@1337exp/taoui 5.30.2 → 5.31.0
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 +9 -0
- package/README.md +1 -1
- package/README.ru.md +1 -1
- package/dist/index.d.ts +45 -1
- package/dist/index.js +568 -185
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
- package/skills/taoui/SKILL.md +2 -1
- package/skills/taoui/references/components.md +1300 -1297
- package/skills/taoui/references/patterns.md +1 -1
package/dist/index.js
CHANGED
|
@@ -110,7 +110,7 @@ function resolveTaoIcon(name) {
|
|
|
110
110
|
}
|
|
111
111
|
const taoIconNames = Object.keys(builtin).map((name) => TAO_ICON_PREFIX + name);
|
|
112
112
|
const _hoisted_1$18 = { class: "tao-icon" };
|
|
113
|
-
const _hoisted_2$
|
|
113
|
+
const _hoisted_2$10 = ["viewBox", "width", "height", "innerHTML"];
|
|
114
114
|
const _sfc_main$1l = /* @__PURE__ */ defineComponent({
|
|
115
115
|
...{ name: "TaoIcon" },
|
|
116
116
|
__name: "TaoIcon",
|
|
@@ -147,7 +147,7 @@ const _sfc_main$1l = /* @__PURE__ */ defineComponent({
|
|
|
147
147
|
"aria-hidden": "true",
|
|
148
148
|
focusable: "false",
|
|
149
149
|
innerHTML: def.value.body
|
|
150
|
-
}, null, 10, _hoisted_2$
|
|
150
|
+
}, null, 10, _hoisted_2$10)) : (openBlock(), createElementBlock("i", {
|
|
151
151
|
key: 1,
|
|
152
152
|
class: normalizeClass(["tao-icon__value", [`icon-${props.name}`, { "tao-icon__value--invert": props.invert }]]),
|
|
153
153
|
style: normalizeStyle(props.size ? `font-size: ${props.size}px` : "")
|
|
@@ -235,6 +235,7 @@ const localeEn = {
|
|
|
235
235
|
inputNumber: { incrementLabel: "Increase", decrementLabel: "Decrease" },
|
|
236
236
|
list: { emptyText: "Nothing here" },
|
|
237
237
|
modal: { closeLabel: "Close" },
|
|
238
|
+
toolbar: { overflowLabel: "More" },
|
|
238
239
|
pagination: {
|
|
239
240
|
ariaLabel: "Pagination",
|
|
240
241
|
prevLabel: "Previous",
|
|
@@ -469,6 +470,7 @@ const localeRu = {
|
|
|
469
470
|
inputNumber: { incrementLabel: "Увеличить", decrementLabel: "Уменьшить" },
|
|
470
471
|
list: { emptyText: "Ничего нет" },
|
|
471
472
|
modal: { closeLabel: "Закрыть" },
|
|
473
|
+
toolbar: { overflowLabel: "Ещё" },
|
|
472
474
|
pagination: {
|
|
473
475
|
ariaLabel: "Пагинация",
|
|
474
476
|
prevLabel: "Назад",
|
|
@@ -596,17 +598,17 @@ function pluralForm(forms, n, code) {
|
|
|
596
598
|
return forms[category] ?? forms.other;
|
|
597
599
|
}
|
|
598
600
|
const _hoisted_1$17 = ["role", "aria-hidden"];
|
|
599
|
-
const _hoisted_2
|
|
601
|
+
const _hoisted_2$$ = {
|
|
600
602
|
key: 0,
|
|
601
603
|
class: "tao-loader__ellipsis",
|
|
602
604
|
"aria-hidden": "true"
|
|
603
605
|
};
|
|
604
|
-
const _hoisted_3$
|
|
606
|
+
const _hoisted_3$S = {
|
|
605
607
|
key: 1,
|
|
606
608
|
class: "tao-loader__ring",
|
|
607
609
|
"aria-hidden": "true"
|
|
608
610
|
};
|
|
609
|
-
const _hoisted_4$
|
|
611
|
+
const _hoisted_4$H = {
|
|
610
612
|
key: 2,
|
|
611
613
|
class: "tao-loader__swap",
|
|
612
614
|
"aria-hidden": "true"
|
|
@@ -658,12 +660,12 @@ const _sfc_main$1k = /* @__PURE__ */ defineComponent({
|
|
|
658
660
|
role: __props.decorative ? void 0 : "status",
|
|
659
661
|
"aria-hidden": __props.decorative ? "true" : void 0
|
|
660
662
|
}, [
|
|
661
|
-
__props.variant === "dots" ? (openBlock(), createElementBlock("div", _hoisted_2
|
|
663
|
+
__props.variant === "dots" ? (openBlock(), createElementBlock("div", _hoisted_2$$, [..._cache[0] || (_cache[0] = [
|
|
662
664
|
createElementVNode("div", null, null, -1),
|
|
663
665
|
createElementVNode("div", null, null, -1),
|
|
664
666
|
createElementVNode("div", null, null, -1),
|
|
665
667
|
createElementVNode("div", null, null, -1)
|
|
666
|
-
])])) : __props.variant === "ring" ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
668
|
+
])])) : __props.variant === "ring" ? (openBlock(), createElementBlock("span", _hoisted_3$S)) : __props.variant === "diamonds" ? (openBlock(), createElementBlock("span", _hoisted_4$H, [..._cache[1] || (_cache[1] = [
|
|
667
669
|
createStaticVNode('<span class="tao-loader__axis" data-v-03f29efb><i class="tao-loader__swap-left" data-v-03f29efb></i><i class="tao-loader__swap-right" data-v-03f29efb></i><i class="tao-loader__swap-hollow" data-v-03f29efb></i></span><span class="tao-loader__axis tao-loader__axis--cross" data-v-03f29efb><i class="tao-loader__swap-left" data-v-03f29efb></i><i class="tao-loader__swap-right" data-v-03f29efb></i><i class="tao-loader__swap-hollow" data-v-03f29efb></i></span>', 2)
|
|
668
670
|
])])) : (openBlock(), createElementBlock("span", _hoisted_5$w)),
|
|
669
671
|
!__props.decorative ? (openBlock(), createElementBlock("span", _hoisted_6$q, toDisplayString(unref(l10n).label), 1)) : createCommentVNode("", true)
|
|
@@ -673,11 +675,11 @@ const _sfc_main$1k = /* @__PURE__ */ defineComponent({
|
|
|
673
675
|
});
|
|
674
676
|
const TaoLoader = /* @__PURE__ */ _export_sfc(_sfc_main$1k, [["__scopeId", "data-v-03f29efb"]]);
|
|
675
677
|
const _hoisted_1$16 = ["type", "aria-pressed", "aria-keyshortcuts", "title", "aria-busy", "disabled"];
|
|
676
|
-
const _hoisted_2$
|
|
678
|
+
const _hoisted_2$_ = {
|
|
677
679
|
key: 2,
|
|
678
680
|
class: "tao-button__content"
|
|
679
681
|
};
|
|
680
|
-
const _hoisted_3$
|
|
682
|
+
const _hoisted_3$R = {
|
|
681
683
|
key: 4,
|
|
682
684
|
class: "tao-button__shortcut",
|
|
683
685
|
"aria-hidden": "true"
|
|
@@ -765,7 +767,7 @@ const _sfc_main$1j = /* @__PURE__ */ defineComponent({
|
|
|
765
767
|
class: "tao-button__icon",
|
|
766
768
|
name: __props.icon
|
|
767
769
|
}, null, 8, ["name"])) : createCommentVNode("", true),
|
|
768
|
-
hasContent() ? (openBlock(), createElementBlock("span", _hoisted_2$
|
|
770
|
+
hasContent() ? (openBlock(), createElementBlock("span", _hoisted_2$_, [
|
|
769
771
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
770
772
|
])) : createCommentVNode("", true),
|
|
771
773
|
__props.iconEnd ? (openBlock(), createBlock(TaoIcon, {
|
|
@@ -773,7 +775,7 @@ const _sfc_main$1j = /* @__PURE__ */ defineComponent({
|
|
|
773
775
|
class: "tao-button__icon",
|
|
774
776
|
name: __props.iconEnd
|
|
775
777
|
}, null, 8, ["name"])) : createCommentVNode("", true),
|
|
776
|
-
__props.shortcut && !isIconOnly() ? (openBlock(), createElementBlock("kbd", _hoisted_3$
|
|
778
|
+
__props.shortcut && !isIconOnly() ? (openBlock(), createElementBlock("kbd", _hoisted_3$R, toDisplayString(__props.shortcut), 1)) : createCommentVNode("", true)
|
|
777
779
|
], 14, _hoisted_1$16);
|
|
778
780
|
};
|
|
779
781
|
}
|
|
@@ -856,8 +858,8 @@ const _hoisted_1$15 = {
|
|
|
856
858
|
key: 0,
|
|
857
859
|
class: "tao-input__affix tao-input__affix--prefix"
|
|
858
860
|
};
|
|
859
|
-
const _hoisted_2$
|
|
860
|
-
const _hoisted_3$
|
|
861
|
+
const _hoisted_2$Z = ["id", "type", "value", "placeholder", "disabled", "aria-invalid", "aria-describedby"];
|
|
862
|
+
const _hoisted_3$Q = {
|
|
861
863
|
key: 1,
|
|
862
864
|
class: "tao-input__affix tao-input__affix--suffix"
|
|
863
865
|
};
|
|
@@ -924,8 +926,8 @@ const _sfc_main$1h = /* @__PURE__ */ defineComponent({
|
|
|
924
926
|
onInput: handleInput,
|
|
925
927
|
onBlur: handleBlur,
|
|
926
928
|
onFocus: handleFocus
|
|
927
|
-
}), null, 16, _hoisted_2$
|
|
928
|
-
has("suffix") ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
929
|
+
}), null, 16, _hoisted_2$Z),
|
|
930
|
+
has("suffix") ? (openBlock(), createElementBlock("span", _hoisted_3$Q, [
|
|
929
931
|
renderSlot(_ctx.$slots, "suffix", {}, void 0, true)
|
|
930
932
|
])) : createCommentVNode("", true)
|
|
931
933
|
], 2)
|
|
@@ -938,8 +940,8 @@ const _hoisted_1$14 = {
|
|
|
938
940
|
key: 0,
|
|
939
941
|
class: "tao-input-group__addon tao-input-group__addon--before"
|
|
940
942
|
};
|
|
941
|
-
const _hoisted_2$
|
|
942
|
-
const _hoisted_3$
|
|
943
|
+
const _hoisted_2$Y = { class: "tao-input-group__field" };
|
|
944
|
+
const _hoisted_3$P = {
|
|
943
945
|
key: 1,
|
|
944
946
|
class: "tao-input-group__addon tao-input-group__addon--after"
|
|
945
947
|
};
|
|
@@ -973,10 +975,10 @@ const _sfc_main$1g = /* @__PURE__ */ defineComponent({
|
|
|
973
975
|
has("before") ? (openBlock(), createElementBlock("div", _hoisted_1$14, [
|
|
974
976
|
renderSlot(_ctx.$slots, "before", {}, void 0, true)
|
|
975
977
|
])) : createCommentVNode("", true),
|
|
976
|
-
createElementVNode("div", _hoisted_2$
|
|
978
|
+
createElementVNode("div", _hoisted_2$Y, [
|
|
977
979
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
978
980
|
]),
|
|
979
|
-
has("after") ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
981
|
+
has("after") ? (openBlock(), createElementBlock("div", _hoisted_3$P, [
|
|
980
982
|
renderSlot(_ctx.$slots, "after", {}, void 0, true)
|
|
981
983
|
])) : createCommentVNode("", true)
|
|
982
984
|
], 34);
|
|
@@ -985,12 +987,12 @@ const _sfc_main$1g = /* @__PURE__ */ defineComponent({
|
|
|
985
987
|
});
|
|
986
988
|
const TaoInputGroup = /* @__PURE__ */ _export_sfc(_sfc_main$1g, [["__scopeId", "data-v-d38f6b53"]]);
|
|
987
989
|
const _hoisted_1$13 = ["id", "value", "placeholder", "disabled", "aria-invalid", "aria-describedby", "aria-valuenow", "aria-valuemin", "aria-valuemax"];
|
|
988
|
-
const _hoisted_2$
|
|
990
|
+
const _hoisted_2$X = {
|
|
989
991
|
key: 0,
|
|
990
992
|
class: "tao-input-number__steppers"
|
|
991
993
|
};
|
|
992
|
-
const _hoisted_3$
|
|
993
|
-
const _hoisted_4$
|
|
994
|
+
const _hoisted_3$O = ["aria-label", "disabled"];
|
|
995
|
+
const _hoisted_4$G = { "aria-hidden": "true" };
|
|
994
996
|
const _hoisted_5$v = ["aria-label", "disabled"];
|
|
995
997
|
const _hoisted_6$p = { "aria-hidden": "true" };
|
|
996
998
|
const _sfc_main$1f = /* @__PURE__ */ defineComponent({
|
|
@@ -1153,7 +1155,7 @@ const _sfc_main$1f = /* @__PURE__ */ defineComponent({
|
|
|
1153
1155
|
onBlur,
|
|
1154
1156
|
onKeydown: onKeydown2
|
|
1155
1157
|
}), null, 16, _hoisted_1$13),
|
|
1156
|
-
__props.controls ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
1158
|
+
__props.controls ? (openBlock(), createElementBlock("div", _hoisted_2$X, [
|
|
1157
1159
|
createElementVNode("button", {
|
|
1158
1160
|
type: "button",
|
|
1159
1161
|
class: "tao-input-number__step",
|
|
@@ -1162,12 +1164,12 @@ const _sfc_main$1f = /* @__PURE__ */ defineComponent({
|
|
|
1162
1164
|
disabled: __props.disabled || atMax.value,
|
|
1163
1165
|
onClick: _cache[0] || (_cache[0] = ($event) => bump(1))
|
|
1164
1166
|
}, [
|
|
1165
|
-
createElementVNode("span", _hoisted_4$
|
|
1167
|
+
createElementVNode("span", _hoisted_4$G, [
|
|
1166
1168
|
renderSlot(_ctx.$slots, "increment-icon", {}, () => [
|
|
1167
1169
|
createVNode(TaoIcon, { name: "tao-plus" })
|
|
1168
1170
|
], true)
|
|
1169
1171
|
])
|
|
1170
|
-
], 8, _hoisted_3$
|
|
1172
|
+
], 8, _hoisted_3$O),
|
|
1171
1173
|
createElementVNode("button", {
|
|
1172
1174
|
type: "button",
|
|
1173
1175
|
class: "tao-input-number__step",
|
|
@@ -1189,9 +1191,9 @@ const _sfc_main$1f = /* @__PURE__ */ defineComponent({
|
|
|
1189
1191
|
});
|
|
1190
1192
|
const TaoInputNumber = /* @__PURE__ */ _export_sfc(_sfc_main$1f, [["__scopeId", "data-v-dc5bb759"]]);
|
|
1191
1193
|
const _hoisted_1$12 = ["aria-label", "disabled"];
|
|
1192
|
-
const _hoisted_2$
|
|
1193
|
-
const _hoisted_3$
|
|
1194
|
-
const _hoisted_4$
|
|
1194
|
+
const _hoisted_2$W = { "aria-hidden": "true" };
|
|
1195
|
+
const _hoisted_3$N = ["id", "value", "disabled", "aria-invalid", "aria-describedby", "aria-valuenow", "aria-valuemin", "aria-valuemax"];
|
|
1196
|
+
const _hoisted_4$F = ["aria-label", "disabled"];
|
|
1195
1197
|
const _hoisted_5$u = { "aria-hidden": "true" };
|
|
1196
1198
|
const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
1197
1199
|
...{ name: "TaoQuantity", inheritAttrs: false },
|
|
@@ -1333,7 +1335,7 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
1333
1335
|
disabled: minusDisabled.value,
|
|
1334
1336
|
onClick: onDec
|
|
1335
1337
|
}, [
|
|
1336
|
-
createElementVNode("span", _hoisted_2$
|
|
1338
|
+
createElementVNode("span", _hoisted_2$W, [
|
|
1337
1339
|
renderSlot(_ctx.$slots, "decrement-icon", {}, () => [
|
|
1338
1340
|
createVNode(TaoIcon, { name: "tao-minus" })
|
|
1339
1341
|
], true)
|
|
@@ -1358,7 +1360,7 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
1358
1360
|
onFocus,
|
|
1359
1361
|
onBlur,
|
|
1360
1362
|
onKeydown: onKeydown2
|
|
1361
|
-
}), null, 16, _hoisted_3$
|
|
1363
|
+
}), null, 16, _hoisted_3$N),
|
|
1362
1364
|
createElementVNode("button", {
|
|
1363
1365
|
type: "button",
|
|
1364
1366
|
class: "tao-quantity__btn tao-quantity__btn--inc",
|
|
@@ -1371,7 +1373,7 @@ const _sfc_main$1e = /* @__PURE__ */ defineComponent({
|
|
|
1371
1373
|
createVNode(TaoIcon, { name: "tao-plus" })
|
|
1372
1374
|
], true)
|
|
1373
1375
|
])
|
|
1374
|
-
], 8, _hoisted_4$
|
|
1376
|
+
], 8, _hoisted_4$F)
|
|
1375
1377
|
], 16);
|
|
1376
1378
|
};
|
|
1377
1379
|
}
|
|
@@ -1381,15 +1383,15 @@ const _hoisted_1$11 = {
|
|
|
1381
1383
|
key: 0,
|
|
1382
1384
|
class: "tao-card__media"
|
|
1383
1385
|
};
|
|
1384
|
-
const _hoisted_2$
|
|
1386
|
+
const _hoisted_2$V = {
|
|
1385
1387
|
key: 0,
|
|
1386
1388
|
class: "tao-card__overlay"
|
|
1387
1389
|
};
|
|
1388
|
-
const _hoisted_3$
|
|
1390
|
+
const _hoisted_3$M = {
|
|
1389
1391
|
key: 1,
|
|
1390
1392
|
class: "tao-card__overlay"
|
|
1391
1393
|
};
|
|
1392
|
-
const _hoisted_4$
|
|
1394
|
+
const _hoisted_4$E = {
|
|
1393
1395
|
key: 0,
|
|
1394
1396
|
class: "tao-card__header"
|
|
1395
1397
|
};
|
|
@@ -1474,10 +1476,10 @@ const _sfc_main$1d = /* @__PURE__ */ defineComponent({
|
|
|
1474
1476
|
}, [
|
|
1475
1477
|
_ctx.$slots.media ? (openBlock(), createElementBlock("div", _hoisted_1$11, [
|
|
1476
1478
|
renderSlot(_ctx.$slots, "media", {}, void 0, true),
|
|
1477
|
-
_ctx.$slots.overlay ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
1479
|
+
_ctx.$slots.overlay ? (openBlock(), createElementBlock("div", _hoisted_2$V, [
|
|
1478
1480
|
renderSlot(_ctx.$slots, "overlay", {}, void 0, true)
|
|
1479
1481
|
])) : createCommentVNode("", true)
|
|
1480
|
-
])) : _ctx.$slots.overlay ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
1482
|
+
])) : _ctx.$slots.overlay ? (openBlock(), createElementBlock("div", _hoisted_3$M, [
|
|
1481
1483
|
renderSlot(_ctx.$slots, "overlay", {}, void 0, true)
|
|
1482
1484
|
])) : createCommentVNode("", true),
|
|
1483
1485
|
hasContent.value ? (openBlock(), createElementBlock("div", {
|
|
@@ -1485,7 +1487,7 @@ const _sfc_main$1d = /* @__PURE__ */ defineComponent({
|
|
|
1485
1487
|
class: "tao-card__content",
|
|
1486
1488
|
style: normalizeStyle(paddingStyle.value)
|
|
1487
1489
|
}, [
|
|
1488
|
-
has("header") ? (openBlock(), createElementBlock("div", _hoisted_4$
|
|
1490
|
+
has("header") ? (openBlock(), createElementBlock("div", _hoisted_4$E, [
|
|
1489
1491
|
renderSlot(_ctx.$slots, "header", {}, void 0, true)
|
|
1490
1492
|
])) : createCommentVNode("", true),
|
|
1491
1493
|
has("title") || has("sub") ? (openBlock(), createElementBlock("div", _hoisted_5$t, [
|
|
@@ -1685,12 +1687,12 @@ function useWholePixelPanel(panel, open) {
|
|
|
1685
1687
|
});
|
|
1686
1688
|
}
|
|
1687
1689
|
const _hoisted_1$10 = ["aria-labelledby"];
|
|
1688
|
-
const _hoisted_2$
|
|
1690
|
+
const _hoisted_2$U = {
|
|
1689
1691
|
key: 0,
|
|
1690
1692
|
class: "tao-modal__header"
|
|
1691
1693
|
};
|
|
1692
|
-
const _hoisted_3$
|
|
1693
|
-
const _hoisted_4$
|
|
1694
|
+
const _hoisted_3$L = ["id"];
|
|
1695
|
+
const _hoisted_4$D = { key: 1 };
|
|
1694
1696
|
const _hoisted_5$s = ["aria-label"];
|
|
1695
1697
|
const _hoisted_6$n = { "aria-hidden": "true" };
|
|
1696
1698
|
const _hoisted_7$j = { class: "tao-modal__content" };
|
|
@@ -1783,13 +1785,13 @@ const _sfc_main$1c = /* @__PURE__ */ defineComponent({
|
|
|
1783
1785
|
"aria-labelledby": __props.title ? unref(titleId) : void 0,
|
|
1784
1786
|
tabindex: "-1"
|
|
1785
1787
|
}), [
|
|
1786
|
-
__props.title || _ctx.$slots.header || __props.closable ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
1788
|
+
__props.title || _ctx.$slots.header || __props.closable ? (openBlock(), createElementBlock("div", _hoisted_2$U, [
|
|
1787
1789
|
renderSlot(_ctx.$slots, "header", {}, () => [
|
|
1788
1790
|
__props.title ? (openBlock(), createElementBlock("h2", {
|
|
1789
1791
|
key: 0,
|
|
1790
1792
|
id: unref(titleId),
|
|
1791
1793
|
class: "tao-modal__title"
|
|
1792
|
-
}, toDisplayString(__props.title), 9, _hoisted_3$
|
|
1794
|
+
}, toDisplayString(__props.title), 9, _hoisted_3$L)) : (openBlock(), createElementBlock("span", _hoisted_4$D))
|
|
1793
1795
|
], true),
|
|
1794
1796
|
__props.closable ? (openBlock(), createElementBlock("button", {
|
|
1795
1797
|
key: 0,
|
|
@@ -1822,7 +1824,7 @@ const _sfc_main$1c = /* @__PURE__ */ defineComponent({
|
|
|
1822
1824
|
});
|
|
1823
1825
|
const TaoModal = /* @__PURE__ */ _export_sfc(_sfc_main$1c, [["__scopeId", "data-v-855470e7"]]);
|
|
1824
1826
|
const _hoisted_1$$ = ["id", "aria-selected", "aria-controls", "tabindex", "disabled", "onClick"];
|
|
1825
|
-
const _hoisted_2$
|
|
1827
|
+
const _hoisted_2$T = ["id", "aria-labelledby"];
|
|
1826
1828
|
const _sfc_main$1b = /* @__PURE__ */ defineComponent({
|
|
1827
1829
|
...{ name: "TaoTabs" },
|
|
1828
1830
|
__name: "TaoTabs",
|
|
@@ -1928,7 +1930,7 @@ const _sfc_main$1b = /* @__PURE__ */ defineComponent({
|
|
|
1928
1930
|
"aria-labelledby": tabId(__props.modelValue)
|
|
1929
1931
|
}, [
|
|
1930
1932
|
renderSlot(_ctx.$slots, "default", { activeTab: __props.modelValue }, void 0, true)
|
|
1931
|
-
], 8, _hoisted_2$
|
|
1933
|
+
], 8, _hoisted_2$T)
|
|
1932
1934
|
], 2);
|
|
1933
1935
|
};
|
|
1934
1936
|
}
|
|
@@ -2447,12 +2449,12 @@ function zoneGradient(zones, min, max, vertical = false, dimmed = false) {
|
|
|
2447
2449
|
return `linear-gradient(${vertical ? "to top" : "to right"}, ${stops.join(", ")})`;
|
|
2448
2450
|
}
|
|
2449
2451
|
const _hoisted_1$_ = ["aria-disabled"];
|
|
2450
|
-
const _hoisted_2$
|
|
2451
|
-
const _hoisted_3$
|
|
2452
|
+
const _hoisted_2$S = ["id", "tabindex", "aria-valuemin", "aria-valuemax", "aria-valuenow", "aria-valuetext", "aria-label", "aria-orientation", "aria-disabled", "aria-invalid", "aria-describedby", "aria-keyshortcuts", "onKeydown"];
|
|
2453
|
+
const _hoisted_3$K = {
|
|
2452
2454
|
key: 2,
|
|
2453
2455
|
class: "tao-slider__value"
|
|
2454
2456
|
};
|
|
2455
|
-
const _hoisted_4$
|
|
2457
|
+
const _hoisted_4$C = ["aria-label", "onKeydown"];
|
|
2456
2458
|
const _hoisted_5$r = {
|
|
2457
2459
|
key: 0,
|
|
2458
2460
|
class: "tao-slider__marks"
|
|
@@ -2792,7 +2794,7 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent({
|
|
|
2792
2794
|
"aria-keyshortcuts": __props.editable ? "Enter F2" : void 0,
|
|
2793
2795
|
onKeydown: ($event) => onKeydown2($event, i),
|
|
2794
2796
|
onBlur: _cache[0] || (_cache[0] = ($event) => pointerFocus.value = false)
|
|
2795
|
-
}, null, 46, _hoisted_2$
|
|
2797
|
+
}, null, 46, _hoisted_2$S),
|
|
2796
2798
|
__props.bubble ? (openBlock(), createElementBlock("div", {
|
|
2797
2799
|
key: 0,
|
|
2798
2800
|
class: normalizeClass(["tao-slider__bubble", { "tao-slider__bubble--auto": bubbleAuto(v) }]),
|
|
@@ -2808,7 +2810,7 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent({
|
|
|
2808
2810
|
], 6)) : createCommentVNode("", true)
|
|
2809
2811
|
], 64);
|
|
2810
2812
|
}), 128)),
|
|
2811
|
-
__props.showValue && editing.value === null ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
2813
|
+
__props.showValue && editing.value === null ? (openBlock(), createElementBlock("div", _hoisted_3$K, [
|
|
2812
2814
|
renderSlot(_ctx.$slots, "pre-value", {}, void 0, true),
|
|
2813
2815
|
createTextVNode(toDisplayString(barText.value), 1),
|
|
2814
2816
|
renderSlot(_ctx.$slots, "post-value", {}, void 0, true)
|
|
@@ -2837,7 +2839,7 @@ const _sfc_main$1a = /* @__PURE__ */ defineComponent({
|
|
|
2837
2839
|
}, ["stop"])),
|
|
2838
2840
|
onWheel: _cache[7] || (_cache[7] = withModifiers(() => {
|
|
2839
2841
|
}, ["stop"]))
|
|
2840
|
-
}, null, 40, _hoisted_4$
|
|
2842
|
+
}, null, 40, _hoisted_4$C)), [
|
|
2841
2843
|
[vModelText, draft.value]
|
|
2842
2844
|
]) : createCommentVNode("", true)
|
|
2843
2845
|
], 34),
|
|
@@ -2942,8 +2944,8 @@ const _sfc_main$19 = /* @__PURE__ */ defineComponent({
|
|
|
2942
2944
|
}
|
|
2943
2945
|
});
|
|
2944
2946
|
const _hoisted_1$Z = { class: "tao-scrubber__controls" };
|
|
2945
|
-
const _hoisted_2$
|
|
2946
|
-
const _hoisted_3$
|
|
2947
|
+
const _hoisted_2$R = { class: "tao-scrubber__track" };
|
|
2948
|
+
const _hoisted_3$J = {
|
|
2947
2949
|
key: 0,
|
|
2948
2950
|
class: "tao-scrubber__time"
|
|
2949
2951
|
};
|
|
@@ -3017,7 +3019,7 @@ const _sfc_main$18 = /* @__PURE__ */ defineComponent({
|
|
|
3017
3019
|
_: 1
|
|
3018
3020
|
}, 8, ["disabled", "aria-label"])) : createCommentVNode("", true)
|
|
3019
3021
|
]),
|
|
3020
|
-
createElementVNode("div", _hoisted_2$
|
|
3022
|
+
createElementVNode("div", _hoisted_2$R, [
|
|
3021
3023
|
createVNode(_sfc_main$19, {
|
|
3022
3024
|
"model-value": __props.modelValue,
|
|
3023
3025
|
min: 0,
|
|
@@ -3041,7 +3043,7 @@ const _sfc_main$18 = /* @__PURE__ */ defineComponent({
|
|
|
3041
3043
|
} : void 0
|
|
3042
3044
|
]), 1032, ["model-value", "max", "step", "marks", "marks-side", "variant", "size", "disabled"])
|
|
3043
3045
|
]),
|
|
3044
|
-
__props.showTime ? (openBlock(), createElementBlock("div", _hoisted_3$
|
|
3046
|
+
__props.showTime ? (openBlock(), createElementBlock("div", _hoisted_3$J, [
|
|
3045
3047
|
renderSlot(_ctx.$slots, "time", {
|
|
3046
3048
|
time: __props.modelValue,
|
|
3047
3049
|
length: __props.length,
|
|
@@ -3397,12 +3399,12 @@ function frameStyle(bordered) {
|
|
|
3397
3399
|
return bordered ? { "--tao-frame-alpha": "100%", "--tao-frame-tint": "0%", "--tao-frame-fill": "0%" } : { "--tao-frame-alpha": "0%", "--tao-frame-tint": "6%", "--tao-frame-fill": "100%" };
|
|
3398
3400
|
}
|
|
3399
3401
|
const _hoisted_1$X = ["aria-expanded", "aria-controls"];
|
|
3400
|
-
const _hoisted_2$
|
|
3402
|
+
const _hoisted_2$Q = {
|
|
3401
3403
|
key: 0,
|
|
3402
3404
|
class: "tao-spoiler__title"
|
|
3403
3405
|
};
|
|
3404
|
-
const _hoisted_3$
|
|
3405
|
-
const _hoisted_4$
|
|
3406
|
+
const _hoisted_3$I = ["id"];
|
|
3407
|
+
const _hoisted_4$B = { class: "tao-spoiler__content-inner" };
|
|
3406
3408
|
const _sfc_main$15 = /* @__PURE__ */ defineComponent({
|
|
3407
3409
|
...{ name: "TaoSpoiler" },
|
|
3408
3410
|
__name: "TaoSpoiler",
|
|
@@ -3477,7 +3479,7 @@ const _sfc_main$15 = /* @__PURE__ */ defineComponent({
|
|
|
3477
3479
|
class: normalizeClass(["tao-spoiler__icon", { "tao-spoiler__icon--open": isOpen.value }]),
|
|
3478
3480
|
name: "tao-chevron-right"
|
|
3479
3481
|
}, null, 8, ["class"]),
|
|
3480
|
-
__props.title || has("title") ? (openBlock(), createElementBlock("span", _hoisted_2$
|
|
3482
|
+
__props.title || has("title") ? (openBlock(), createElementBlock("span", _hoisted_2$Q, [
|
|
3481
3483
|
renderSlot(_ctx.$slots, "title", {}, () => [
|
|
3482
3484
|
createTextVNode(toDisplayString(__props.title), 1)
|
|
3483
3485
|
], true)
|
|
@@ -3496,10 +3498,10 @@ const _sfc_main$15 = /* @__PURE__ */ defineComponent({
|
|
|
3496
3498
|
id: unref(panelId),
|
|
3497
3499
|
class: "tao-spoiler__content"
|
|
3498
3500
|
}, [
|
|
3499
|
-
createElementVNode("div", _hoisted_4$
|
|
3501
|
+
createElementVNode("div", _hoisted_4$B, [
|
|
3500
3502
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
3501
3503
|
])
|
|
3502
|
-
], 8, _hoisted_3$
|
|
3504
|
+
], 8, _hoisted_3$I)) : createCommentVNode("", true)
|
|
3503
3505
|
]),
|
|
3504
3506
|
_: 3
|
|
3505
3507
|
})
|
|
@@ -3767,13 +3769,13 @@ const _hoisted_1$U = {
|
|
|
3767
3769
|
key: 0,
|
|
3768
3770
|
class: "tao-tour"
|
|
3769
3771
|
};
|
|
3770
|
-
const _hoisted_2$
|
|
3772
|
+
const _hoisted_2$P = {
|
|
3771
3773
|
key: 1,
|
|
3772
3774
|
class: "tao-tour__dim",
|
|
3773
3775
|
"aria-hidden": "true"
|
|
3774
3776
|
};
|
|
3775
|
-
const _hoisted_3$
|
|
3776
|
-
const _hoisted_4$
|
|
3777
|
+
const _hoisted_3$H = ["aria-labelledby", "aria-describedby"];
|
|
3778
|
+
const _hoisted_4$A = ["id"];
|
|
3777
3779
|
const _hoisted_5$q = ["id"];
|
|
3778
3780
|
const _hoisted_6$l = { class: "tao-tour__footer" };
|
|
3779
3781
|
const _hoisted_7$h = {
|
|
@@ -3957,7 +3959,7 @@ const _sfc_main$11 = /* @__PURE__ */ defineComponent({
|
|
|
3957
3959
|
class: "tao-tour__hole",
|
|
3958
3960
|
style: normalizeStyle(holeStyle.value),
|
|
3959
3961
|
"aria-hidden": "true"
|
|
3960
|
-
}, null, 4)) : (openBlock(), createElementBlock("div", _hoisted_2$
|
|
3962
|
+
}, null, 4)) : (openBlock(), createElementBlock("div", _hoisted_2$P)),
|
|
3961
3963
|
createElementVNode("div", {
|
|
3962
3964
|
ref_key: "cardRef",
|
|
3963
3965
|
ref: cardRef,
|
|
@@ -3984,7 +3986,7 @@ const _sfc_main$11 = /* @__PURE__ */ defineComponent({
|
|
|
3984
3986
|
key: 0,
|
|
3985
3987
|
id: unref(titleId),
|
|
3986
3988
|
class: "tao-tour__title"
|
|
3987
|
-
}, toDisplayString(__props.step.title), 9, _hoisted_4$
|
|
3989
|
+
}, toDisplayString(__props.step.title), 9, _hoisted_4$A)) : createCommentVNode("", true),
|
|
3988
3990
|
__props.step.text ? (openBlock(), createElementBlock("p", {
|
|
3989
3991
|
key: 1,
|
|
3990
3992
|
id: unref(textId),
|
|
@@ -4037,7 +4039,7 @@ const _sfc_main$11 = /* @__PURE__ */ defineComponent({
|
|
|
4037
4039
|
})
|
|
4038
4040
|
])
|
|
4039
4041
|
])
|
|
4040
|
-
], 46, _hoisted_3$
|
|
4042
|
+
], 46, _hoisted_3$H)
|
|
4041
4043
|
])) : createCommentVNode("", true)
|
|
4042
4044
|
]);
|
|
4043
4045
|
};
|
|
@@ -4206,9 +4208,9 @@ const _sfc_main$Y = /* @__PURE__ */ defineComponent({
|
|
|
4206
4208
|
});
|
|
4207
4209
|
const TaoGridItem = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["__scopeId", "data-v-d42e5e67"]]);
|
|
4208
4210
|
const _hoisted_1$S = { class: "tao-split__pane tao-split__pane--start" };
|
|
4209
|
-
const _hoisted_2$
|
|
4210
|
-
const _hoisted_3$
|
|
4211
|
-
const _hoisted_4$
|
|
4211
|
+
const _hoisted_2$O = ["aria-orientation", "aria-valuemin", "aria-valuemax", "aria-valuenow", "aria-valuetext", "aria-disabled", "tabindex"];
|
|
4212
|
+
const _hoisted_3$G = { class: "tao-split__pane tao-split__pane--end" };
|
|
4213
|
+
const _hoisted_4$z = {
|
|
4212
4214
|
key: 0,
|
|
4213
4215
|
class: "tao-split__shield"
|
|
4214
4216
|
};
|
|
@@ -4532,19 +4534,19 @@ const _sfc_main$X = /* @__PURE__ */ defineComponent({
|
|
|
4532
4534
|
onKeydown: onKeydown2,
|
|
4533
4535
|
onDragstart: _cache[0] || (_cache[0] = withModifiers(() => {
|
|
4534
4536
|
}, ["prevent"]))
|
|
4535
|
-
}, null, 40, _hoisted_2$
|
|
4536
|
-
createElementVNode("div", _hoisted_3$
|
|
4537
|
+
}, null, 40, _hoisted_2$O),
|
|
4538
|
+
createElementVNode("div", _hoisted_3$G, [
|
|
4537
4539
|
renderSlot(_ctx.$slots, "end", {}, void 0, true)
|
|
4538
4540
|
]),
|
|
4539
|
-
isDragging.value ? (openBlock(), createElementBlock("div", _hoisted_4$
|
|
4541
|
+
isDragging.value ? (openBlock(), createElementBlock("div", _hoisted_4$z)) : createCommentVNode("", true)
|
|
4540
4542
|
], 6);
|
|
4541
4543
|
};
|
|
4542
4544
|
}
|
|
4543
4545
|
});
|
|
4544
4546
|
const TaoSplit = /* @__PURE__ */ _export_sfc(_sfc_main$X, [["__scopeId", "data-v-316b0d45"]]);
|
|
4545
4547
|
const _hoisted_1$R = { class: "tao-image" };
|
|
4546
|
-
const _hoisted_2$
|
|
4547
|
-
const _hoisted_3$
|
|
4548
|
+
const _hoisted_2$N = ["src", "alt", "loading"];
|
|
4549
|
+
const _hoisted_3$F = { class: "tao-image__placeholder" };
|
|
4548
4550
|
const _sfc_main$W = /* @__PURE__ */ defineComponent({
|
|
4549
4551
|
...{ name: "TaoImage" },
|
|
4550
4552
|
__name: "TaoImage",
|
|
@@ -4587,9 +4589,9 @@ const _sfc_main$W = /* @__PURE__ */ defineComponent({
|
|
|
4587
4589
|
draggable: "false",
|
|
4588
4590
|
onLoad: handleLoad,
|
|
4589
4591
|
onError: handleError
|
|
4590
|
-
}, null, 42, _hoisted_2$
|
|
4592
|
+
}, null, 42, _hoisted_2$N)) : createCommentVNode("", true),
|
|
4591
4593
|
!__props.src || hasError.value ? renderSlot(_ctx.$slots, "default", {}, () => [
|
|
4592
|
-
createElementVNode("div", _hoisted_3$
|
|
4594
|
+
createElementVNode("div", _hoisted_3$F, toDisplayString(__props.placeholderText), 1)
|
|
4593
4595
|
], true, 1) : createCommentVNode("", true)
|
|
4594
4596
|
]);
|
|
4595
4597
|
};
|
|
@@ -4597,12 +4599,12 @@ const _sfc_main$W = /* @__PURE__ */ defineComponent({
|
|
|
4597
4599
|
});
|
|
4598
4600
|
const TaoImage = /* @__PURE__ */ _export_sfc(_sfc_main$W, [["__scopeId", "data-v-61f47c52"]]);
|
|
4599
4601
|
const _hoisted_1$Q = ["for"];
|
|
4600
|
-
const _hoisted_2$
|
|
4601
|
-
const _hoisted_3$
|
|
4602
|
+
const _hoisted_2$M = ["id", "checked", "disabled", "aria-checked", "aria-invalid", "aria-describedby"];
|
|
4603
|
+
const _hoisted_3$E = {
|
|
4602
4604
|
key: 0,
|
|
4603
4605
|
class: "tao-checkbox__label"
|
|
4604
4606
|
};
|
|
4605
|
-
const _hoisted_4$
|
|
4607
|
+
const _hoisted_4$y = {
|
|
4606
4608
|
key: 1,
|
|
4607
4609
|
class: "tao-checkbox__label"
|
|
4608
4610
|
};
|
|
@@ -4677,9 +4679,9 @@ const _sfc_main$V = /* @__PURE__ */ defineComponent({
|
|
|
4677
4679
|
"aria-invalid": unref(invalid) || void 0,
|
|
4678
4680
|
"aria-describedby": unref(describedBy),
|
|
4679
4681
|
onChange: onInputChange
|
|
4680
|
-
}), null, 16, _hoisted_2$
|
|
4682
|
+
}), null, 16, _hoisted_2$M),
|
|
4681
4683
|
_cache[0] || (_cache[0] = createElementVNode("span", { class: "tao-checkbox__box" }, null, -1)),
|
|
4682
|
-
__props.label ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
4684
|
+
__props.label ? (openBlock(), createElementBlock("span", _hoisted_3$E, toDisplayString(__props.label), 1)) : (openBlock(), createElementBlock("span", _hoisted_4$y, [
|
|
4683
4685
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
4684
4686
|
])),
|
|
4685
4687
|
renderSlot(_ctx.$slots, "post", { text: __props.label }, void 0, true)
|
|
@@ -4692,9 +4694,9 @@ const _hoisted_1$P = {
|
|
|
4692
4694
|
key: 0,
|
|
4693
4695
|
class: "tao-tag__prefix"
|
|
4694
4696
|
};
|
|
4695
|
-
const _hoisted_2$
|
|
4696
|
-
const _hoisted_3$
|
|
4697
|
-
const _hoisted_4$
|
|
4697
|
+
const _hoisted_2$L = { class: "tao-tag__text" };
|
|
4698
|
+
const _hoisted_3$D = ["aria-label"];
|
|
4699
|
+
const _hoisted_4$x = { "aria-hidden": "true" };
|
|
4698
4700
|
const _sfc_main$U = /* @__PURE__ */ defineComponent({
|
|
4699
4701
|
...{ name: "TaoTag" },
|
|
4700
4702
|
__name: "TaoTag",
|
|
@@ -4741,7 +4743,7 @@ const _sfc_main$U = /* @__PURE__ */ defineComponent({
|
|
|
4741
4743
|
has("prefix") ? (openBlock(), createElementBlock("span", _hoisted_1$P, [
|
|
4742
4744
|
renderSlot(_ctx.$slots, "prefix", {}, void 0, true)
|
|
4743
4745
|
])) : createCommentVNode("", true),
|
|
4744
|
-
createElementVNode("span", _hoisted_2$
|
|
4746
|
+
createElementVNode("span", _hoisted_2$L, [
|
|
4745
4747
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
4746
4748
|
]),
|
|
4747
4749
|
__props.closable ? (openBlock(), createElementBlock("button", {
|
|
@@ -4751,23 +4753,23 @@ const _sfc_main$U = /* @__PURE__ */ defineComponent({
|
|
|
4751
4753
|
"aria-label": unref(l10n).closeLabel,
|
|
4752
4754
|
onClick: withModifiers(onClose, ["stop"])
|
|
4753
4755
|
}, [
|
|
4754
|
-
createElementVNode("span", _hoisted_4$
|
|
4756
|
+
createElementVNode("span", _hoisted_4$x, [
|
|
4755
4757
|
renderSlot(_ctx.$slots, "close-icon", {}, () => [
|
|
4756
4758
|
createVNode(TaoIcon, { name: "tao-close" })
|
|
4757
4759
|
], true)
|
|
4758
4760
|
])
|
|
4759
|
-
], 8, _hoisted_3$
|
|
4761
|
+
], 8, _hoisted_3$D)) : createCommentVNode("", true)
|
|
4760
4762
|
], 6);
|
|
4761
4763
|
};
|
|
4762
4764
|
}
|
|
4763
4765
|
});
|
|
4764
4766
|
const TaoTag = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["__scopeId", "data-v-0af1f161"]]);
|
|
4765
4767
|
const _hoisted_1$O = ["role", "aria-hidden"];
|
|
4766
|
-
const _hoisted_2$
|
|
4768
|
+
const _hoisted_2$K = {
|
|
4767
4769
|
key: 1,
|
|
4768
4770
|
class: "tao-divider__text"
|
|
4769
4771
|
};
|
|
4770
|
-
const _hoisted_3$
|
|
4772
|
+
const _hoisted_3$C = {
|
|
4771
4773
|
key: 2,
|
|
4772
4774
|
class: "tao-divider__line tao-divider__line--end"
|
|
4773
4775
|
};
|
|
@@ -4803,12 +4805,12 @@ const _sfc_main$T = /* @__PURE__ */ defineComponent({
|
|
|
4803
4805
|
key: 0,
|
|
4804
4806
|
class: normalizeClass(["tao-divider__line", { "tao-divider__line--start": hasLabel.value }])
|
|
4805
4807
|
}, null, 2)) : createCommentVNode("", true),
|
|
4806
|
-
hasLabel.value ? (openBlock(), createElementBlock("span", _hoisted_2$
|
|
4808
|
+
hasLabel.value ? (openBlock(), createElementBlock("span", _hoisted_2$K, [
|
|
4807
4809
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
4808
4810
|
createTextVNode(toDisplayString(__props.text), 1)
|
|
4809
4811
|
], true)
|
|
4810
4812
|
])) : createCommentVNode("", true),
|
|
4811
|
-
__props.variant !== "gap" && hasLabel.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
4813
|
+
__props.variant !== "gap" && hasLabel.value ? (openBlock(), createElementBlock("span", _hoisted_3$C)) : createCommentVNode("", true)
|
|
4812
4814
|
], 10, _hoisted_1$O);
|
|
4813
4815
|
};
|
|
4814
4816
|
}
|
|
@@ -4818,7 +4820,7 @@ const _hoisted_1$N = {
|
|
|
4818
4820
|
key: 0,
|
|
4819
4821
|
class: "tao-fieldset__legend"
|
|
4820
4822
|
};
|
|
4821
|
-
const _hoisted_2$
|
|
4823
|
+
const _hoisted_2$J = { class: "tao-fieldset__body" };
|
|
4822
4824
|
const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
4823
4825
|
...{ name: "TaoFieldset" },
|
|
4824
4826
|
__name: "TaoFieldset",
|
|
@@ -4838,7 +4840,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
|
4838
4840
|
createTextVNode(toDisplayString(__props.legend), 1)
|
|
4839
4841
|
], true)
|
|
4840
4842
|
])) : createCommentVNode("", true),
|
|
4841
|
-
createElementVNode("div", _hoisted_2$
|
|
4843
|
+
createElementVNode("div", _hoisted_2$J, [
|
|
4842
4844
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
4843
4845
|
])
|
|
4844
4846
|
], 2);
|
|
@@ -4891,7 +4893,7 @@ const _sfc_main$R = /* @__PURE__ */ defineComponent({
|
|
|
4891
4893
|
});
|
|
4892
4894
|
const TaoAnimatedBorder = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["__scopeId", "data-v-86ba074e"]]);
|
|
4893
4895
|
const _hoisted_1$M = ["id", "placeholder", "spellcheck", "autocomplete", "minlength", "maxlength", "disabled", "readonly", "rows", "value", "aria-invalid", "aria-describedby"];
|
|
4894
|
-
const _hoisted_2$
|
|
4896
|
+
const _hoisted_2$I = ["id"];
|
|
4895
4897
|
const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
4896
4898
|
...{ name: "TaoTextarea", inheritAttrs: false },
|
|
4897
4899
|
__name: "TaoTextarea",
|
|
@@ -5035,15 +5037,15 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
|
5035
5037
|
key: 0,
|
|
5036
5038
|
id: counterId.value,
|
|
5037
5039
|
class: normalizeClass(["tao-textarea__count", { "tao-textarea__count--limit": atLimit.value }])
|
|
5038
|
-
}, toDisplayString(countLabel.value), 11, _hoisted_2$
|
|
5040
|
+
}, toDisplayString(countLabel.value), 11, _hoisted_2$I)) : createCommentVNode("", true)
|
|
5039
5041
|
], 16);
|
|
5040
5042
|
};
|
|
5041
5043
|
}
|
|
5042
5044
|
});
|
|
5043
5045
|
const TaoTextarea = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["__scopeId", "data-v-9aaf7131"]]);
|
|
5044
5046
|
const _hoisted_1$L = ["aria-label"];
|
|
5045
|
-
const _hoisted_2$
|
|
5046
|
-
const _hoisted_3$
|
|
5047
|
+
const _hoisted_2$H = { class: "tao-scroll-top__content" };
|
|
5048
|
+
const _hoisted_3$B = {
|
|
5047
5049
|
key: 0,
|
|
5048
5050
|
class: "tao-scroll-top__text",
|
|
5049
5051
|
"aria-hidden": "true"
|
|
@@ -5143,8 +5145,8 @@ const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
|
5143
5145
|
"aria-label": accessibleName.value,
|
|
5144
5146
|
onClick: withModifiers(goToTop, ["prevent"])
|
|
5145
5147
|
}), [
|
|
5146
|
-
createElementVNode("span", _hoisted_2$
|
|
5147
|
-
isText.value && caption.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
5148
|
+
createElementVNode("span", _hoisted_2$H, [
|
|
5149
|
+
isText.value && caption.value ? (openBlock(), createElementBlock("span", _hoisted_3$B, toDisplayString(caption.value), 1)) : createCommentVNode("", true),
|
|
5148
5150
|
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
5149
5151
|
createVNode(TaoIcon, {
|
|
5150
5152
|
class: "tao-scroll-top__icon",
|
|
@@ -5168,12 +5170,12 @@ const _sfc_main$P = /* @__PURE__ */ defineComponent({
|
|
|
5168
5170
|
});
|
|
5169
5171
|
const TaoScrollTop = /* @__PURE__ */ _export_sfc(_sfc_main$P, [["__scopeId", "data-v-69ee603c"]]);
|
|
5170
5172
|
const _hoisted_1$K = { class: "tao-progress" };
|
|
5171
|
-
const _hoisted_2$
|
|
5173
|
+
const _hoisted_2$G = {
|
|
5172
5174
|
key: 0,
|
|
5173
5175
|
class: "tao-progress__side"
|
|
5174
5176
|
};
|
|
5175
|
-
const _hoisted_3$
|
|
5176
|
-
const _hoisted_4$
|
|
5177
|
+
const _hoisted_3$A = { class: "tao-progress__main" };
|
|
5178
|
+
const _hoisted_4$w = {
|
|
5177
5179
|
key: 0,
|
|
5178
5180
|
class: "tao-progress__percentage"
|
|
5179
5181
|
};
|
|
@@ -5220,11 +5222,11 @@ const _sfc_main$O = /* @__PURE__ */ defineComponent({
|
|
|
5220
5222
|
class: normalizeClass(["tao-progress__container", { "tao-progress__container--over": showOverPercent.value }]),
|
|
5221
5223
|
style: normalizeStyle({ minWidth: `${minW.value}px`, maxWidth: `${maxW.value}px` })
|
|
5222
5224
|
}, [
|
|
5223
|
-
has("left") ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
5225
|
+
has("left") ? (openBlock(), createElementBlock("div", _hoisted_2$G, [
|
|
5224
5226
|
renderSlot(_ctx.$slots, "left", {}, void 0, true)
|
|
5225
5227
|
])) : createCommentVNode("", true),
|
|
5226
|
-
createElementVNode("div", _hoisted_3$
|
|
5227
|
-
showOverPercent.value ? (openBlock(), createElementBlock("span", _hoisted_4$
|
|
5228
|
+
createElementVNode("div", _hoisted_3$A, [
|
|
5229
|
+
showOverPercent.value ? (openBlock(), createElementBlock("span", _hoisted_4$w, toDisplayString(__props.progress) + "%", 1)) : createCommentVNode("", true),
|
|
5228
5230
|
createElementVNode("div", {
|
|
5229
5231
|
class: "tao-progress__track",
|
|
5230
5232
|
style: normalizeStyle({ height: `${__props.height}px` })
|
|
@@ -5341,9 +5343,9 @@ function partitionByAccept(files, accept) {
|
|
|
5341
5343
|
return { accepted, rejected };
|
|
5342
5344
|
}
|
|
5343
5345
|
const _hoisted_1$J = { class: "tao-file-drop__row" };
|
|
5344
|
-
const _hoisted_2$
|
|
5345
|
-
const _hoisted_3$
|
|
5346
|
-
const _hoisted_4$
|
|
5346
|
+
const _hoisted_2$F = ["aria-label"];
|
|
5347
|
+
const _hoisted_3$z = { "aria-hidden": "true" };
|
|
5348
|
+
const _hoisted_4$v = ["accept", "multiple"];
|
|
5347
5349
|
const _hoisted_5$o = {
|
|
5348
5350
|
key: 0,
|
|
5349
5351
|
class: "tao-file-drop__list"
|
|
@@ -5478,12 +5480,12 @@ const _sfc_main$M = /* @__PURE__ */ defineComponent({
|
|
|
5478
5480
|
"aria-label": unref(l10n).clearLabel,
|
|
5479
5481
|
onClick: requestClear
|
|
5480
5482
|
}, [
|
|
5481
|
-
createElementVNode("span", _hoisted_3$
|
|
5483
|
+
createElementVNode("span", _hoisted_3$z, [
|
|
5482
5484
|
renderSlot(_ctx.$slots, "clear-icon", {}, () => [
|
|
5483
5485
|
createVNode(TaoIcon, { name: "tao-close" })
|
|
5484
5486
|
], true)
|
|
5485
5487
|
])
|
|
5486
|
-
], 8, _hoisted_2$
|
|
5488
|
+
], 8, _hoisted_2$F)) : createCommentVNode("", true),
|
|
5487
5489
|
createElementVNode("label", {
|
|
5488
5490
|
class: normalizeClass(["tao-file-drop__zone", { "tao-file-drop__zone--dragging": isDragging.value }]),
|
|
5489
5491
|
onDragover: handleDragOver,
|
|
@@ -5503,7 +5505,7 @@ const _sfc_main$M = /* @__PURE__ */ defineComponent({
|
|
|
5503
5505
|
onChange: handleFileSelect,
|
|
5504
5506
|
onClick: _cache[0] || (_cache[0] = withModifiers(() => {
|
|
5505
5507
|
}, ["stop"]))
|
|
5506
|
-
}), null, 16, _hoisted_4$
|
|
5508
|
+
}), null, 16, _hoisted_4$v)
|
|
5507
5509
|
], 34)
|
|
5508
5510
|
]),
|
|
5509
5511
|
__props.list && __props.modelValue.length ? (openBlock(), createElementBlock("ul", _hoisted_5$o, [
|
|
@@ -5620,17 +5622,17 @@ function useListNav(options) {
|
|
|
5620
5622
|
return { onKeydown: onKeydown2 };
|
|
5621
5623
|
}
|
|
5622
5624
|
const _hoisted_1$I = ["aria-label", "aria-activedescendant", "data-tao-menu-root"];
|
|
5623
|
-
const _hoisted_2$
|
|
5625
|
+
const _hoisted_2$E = {
|
|
5624
5626
|
key: 0,
|
|
5625
5627
|
class: "tao-menu__separator",
|
|
5626
5628
|
role: "separator"
|
|
5627
5629
|
};
|
|
5628
|
-
const _hoisted_3$
|
|
5630
|
+
const _hoisted_3$y = {
|
|
5629
5631
|
key: 1,
|
|
5630
5632
|
class: "tao-menu__label",
|
|
5631
5633
|
role: "presentation"
|
|
5632
5634
|
};
|
|
5633
|
-
const _hoisted_4$
|
|
5635
|
+
const _hoisted_4$u = ["id", "role", "aria-checked", "aria-disabled", "aria-haspopup", "aria-expanded", "aria-keyshortcuts", "onClick", "onMouseenter"];
|
|
5634
5636
|
const _hoisted_5$n = { class: "tao-menu__text" };
|
|
5635
5637
|
const _hoisted_6$i = {
|
|
5636
5638
|
key: 1,
|
|
@@ -5824,7 +5826,7 @@ const _sfc_main$L = /* @__PURE__ */ defineComponent({
|
|
|
5824
5826
|
return openBlock(), createElementBlock(Fragment, {
|
|
5825
5827
|
key: "id" in item ? item.id : `${item.type}-${index}`
|
|
5826
5828
|
}, [
|
|
5827
|
-
item.type === "separator" ? (openBlock(), createElementBlock("div", _hoisted_2$
|
|
5829
|
+
item.type === "separator" ? (openBlock(), createElementBlock("div", _hoisted_2$E)) : item.type === "label" ? (openBlock(), createElementBlock("div", _hoisted_3$y, toDisplayString(item.label), 1)) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
5828
5830
|
createElementVNode("div", {
|
|
5829
5831
|
id: itemId(index),
|
|
5830
5832
|
ref_for: true,
|
|
@@ -5863,7 +5865,7 @@ const _sfc_main$L = /* @__PURE__ */ defineComponent({
|
|
|
5863
5865
|
]),
|
|
5864
5866
|
"shortcut" in item && item.shortcut ? (openBlock(), createElementBlock("span", _hoisted_6$i, toDisplayString(item.shortcut), 1)) : createCommentVNode("", true),
|
|
5865
5867
|
"items" in item && item.items ? (openBlock(), createElementBlock("span", _hoisted_7$f)) : createCommentVNode("", true)
|
|
5866
|
-
], 42, _hoisted_4$
|
|
5868
|
+
], 42, _hoisted_4$u),
|
|
5867
5869
|
"items" in item && item.items && openSub.value === index ? (openBlock(), createBlock(_component_TaoMenu, {
|
|
5868
5870
|
key: 0,
|
|
5869
5871
|
items: item.items,
|
|
@@ -5883,8 +5885,8 @@ const _sfc_main$L = /* @__PURE__ */ defineComponent({
|
|
|
5883
5885
|
}
|
|
5884
5886
|
});
|
|
5885
5887
|
const _hoisted_1$H = { class: "tao-dropdown-menu" };
|
|
5886
|
-
const _hoisted_2$
|
|
5887
|
-
const _hoisted_3$
|
|
5888
|
+
const _hoisted_2$D = ["tabindex", "aria-expanded", "aria-label"];
|
|
5889
|
+
const _hoisted_3$x = {
|
|
5888
5890
|
key: 1,
|
|
5889
5891
|
"aria-hidden": "true"
|
|
5890
5892
|
};
|
|
@@ -5935,12 +5937,12 @@ const _sfc_main$K = /* @__PURE__ */ defineComponent({
|
|
|
5935
5937
|
onClick: toggleMenu,
|
|
5936
5938
|
onKeydown: onTriggerKeydown
|
|
5937
5939
|
}, [
|
|
5938
|
-
_ctx.$slots.button ? renderSlot(_ctx.$slots, "button", {}, void 0, true, 0) : (openBlock(), createElementBlock("span", _hoisted_3$
|
|
5940
|
+
_ctx.$slots.button ? renderSlot(_ctx.$slots, "button", {}, void 0, true, 0) : (openBlock(), createElementBlock("span", _hoisted_3$x, [
|
|
5939
5941
|
renderSlot(_ctx.$slots, "icon", {}, () => [
|
|
5940
5942
|
createVNode(TaoIcon, { name: "tao-more-vertical" })
|
|
5941
5943
|
], true)
|
|
5942
5944
|
]))
|
|
5943
|
-
], 42, _hoisted_2$
|
|
5945
|
+
], 42, _hoisted_2$D),
|
|
5944
5946
|
createVNode(_sfc_main$L, {
|
|
5945
5947
|
items: __props.items,
|
|
5946
5948
|
open: isOpen.value,
|
|
@@ -6041,7 +6043,7 @@ const _sfc_main$J = /* @__PURE__ */ defineComponent({
|
|
|
6041
6043
|
});
|
|
6042
6044
|
const TaoContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$J, [["__scopeId", "data-v-65a7f071"]]);
|
|
6043
6045
|
const _hoisted_1$G = ["aria-label"];
|
|
6044
|
-
const _hoisted_2$
|
|
6046
|
+
const _hoisted_2$C = ["tabindex", "aria-haspopup", "aria-expanded", "aria-disabled", "onClick", "onKeydown", "onMouseenter", "onFocus"];
|
|
6045
6047
|
const _sfc_main$I = /* @__PURE__ */ defineComponent({
|
|
6046
6048
|
...{ name: "TaoMenubar" },
|
|
6047
6049
|
__name: "TaoMenubar",
|
|
@@ -6172,7 +6174,7 @@ const _sfc_main$I = /* @__PURE__ */ defineComponent({
|
|
|
6172
6174
|
onKeydown: ($event) => onKeydown2($event, index),
|
|
6173
6175
|
onMouseenter: ($event) => onEnter(index),
|
|
6174
6176
|
onFocus: ($event) => current2.value = index
|
|
6175
|
-
}, toDisplayString(entry.label), 43, _hoisted_2$
|
|
6177
|
+
}, toDisplayString(entry.label), 43, _hoisted_2$C),
|
|
6176
6178
|
hasMenu(index) ? (openBlock(), createBlock(_sfc_main$L, {
|
|
6177
6179
|
key: 0,
|
|
6178
6180
|
items: entry.items,
|
|
@@ -6201,10 +6203,41 @@ const _sfc_main$I = /* @__PURE__ */ defineComponent({
|
|
|
6201
6203
|
});
|
|
6202
6204
|
const TaoMenubar = /* @__PURE__ */ _export_sfc(_sfc_main$I, [["__scopeId", "data-v-446c1c49"]]);
|
|
6203
6205
|
const toolbarKey = Symbol("tao-toolbar");
|
|
6206
|
+
function planOverflow(entries, available, gap, moreWidth) {
|
|
6207
|
+
const away = /* @__PURE__ */ new Set();
|
|
6208
|
+
const widthOf = (hidden) => {
|
|
6209
|
+
let count = 0;
|
|
6210
|
+
let sum = 0;
|
|
6211
|
+
entries.forEach((entry, i) => {
|
|
6212
|
+
if (!hidden.has(i)) {
|
|
6213
|
+
count += 1;
|
|
6214
|
+
sum += entry.width;
|
|
6215
|
+
}
|
|
6216
|
+
});
|
|
6217
|
+
return sum + gap * Math.max(0, count - 1) + (hidden.size ? gap + moreWidth : 0);
|
|
6218
|
+
};
|
|
6219
|
+
if (widthOf(away) <= available) {
|
|
6220
|
+
return away;
|
|
6221
|
+
}
|
|
6222
|
+
for (let i = entries.length - 1; i >= 0; i -= 1) {
|
|
6223
|
+
const entry = entries[i];
|
|
6224
|
+
if (entry.kind !== "group" || entry.pinned) {
|
|
6225
|
+
continue;
|
|
6226
|
+
}
|
|
6227
|
+
away.add(i);
|
|
6228
|
+
if (entries[i - 1]?.kind === "separator") {
|
|
6229
|
+
away.add(i - 1);
|
|
6230
|
+
}
|
|
6231
|
+
if (widthOf(away) <= available) {
|
|
6232
|
+
break;
|
|
6233
|
+
}
|
|
6234
|
+
}
|
|
6235
|
+
return away;
|
|
6236
|
+
}
|
|
6204
6237
|
const ITEMS = 'button, a[href], input, select, textarea, [role="button"], [data-tao-toolbar-item]';
|
|
6205
6238
|
const TEXT_INPUT = /^(text|search|email|url|tel|password|number|date|time|datetime-local|month|week)$/;
|
|
6206
6239
|
function usable(el) {
|
|
6207
|
-
if (el.disabled || el.getAttribute("aria-disabled") === "true" || el.hidden) {
|
|
6240
|
+
if (el.disabled || el.getAttribute("aria-disabled") === "true" || el.closest("[hidden], [data-tao-away]")) {
|
|
6208
6241
|
return false;
|
|
6209
6242
|
}
|
|
6210
6243
|
return !el.parentElement?.closest(ITEMS);
|
|
@@ -6253,6 +6286,9 @@ function isTextField(el) {
|
|
|
6253
6286
|
return el instanceof HTMLInputElement && TEXT_INPUT.test(el.type);
|
|
6254
6287
|
}
|
|
6255
6288
|
const _hoisted_1$F = ["aria-label", "aria-orientation"];
|
|
6289
|
+
const _hoisted_2$B = ["data-tao-away"];
|
|
6290
|
+
const _hoisted_3$w = ["aria-label"];
|
|
6291
|
+
const _hoisted_4$t = ["aria-label"];
|
|
6256
6292
|
const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
6257
6293
|
...{ name: "TaoToolbar" },
|
|
6258
6294
|
__name: "TaoToolbar",
|
|
@@ -6261,133 +6297,480 @@ const _sfc_main$H = /* @__PURE__ */ defineComponent({
|
|
|
6261
6297
|
size: { default: void 0 },
|
|
6262
6298
|
orientation: { default: "horizontal" },
|
|
6263
6299
|
variant: { default: "panel" },
|
|
6264
|
-
bordered: { type: Boolean, default: void 0 }
|
|
6300
|
+
bordered: { type: Boolean, default: void 0 },
|
|
6301
|
+
overflow: { type: Boolean, default: false },
|
|
6302
|
+
overflowLabel: { default: void 0 }
|
|
6265
6303
|
},
|
|
6266
|
-
setup(__props) {
|
|
6304
|
+
setup(__props, { expose: __expose }) {
|
|
6267
6305
|
const props = __props;
|
|
6268
|
-
|
|
6306
|
+
const l10n = useLocaleText(props, "toolbar");
|
|
6307
|
+
const managed = computed(() => props.overflow && props.orientation === "horizontal");
|
|
6269
6308
|
const root = ref(null);
|
|
6270
|
-
|
|
6271
|
-
|
|
6272
|
-
|
|
6273
|
-
|
|
6274
|
-
|
|
6309
|
+
const moreHost = ref(null);
|
|
6310
|
+
const panel = ref(null);
|
|
6311
|
+
const menuEl = ref(null);
|
|
6312
|
+
function createRoving(getRoot) {
|
|
6313
|
+
let current2 = 0;
|
|
6314
|
+
function refresh() {
|
|
6315
|
+
const el = getRoot();
|
|
6316
|
+
if (!el) {
|
|
6317
|
+
return;
|
|
6318
|
+
}
|
|
6319
|
+
const stops = toolbarStops(el);
|
|
6320
|
+
current2 = Math.min(current2, Math.max(0, stops.length - 1));
|
|
6321
|
+
applyRoving(stops, current2);
|
|
6275
6322
|
}
|
|
6276
|
-
|
|
6277
|
-
|
|
6278
|
-
|
|
6279
|
-
|
|
6280
|
-
|
|
6281
|
-
|
|
6282
|
-
|
|
6323
|
+
function onFocusin(event) {
|
|
6324
|
+
const el = getRoot();
|
|
6325
|
+
if (!el) {
|
|
6326
|
+
return;
|
|
6327
|
+
}
|
|
6328
|
+
const stops = toolbarStops(el);
|
|
6329
|
+
const index = stops.findIndex((stop) => stop.els.includes(event.target));
|
|
6330
|
+
if (index !== -1 && index !== current2) {
|
|
6331
|
+
current2 = index;
|
|
6332
|
+
applyRoving(stops, current2);
|
|
6333
|
+
}
|
|
6334
|
+
}
|
|
6335
|
+
function onKeydown2(event) {
|
|
6336
|
+
const el = getRoot();
|
|
6337
|
+
if (!el || event.altKey || event.ctrlKey || event.metaKey || isTextField(event.target)) {
|
|
6338
|
+
return;
|
|
6339
|
+
}
|
|
6340
|
+
const vertical = props.orientation === "vertical";
|
|
6341
|
+
const next = vertical ? "ArrowDown" : "ArrowRight";
|
|
6342
|
+
const prev = vertical ? "ArrowUp" : "ArrowLeft";
|
|
6343
|
+
if (![next, prev, "Home", "End"].includes(event.key)) {
|
|
6344
|
+
return;
|
|
6345
|
+
}
|
|
6346
|
+
const stops = toolbarStops(el);
|
|
6347
|
+
const target = event.target;
|
|
6348
|
+
const index = stops.findIndex((stop2) => stop2.els.includes(target));
|
|
6349
|
+
if (index === -1) {
|
|
6350
|
+
return;
|
|
6351
|
+
}
|
|
6352
|
+
const stop = stops[index];
|
|
6353
|
+
if (isRadio(target) && (event.key === next || event.key === prev)) {
|
|
6354
|
+
const edge = event.key === next ? stop.els[stop.els.length - 1] : stop.els[0];
|
|
6355
|
+
if (target !== edge) {
|
|
6356
|
+
return;
|
|
6357
|
+
}
|
|
6358
|
+
}
|
|
6359
|
+
let to;
|
|
6360
|
+
if (event.key === "Home") {
|
|
6361
|
+
to = 0;
|
|
6362
|
+
} else if (event.key === "End") {
|
|
6363
|
+
to = stops.length - 1;
|
|
6364
|
+
} else {
|
|
6365
|
+
to = (index + (event.key === next ? 1 : -1) + stops.length) % stops.length;
|
|
6366
|
+
}
|
|
6367
|
+
event.preventDefault();
|
|
6368
|
+
current2 = to;
|
|
6369
|
+
applyRoving(stops, current2);
|
|
6370
|
+
stopTarget(stops[to]).focus();
|
|
6283
6371
|
}
|
|
6284
|
-
|
|
6285
|
-
|
|
6286
|
-
|
|
6287
|
-
|
|
6372
|
+
function focusFirst() {
|
|
6373
|
+
const el = getRoot();
|
|
6374
|
+
const stops = el ? toolbarStops(el) : [];
|
|
6375
|
+
if (!stops.length) {
|
|
6376
|
+
return false;
|
|
6377
|
+
}
|
|
6378
|
+
current2 = 0;
|
|
6288
6379
|
applyRoving(stops, current2);
|
|
6380
|
+
stopTarget(stops[0]).focus({ preventScroll: true });
|
|
6381
|
+
return true;
|
|
6289
6382
|
}
|
|
6383
|
+
return { refresh, onFocusin, onKeydown: onKeydown2, focusFirst };
|
|
6290
6384
|
}
|
|
6291
|
-
|
|
6292
|
-
|
|
6385
|
+
const bar = createRoving(() => root.value);
|
|
6386
|
+
const menu = createRoving(() => menuEl.value);
|
|
6387
|
+
const units = [];
|
|
6388
|
+
const anyAway = ref(false);
|
|
6389
|
+
const open = ref(false);
|
|
6390
|
+
const panelSize = ref("medium");
|
|
6391
|
+
const panelDensity = ref("default");
|
|
6392
|
+
let moreWidth = 0;
|
|
6393
|
+
let measureQueued = false;
|
|
6394
|
+
let resizeObserver;
|
|
6395
|
+
function register(unit) {
|
|
6396
|
+
units.push(unit);
|
|
6397
|
+
schedule();
|
|
6398
|
+
return () => {
|
|
6399
|
+
units.splice(units.indexOf(unit), 1);
|
|
6400
|
+
schedule();
|
|
6401
|
+
};
|
|
6402
|
+
}
|
|
6403
|
+
provide(toolbarKey, { orientation: toRef(props, "orientation"), overflow: managed, menuEl, register });
|
|
6404
|
+
function outerWidth(el) {
|
|
6405
|
+
const rect = el.getBoundingClientRect();
|
|
6406
|
+
const style = getComputedStyle(el);
|
|
6407
|
+
return rect.width + (parseFloat(style.marginLeft) || 0) + (parseFloat(style.marginRight) || 0);
|
|
6408
|
+
}
|
|
6409
|
+
function observeUnits() {
|
|
6410
|
+
if (!resizeObserver) {
|
|
6293
6411
|
return;
|
|
6294
6412
|
}
|
|
6295
|
-
const
|
|
6296
|
-
|
|
6297
|
-
|
|
6298
|
-
|
|
6299
|
-
|
|
6413
|
+
for (const unit of units) {
|
|
6414
|
+
const target = unit.kind === "group" ? unit.el.value?.firstElementChild : unit.el.value;
|
|
6415
|
+
if (target) {
|
|
6416
|
+
resizeObserver.observe(target);
|
|
6417
|
+
}
|
|
6300
6418
|
}
|
|
6301
|
-
|
|
6302
|
-
|
|
6303
|
-
const
|
|
6304
|
-
if (
|
|
6419
|
+
}
|
|
6420
|
+
async function measure() {
|
|
6421
|
+
const el = root.value;
|
|
6422
|
+
if (!managed.value || !el || el.clientWidth === 0) {
|
|
6305
6423
|
return;
|
|
6306
6424
|
}
|
|
6307
|
-
const
|
|
6308
|
-
|
|
6309
|
-
|
|
6310
|
-
|
|
6425
|
+
const style = getComputedStyle(el);
|
|
6426
|
+
const gap = parseFloat(style.columnGap) || 0;
|
|
6427
|
+
const available = el.clientWidth - (parseFloat(style.paddingLeft) || 0) - (parseFloat(style.paddingRight) || 0);
|
|
6428
|
+
if (moreHost.value && !moreHost.value.hasAttribute("data-tao-away")) {
|
|
6429
|
+
moreWidth = outerWidth(moreHost.value);
|
|
6430
|
+
}
|
|
6431
|
+
const more = moreWidth || parseFloat(style.getPropertyValue("--tao-control-height")) || 36;
|
|
6432
|
+
const found = [];
|
|
6433
|
+
const entries = [];
|
|
6434
|
+
for (const child of Array.from(el.children)) {
|
|
6435
|
+
if (child === moreHost.value) {
|
|
6436
|
+
continue;
|
|
6437
|
+
}
|
|
6438
|
+
const unit = units.find((u) => u.el.value === child);
|
|
6439
|
+
if (unit) {
|
|
6440
|
+
const inner = unit.kind === "group" ? child.firstElementChild : child;
|
|
6441
|
+
if (!unit.away.value && inner instanceof HTMLElement) {
|
|
6442
|
+
unit.width = outerWidth(inner);
|
|
6443
|
+
}
|
|
6444
|
+
found.push({ unit });
|
|
6445
|
+
entries.push({ kind: unit.kind, width: unit.width, pinned: unit.pinned.value });
|
|
6446
|
+
} else {
|
|
6447
|
+
const width = outerWidth(child);
|
|
6448
|
+
if (width > 0) {
|
|
6449
|
+
found.push({});
|
|
6450
|
+
entries.push({ kind: "loose", width });
|
|
6451
|
+
}
|
|
6452
|
+
}
|
|
6453
|
+
}
|
|
6454
|
+
const plan = planOverflow(entries, available, gap, more);
|
|
6455
|
+
const active = document.activeElement;
|
|
6456
|
+
const hadFocus = Boolean(active && active !== document.body && (el.contains(active) || panel.value?.contains(active)));
|
|
6457
|
+
let order = 0;
|
|
6458
|
+
found.forEach(({ unit }, i) => {
|
|
6459
|
+
if (!unit) {
|
|
6311
6460
|
return;
|
|
6312
6461
|
}
|
|
6462
|
+
const away = plan.has(i);
|
|
6463
|
+
if (unit.away.value !== away) {
|
|
6464
|
+
unit.away.value = away;
|
|
6465
|
+
}
|
|
6466
|
+
if (away && unit.kind === "group") {
|
|
6467
|
+
unit.order.value = order;
|
|
6468
|
+
unit.first.value = order === 0;
|
|
6469
|
+
order += 1;
|
|
6470
|
+
}
|
|
6471
|
+
});
|
|
6472
|
+
if (anyAway.value !== plan.size > 0) {
|
|
6473
|
+
anyAway.value = plan.size > 0;
|
|
6313
6474
|
}
|
|
6314
|
-
|
|
6315
|
-
|
|
6316
|
-
|
|
6317
|
-
|
|
6318
|
-
|
|
6475
|
+
observeUnits();
|
|
6476
|
+
await nextTick();
|
|
6477
|
+
const now = document.activeElement;
|
|
6478
|
+
if (hadFocus && (!now || now === document.body || now.closest("[data-tao-away]"))) {
|
|
6479
|
+
const button = moreHost.value?.querySelector("button");
|
|
6480
|
+
if (anyAway.value && button) {
|
|
6481
|
+
button.focus({ preventScroll: true });
|
|
6482
|
+
} else {
|
|
6483
|
+
bar.focusFirst();
|
|
6484
|
+
}
|
|
6485
|
+
}
|
|
6486
|
+
bar.refresh();
|
|
6487
|
+
menu.refresh();
|
|
6488
|
+
if (moreHost.value && !moreHost.value.hasAttribute("data-tao-away") && outerWidth(moreHost.value) !== moreWidth) {
|
|
6489
|
+
schedule();
|
|
6490
|
+
}
|
|
6491
|
+
}
|
|
6492
|
+
function schedule() {
|
|
6493
|
+
if (measureQueued || typeof window === "undefined") {
|
|
6494
|
+
return;
|
|
6495
|
+
}
|
|
6496
|
+
measureQueued = true;
|
|
6497
|
+
void nextTick(() => {
|
|
6498
|
+
measureQueued = false;
|
|
6499
|
+
void measure();
|
|
6500
|
+
});
|
|
6501
|
+
}
|
|
6502
|
+
function reset() {
|
|
6503
|
+
open.value = false;
|
|
6504
|
+
for (const unit of units) {
|
|
6505
|
+
unit.away.value = false;
|
|
6506
|
+
}
|
|
6507
|
+
anyAway.value = false;
|
|
6508
|
+
}
|
|
6509
|
+
async function remeasureAll() {
|
|
6510
|
+
reset();
|
|
6511
|
+
await nextTick();
|
|
6512
|
+
void measure();
|
|
6513
|
+
}
|
|
6514
|
+
watch(managed, (on) => {
|
|
6515
|
+
if (on) {
|
|
6516
|
+
schedule();
|
|
6319
6517
|
} else {
|
|
6320
|
-
|
|
6518
|
+
reset();
|
|
6321
6519
|
}
|
|
6322
|
-
|
|
6323
|
-
|
|
6324
|
-
|
|
6325
|
-
|
|
6520
|
+
});
|
|
6521
|
+
watch(() => props.size, () => managed.value && void remeasureAll());
|
|
6522
|
+
watch(anyAway, (any) => {
|
|
6523
|
+
if (!any) {
|
|
6524
|
+
open.value = false;
|
|
6525
|
+
}
|
|
6526
|
+
});
|
|
6527
|
+
function focusMore() {
|
|
6528
|
+
moreHost.value?.querySelector("button")?.focus();
|
|
6529
|
+
}
|
|
6530
|
+
function close() {
|
|
6531
|
+
open.value = false;
|
|
6532
|
+
}
|
|
6533
|
+
function toggle() {
|
|
6534
|
+
open.value = !open.value;
|
|
6535
|
+
}
|
|
6536
|
+
const { style: panelStyle, update } = useFloating(moreHost, panel, open, { placement: "bottom-end" });
|
|
6537
|
+
const layer = useLayer(open, {
|
|
6538
|
+
onEscape: () => {
|
|
6539
|
+
close();
|
|
6540
|
+
focusMore();
|
|
6541
|
+
}
|
|
6542
|
+
});
|
|
6543
|
+
useDismiss(
|
|
6544
|
+
open,
|
|
6545
|
+
() => [
|
|
6546
|
+
moreHost.value,
|
|
6547
|
+
panel.value,
|
|
6548
|
+
...layer.isTop() ? Array.from(document.querySelectorAll("[data-tao-keep-open]")) : [document.body]
|
|
6549
|
+
],
|
|
6550
|
+
close
|
|
6551
|
+
);
|
|
6552
|
+
watch(open, async (isOpen) => {
|
|
6553
|
+
if (!isOpen) {
|
|
6554
|
+
return;
|
|
6555
|
+
}
|
|
6556
|
+
panelSize.value = resolveSize(root.value);
|
|
6557
|
+
panelDensity.value = resolveDensity(root.value);
|
|
6558
|
+
await nextTick();
|
|
6559
|
+
await nextTick();
|
|
6560
|
+
menu.refresh();
|
|
6561
|
+
update();
|
|
6562
|
+
if (!menu.focusFirst()) {
|
|
6563
|
+
panel.value?.focus({ preventScroll: true });
|
|
6564
|
+
}
|
|
6565
|
+
});
|
|
6566
|
+
let menuObserver;
|
|
6567
|
+
watch(menuEl, (el) => {
|
|
6568
|
+
menuObserver?.disconnect();
|
|
6569
|
+
menuObserver = void 0;
|
|
6570
|
+
if (el && typeof MutationObserver !== "undefined") {
|
|
6571
|
+
menuObserver = new MutationObserver(() => menu.refresh());
|
|
6572
|
+
menuObserver.observe(el, { childList: true, subtree: true, attributeFilter: ["disabled", "aria-disabled"] });
|
|
6573
|
+
}
|
|
6574
|
+
});
|
|
6575
|
+
async function reveal(el) {
|
|
6576
|
+
if (root.value?.contains(el) && el.closest("[data-tao-away]")) {
|
|
6577
|
+
open.value = true;
|
|
6578
|
+
await nextTick();
|
|
6579
|
+
await nextTick();
|
|
6580
|
+
}
|
|
6581
|
+
return el;
|
|
6326
6582
|
}
|
|
6583
|
+
__expose({ reveal });
|
|
6584
|
+
let observer;
|
|
6327
6585
|
onMounted(() => {
|
|
6328
|
-
refresh();
|
|
6586
|
+
bar.refresh();
|
|
6329
6587
|
if (typeof MutationObserver !== "undefined" && root.value) {
|
|
6330
|
-
observer = new MutationObserver(
|
|
6588
|
+
observer = new MutationObserver(() => {
|
|
6589
|
+
bar.refresh();
|
|
6590
|
+
if (managed.value) {
|
|
6591
|
+
schedule();
|
|
6592
|
+
}
|
|
6593
|
+
});
|
|
6331
6594
|
observer.observe(root.value, { childList: true, subtree: true, attributeFilter: ["disabled", "aria-disabled"] });
|
|
6332
6595
|
}
|
|
6596
|
+
if (typeof ResizeObserver !== "undefined" && root.value) {
|
|
6597
|
+
resizeObserver = new ResizeObserver(() => schedule());
|
|
6598
|
+
resizeObserver.observe(root.value);
|
|
6599
|
+
}
|
|
6600
|
+
if (managed.value) {
|
|
6601
|
+
void measure();
|
|
6602
|
+
}
|
|
6603
|
+
});
|
|
6604
|
+
onBeforeUnmount(() => {
|
|
6605
|
+
observer?.disconnect();
|
|
6606
|
+
menuObserver?.disconnect();
|
|
6607
|
+
resizeObserver?.disconnect();
|
|
6333
6608
|
});
|
|
6334
|
-
onBeforeUnmount(() => observer?.disconnect());
|
|
6335
6609
|
return (_ctx, _cache) => {
|
|
6336
6610
|
return openBlock(), createElementBlock("div", {
|
|
6337
6611
|
ref_key: "root",
|
|
6338
6612
|
ref: root,
|
|
6339
|
-
class: normalizeClass(["tao-toolbar", [unref(sizeClass)(__props.size), `tao-toolbar--${__props.variant}`, `tao-toolbar--${__props.orientation}
|
|
6613
|
+
class: normalizeClass(["tao-toolbar", [unref(sizeClass)(__props.size), `tao-toolbar--${__props.variant}`, `tao-toolbar--${__props.orientation}`, { "tao-toolbar--overflow": managed.value }]]),
|
|
6340
6614
|
role: "toolbar",
|
|
6341
6615
|
"aria-label": __props.label,
|
|
6342
6616
|
"aria-orientation": __props.orientation,
|
|
6343
6617
|
style: normalizeStyle(unref(frameStyle)(__props.bordered)),
|
|
6344
|
-
onFocusin
|
|
6345
|
-
|
|
6618
|
+
onFocusin: _cache[2] || (_cache[2] = //@ts-ignore
|
|
6619
|
+
(...args) => unref(bar).onFocusin && unref(bar).onFocusin(...args)),
|
|
6620
|
+
onKeydown: _cache[3] || (_cache[3] = //@ts-ignore
|
|
6621
|
+
(...args) => unref(bar).onKeydown && unref(bar).onKeydown(...args))
|
|
6346
6622
|
}, [
|
|
6347
|
-
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
6623
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true),
|
|
6624
|
+
managed.value ? (openBlock(), createElementBlock("div", {
|
|
6625
|
+
key: 0,
|
|
6626
|
+
ref_key: "moreHost",
|
|
6627
|
+
ref: moreHost,
|
|
6628
|
+
class: "tao-toolbar__more",
|
|
6629
|
+
"data-tao-away": anyAway.value ? void 0 : ""
|
|
6630
|
+
}, [
|
|
6631
|
+
createVNode(TaoButton, {
|
|
6632
|
+
variant: "ghost",
|
|
6633
|
+
tone: "neutral",
|
|
6634
|
+
icon: "tao-more-vertical",
|
|
6635
|
+
"aria-label": __props.overflowLabel ?? unref(l10n).overflowLabel,
|
|
6636
|
+
"aria-haspopup": "dialog",
|
|
6637
|
+
"aria-expanded": open.value,
|
|
6638
|
+
onClick: toggle
|
|
6639
|
+
}, null, 8, ["aria-label", "aria-expanded"])
|
|
6640
|
+
], 8, _hoisted_2$B)) : createCommentVNode("", true),
|
|
6641
|
+
managed.value ? (openBlock(), createBlock(Teleport, {
|
|
6642
|
+
key: 1,
|
|
6643
|
+
to: "body"
|
|
6644
|
+
}, [
|
|
6645
|
+
open.value && anyAway.value ? (openBlock(), createElementBlock("div", {
|
|
6646
|
+
key: 0,
|
|
6647
|
+
ref_key: "panel",
|
|
6648
|
+
ref: panel,
|
|
6649
|
+
class: normalizeClass(["tao-toolbar__menu", [unref(sizeClass)(panelSize.value), unref(densityClass)(panelDensity.value)]]),
|
|
6650
|
+
role: "dialog",
|
|
6651
|
+
tabindex: "-1",
|
|
6652
|
+
"aria-label": __props.overflowLabel ?? unref(l10n).overflowLabel,
|
|
6653
|
+
style: normalizeStyle(unref(panelStyle))
|
|
6654
|
+
}, [
|
|
6655
|
+
createElementVNode("div", {
|
|
6656
|
+
ref_key: "menuEl",
|
|
6657
|
+
ref: menuEl,
|
|
6658
|
+
class: "tao-toolbar__menu-body",
|
|
6659
|
+
role: "toolbar",
|
|
6660
|
+
"aria-label": __props.overflowLabel ?? unref(l10n).overflowLabel,
|
|
6661
|
+
onFocusin: _cache[0] || (_cache[0] = //@ts-ignore
|
|
6662
|
+
(...args) => unref(menu).onFocusin && unref(menu).onFocusin(...args)),
|
|
6663
|
+
onKeydown: _cache[1] || (_cache[1] = //@ts-ignore
|
|
6664
|
+
(...args) => unref(menu).onKeydown && unref(menu).onKeydown(...args))
|
|
6665
|
+
}, null, 40, _hoisted_4$t)
|
|
6666
|
+
], 14, _hoisted_3$w)) : createCommentVNode("", true)
|
|
6667
|
+
])) : createCommentVNode("", true)
|
|
6348
6668
|
], 46, _hoisted_1$F);
|
|
6349
6669
|
};
|
|
6350
6670
|
}
|
|
6351
6671
|
});
|
|
6352
|
-
const TaoToolbar = /* @__PURE__ */ _export_sfc(_sfc_main$H, [["__scopeId", "data-v-
|
|
6672
|
+
const TaoToolbar = /* @__PURE__ */ _export_sfc(_sfc_main$H, [["__scopeId", "data-v-27fec442"]]);
|
|
6353
6673
|
const _hoisted_1$E = ["aria-label"];
|
|
6674
|
+
const _hoisted_2$A = ["data-tao-away", "hidden"];
|
|
6675
|
+
const _hoisted_3$v = ["aria-label"];
|
|
6354
6676
|
const _sfc_main$G = /* @__PURE__ */ defineComponent({
|
|
6355
|
-
...{ name: "TaoToolbarGroup" },
|
|
6677
|
+
...{ name: "TaoToolbarGroup", inheritAttrs: false },
|
|
6356
6678
|
__name: "TaoToolbarGroup",
|
|
6357
6679
|
props: {
|
|
6358
6680
|
label: { default: void 0 },
|
|
6359
|
-
inset: { type: Boolean, default: false }
|
|
6681
|
+
inset: { type: Boolean, default: false },
|
|
6682
|
+
pinned: { type: Boolean, default: false }
|
|
6360
6683
|
},
|
|
6361
6684
|
setup(__props) {
|
|
6685
|
+
const props = __props;
|
|
6686
|
+
const toolbar = inject(toolbarKey, null);
|
|
6687
|
+
const managed = computed(() => Boolean(toolbar?.overflow.value));
|
|
6688
|
+
const host = ref(null);
|
|
6689
|
+
const unit = {
|
|
6690
|
+
kind: "group",
|
|
6691
|
+
el: host,
|
|
6692
|
+
pinned: toRef(props, "pinned"),
|
|
6693
|
+
away: ref(false),
|
|
6694
|
+
order: ref(0),
|
|
6695
|
+
first: ref(false),
|
|
6696
|
+
width: 0
|
|
6697
|
+
};
|
|
6698
|
+
let unregister;
|
|
6699
|
+
onMounted(() => {
|
|
6700
|
+
unregister = toolbar?.register(unit);
|
|
6701
|
+
});
|
|
6702
|
+
onBeforeUnmount(() => unregister?.());
|
|
6703
|
+
const inMenu = computed(() => unit.away.value && Boolean(toolbar?.menuEl.value));
|
|
6704
|
+
const target = computed(() => toolbar?.menuEl.value ?? "body");
|
|
6362
6705
|
return (_ctx, _cache) => {
|
|
6363
|
-
return openBlock(), createElementBlock("div", {
|
|
6364
|
-
|
|
6706
|
+
return !managed.value ? (openBlock(), createElementBlock("div", mergeProps({
|
|
6707
|
+
key: 0,
|
|
6708
|
+
class: ["tao-toolbar-group", { "tao-toolbar-group--inset": __props.inset }],
|
|
6365
6709
|
role: "group",
|
|
6366
6710
|
"aria-label": __props.label
|
|
6367
|
-
}, [
|
|
6711
|
+
}, _ctx.$attrs), [
|
|
6368
6712
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
6369
|
-
],
|
|
6713
|
+
], 16, _hoisted_1$E)) : (openBlock(), createElementBlock("div", {
|
|
6714
|
+
key: 1,
|
|
6715
|
+
ref_key: "host",
|
|
6716
|
+
ref: host,
|
|
6717
|
+
class: "tao-toolbar-host",
|
|
6718
|
+
"data-tao-away": unit.away.value ? "" : void 0,
|
|
6719
|
+
hidden: unit.away.value && !inMenu.value ? true : void 0
|
|
6720
|
+
}, [
|
|
6721
|
+
(openBlock(), createBlock(Teleport, {
|
|
6722
|
+
to: target.value,
|
|
6723
|
+
disabled: !inMenu.value
|
|
6724
|
+
}, [
|
|
6725
|
+
createElementVNode("div", mergeProps({
|
|
6726
|
+
class: ["tao-toolbar-group", { "tao-toolbar-group--inset": __props.inset, "tao-toolbar-group--menu": inMenu.value, "tao-toolbar-group--menu-first": inMenu.value && unit.first.value }],
|
|
6727
|
+
style: inMenu.value ? { order: unit.order.value } : void 0,
|
|
6728
|
+
role: "group",
|
|
6729
|
+
"aria-label": __props.label
|
|
6730
|
+
}, _ctx.$attrs), [
|
|
6731
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
6732
|
+
], 16, _hoisted_3$v)
|
|
6733
|
+
], 8, ["to", "disabled"]))
|
|
6734
|
+
], 8, _hoisted_2$A));
|
|
6370
6735
|
};
|
|
6371
6736
|
}
|
|
6372
6737
|
});
|
|
6373
|
-
const TaoToolbarGroup = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["__scopeId", "data-v-
|
|
6374
|
-
const _hoisted_1$D = ["aria-orientation"];
|
|
6738
|
+
const TaoToolbarGroup = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["__scopeId", "data-v-61688996"]]);
|
|
6739
|
+
const _hoisted_1$D = ["aria-orientation", "data-tao-away"];
|
|
6375
6740
|
const _sfc_main$F = /* @__PURE__ */ defineComponent({
|
|
6376
6741
|
...{ name: "TaoToolbarSeparator" },
|
|
6377
6742
|
__name: "TaoToolbarSeparator",
|
|
6378
6743
|
setup(__props) {
|
|
6379
6744
|
const toolbar = inject(toolbarKey, null);
|
|
6380
6745
|
const orientation = computed(() => toolbar?.orientation.value === "vertical" ? "horizontal" : "vertical");
|
|
6746
|
+
const el = ref(null);
|
|
6747
|
+
const unit = {
|
|
6748
|
+
kind: "separator",
|
|
6749
|
+
el,
|
|
6750
|
+
pinned: ref(false),
|
|
6751
|
+
away: ref(false),
|
|
6752
|
+
order: ref(0),
|
|
6753
|
+
first: ref(false),
|
|
6754
|
+
width: 0
|
|
6755
|
+
};
|
|
6756
|
+
let unregister;
|
|
6757
|
+
onMounted(() => {
|
|
6758
|
+
unregister = toolbar?.register(unit);
|
|
6759
|
+
});
|
|
6760
|
+
onBeforeUnmount(() => unregister?.());
|
|
6381
6761
|
return (_ctx, _cache) => {
|
|
6382
6762
|
return openBlock(), createElementBlock("div", {
|
|
6763
|
+
ref_key: "el",
|
|
6764
|
+
ref: el,
|
|
6383
6765
|
class: normalizeClass(["tao-toolbar-separator", `tao-toolbar-separator--${orientation.value}`]),
|
|
6384
6766
|
role: "separator",
|
|
6385
|
-
"aria-orientation": orientation.value
|
|
6767
|
+
"aria-orientation": orientation.value,
|
|
6768
|
+
"data-tao-away": unit.away.value ? "" : void 0
|
|
6386
6769
|
}, null, 10, _hoisted_1$D);
|
|
6387
6770
|
};
|
|
6388
6771
|
}
|
|
6389
6772
|
});
|
|
6390
|
-
const TaoToolbarSeparator = /* @__PURE__ */ _export_sfc(_sfc_main$F, [["__scopeId", "data-v-
|
|
6773
|
+
const TaoToolbarSeparator = /* @__PURE__ */ _export_sfc(_sfc_main$F, [["__scopeId", "data-v-3555f99a"]]);
|
|
6391
6774
|
const TAO_CHART_COLORS = 6;
|
|
6392
6775
|
const chartColorVar = (index) => `var(--tao-color-chart-${index % TAO_CHART_COLORS + 1})`;
|
|
6393
6776
|
const finite = (v) => typeof v === "number" && Number.isFinite(v);
|