@dskripchenko/ui 1.2.2 → 1.3.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/README.md +2 -2
- package/dist/components/Drawer/UidDrawer.vue.d.ts +5 -2
- package/dist/components/Modal/UidModal.vue.d.ts +5 -2
- package/dist/components/Stepper/UidStepper.vue.d.ts +11 -1
- package/dist/components/Table/UidTable.vue.d.ts +3 -3
- package/dist/components/TreeView/UidTreeView.vue.d.ts +4 -3
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +43 -18
- package/dist/styles/all.css +1 -1
- package/dist/styles/index.css +1 -1
- package/package.json +15 -16
- package/README.de.md +0 -145
- package/README.ru.md +0 -143
- package/README.zh.md +0 -145
package/dist/index.mjs
CHANGED
|
@@ -1170,6 +1170,10 @@ var vn = ["aria-labelledby"], yn = { class: "uid-modal__header" }, bn = ["id"],
|
|
|
1170
1170
|
type: Boolean,
|
|
1171
1171
|
default: !0
|
|
1172
1172
|
},
|
|
1173
|
+
closeOnEsc: {
|
|
1174
|
+
type: Boolean,
|
|
1175
|
+
default: !0
|
|
1176
|
+
},
|
|
1173
1177
|
hideClose: {
|
|
1174
1178
|
type: Boolean,
|
|
1175
1179
|
default: !1
|
|
@@ -1194,7 +1198,7 @@ var vn = ["aria-labelledby"], yn = { class: "uid-modal__header" }, bn = ["id"],
|
|
|
1194
1198
|
e ? (b(), await g(), v(), document.addEventListener("keydown", D)) : (S(), y(), document.removeEventListener("keydown", D));
|
|
1195
1199
|
});
|
|
1196
1200
|
function D(e) {
|
|
1197
|
-
e.key === "Escape" && C();
|
|
1201
|
+
e.key === "Escape" && f.closeOnEsc && C();
|
|
1198
1202
|
}
|
|
1199
1203
|
return (i, f) => (x(), o(n, { to: "body" }, [d(r, { name: "uid-modal" }, {
|
|
1200
1204
|
default: z(() => [u.value ? (x(), c("div", {
|
|
@@ -1242,6 +1246,10 @@ var vn = ["aria-labelledby"], yn = { class: "uid-modal__header" }, bn = ["id"],
|
|
|
1242
1246
|
type: Boolean,
|
|
1243
1247
|
default: !0
|
|
1244
1248
|
},
|
|
1249
|
+
closeOnEsc: {
|
|
1250
|
+
type: Boolean,
|
|
1251
|
+
default: !0
|
|
1252
|
+
},
|
|
1245
1253
|
hideClose: {
|
|
1246
1254
|
type: Boolean,
|
|
1247
1255
|
default: !1
|
|
@@ -1265,7 +1273,7 @@ var vn = ["aria-labelledby"], yn = { class: "uid-modal__header" }, bn = ["id"],
|
|
|
1265
1273
|
f.closeOnOverlay && T();
|
|
1266
1274
|
}
|
|
1267
1275
|
function O(e) {
|
|
1268
|
-
e.key === "Escape" && T();
|
|
1276
|
+
e.key === "Escape" && f.closeOnEsc && T();
|
|
1269
1277
|
}
|
|
1270
1278
|
return R(u, async (e) => {
|
|
1271
1279
|
e ? (S(), await g(), y(), document.addEventListener("keydown", O)) : (C(), b(), document.removeEventListener("keydown", O));
|
|
@@ -1279,8 +1287,8 @@ var vn = ["aria-labelledby"], yn = { class: "uid-modal__header" }, bn = ["id"],
|
|
|
1279
1287
|
ref: h,
|
|
1280
1288
|
class: _(["uid-drawer", `uid-drawer--${t.side}`]),
|
|
1281
1289
|
style: v({
|
|
1282
|
-
width: t.side === "
|
|
1283
|
-
height: t.side === "bottom" ? t.height : void 0
|
|
1290
|
+
width: t.side === "left" || t.side === "right" ? t.width : void 0,
|
|
1291
|
+
height: t.side === "top" || t.side === "bottom" ? t.height : void 0
|
|
1284
1292
|
}),
|
|
1285
1293
|
role: "dialog",
|
|
1286
1294
|
"aria-modal": "true",
|
|
@@ -7208,25 +7216,42 @@ var Qn = /* @__PURE__ */ Jn(Yn, [["render", Zn]]), $n = Symbol("uid-tabs"), er =
|
|
|
7208
7216
|
props: {
|
|
7209
7217
|
steps: {},
|
|
7210
7218
|
current: { default: 0 },
|
|
7211
|
-
orientation: { default: "horizontal" }
|
|
7219
|
+
orientation: { default: "horizontal" },
|
|
7220
|
+
selectable: { default: "none" }
|
|
7212
7221
|
},
|
|
7213
|
-
|
|
7214
|
-
|
|
7222
|
+
emits: ["select"],
|
|
7223
|
+
setup(n, { emit: r }) {
|
|
7224
|
+
let i = n, a = r;
|
|
7225
|
+
function u(e) {
|
|
7226
|
+
return e === i.current ? !1 : i.selectable === "all" ? !0 : i.selectable === "completed" && e < i.current;
|
|
7227
|
+
}
|
|
7228
|
+
function d(e, t) {
|
|
7215
7229
|
return e < t ? "completed" : e === t ? "current" : "pending";
|
|
7216
7230
|
}
|
|
7217
|
-
return (
|
|
7231
|
+
return (r, i) => (x(), c("ol", {
|
|
7218
7232
|
class: _(["uid-stepper", [`uid-stepper--${n.orientation}`]]),
|
|
7219
7233
|
"aria-label": `Шаги (текущий: ${n.current + 1} из ${n.steps.length})`
|
|
7220
|
-
}, [(x(!0), c(t, null, T(n.steps, (t,
|
|
7221
|
-
key:
|
|
7222
|
-
class: _(["uid-stepper__step", [`uid-stepper__step--${r
|
|
7223
|
-
"aria-current":
|
|
7224
|
-
}, [
|
|
7225
|
-
|
|
7226
|
-
|
|
7227
|
-
|
|
7228
|
-
|
|
7229
|
-
|
|
7234
|
+
}, [(x(!0), c(t, null, T(n.steps, (t, r) => (x(), c("li", {
|
|
7235
|
+
key: r,
|
|
7236
|
+
class: _(["uid-stepper__step", [`uid-stepper__step--${d(r, n.current)}`]]),
|
|
7237
|
+
"aria-current": r === n.current ? "step" : void 0
|
|
7238
|
+
}, [(x(), o(O(u(r) ? "button" : "div"), {
|
|
7239
|
+
type: u(r) ? "button" : void 0,
|
|
7240
|
+
class: _(["uid-stepper__target", { "uid-stepper__target--selectable": u(r) }]),
|
|
7241
|
+
onClick: (e) => u(r) && a("select", r)
|
|
7242
|
+
}, {
|
|
7243
|
+
default: z(() => [l("div", _u, [d(r, n.current) === "completed" ? (x(), o(e, {
|
|
7244
|
+
key: 0,
|
|
7245
|
+
icon: j(q),
|
|
7246
|
+
size: 16,
|
|
7247
|
+
"aria-hidden": "true"
|
|
7248
|
+
}, null, 8, ["icon"])) : (x(), c("span", vu, k(r + 1), 1))]), l("div", yu, [l("span", bu, k(t.label), 1), t.description ? (x(), c("span", xu, k(t.description), 1)) : s("", !0)])]),
|
|
7249
|
+
_: 2
|
|
7250
|
+
}, 1032, [
|
|
7251
|
+
"type",
|
|
7252
|
+
"class",
|
|
7253
|
+
"onClick"
|
|
7254
|
+
]))], 10, gu))), 128))], 10, hu));
|
|
7230
7255
|
}
|
|
7231
7256
|
}), Cu = /* @__PURE__ */ f({
|
|
7232
7257
|
__name: "UidStack",
|