@1337exp/taoui 1.9.0 → 1.10.1
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 +1 -1
- package/README.ru.md +1 -1
- package/dist/index.cjs +19 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +19 -3
- package/dist/index.mjs +19 -5
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +96 -80
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1164,9 +1164,14 @@ rows?: Record<string, unknown>[];
|
|
|
1164
1164
|
rowKey?: string | ((row: Record<string, unknown>, index: number) => string | number);
|
|
1165
1165
|
loading?: boolean;
|
|
1166
1166
|
emptyText?: string;
|
|
1167
|
-
|
|
1167
|
+
/** Зебра. `true` / `odd` — с первой строки, `even` — со второй. */
|
|
1168
|
+
striped?: boolean | "odd" | "even";
|
|
1168
1169
|
compact?: boolean;
|
|
1169
1170
|
hover?: boolean;
|
|
1171
|
+
/** Подсветка шапки. */
|
|
1172
|
+
head?: boolean;
|
|
1173
|
+
/** Горизонтальные линии между рядами. */
|
|
1174
|
+
lines?: boolean;
|
|
1170
1175
|
sticky?: boolean;
|
|
1171
1176
|
maxHeight?: string;
|
|
1172
1177
|
clickable?: boolean;
|
|
@@ -1180,6 +1185,8 @@ emptyText: string;
|
|
|
1180
1185
|
striped: boolean;
|
|
1181
1186
|
compact: boolean;
|
|
1182
1187
|
hover: boolean;
|
|
1188
|
+
head: boolean;
|
|
1189
|
+
lines: boolean;
|
|
1183
1190
|
sticky: boolean;
|
|
1184
1191
|
maxHeight: string;
|
|
1185
1192
|
clickable: boolean;
|
|
@@ -1195,9 +1202,14 @@ rows?: Record<string, unknown>[];
|
|
|
1195
1202
|
rowKey?: string | ((row: Record<string, unknown>, index: number) => string | number);
|
|
1196
1203
|
loading?: boolean;
|
|
1197
1204
|
emptyText?: string;
|
|
1198
|
-
|
|
1205
|
+
/** Зебра. `true` / `odd` — с первой строки, `even` — со второй. */
|
|
1206
|
+
striped?: boolean | "odd" | "even";
|
|
1199
1207
|
compact?: boolean;
|
|
1200
1208
|
hover?: boolean;
|
|
1209
|
+
/** Подсветка шапки. */
|
|
1210
|
+
head?: boolean;
|
|
1211
|
+
/** Горизонтальные линии между рядами. */
|
|
1212
|
+
lines?: boolean;
|
|
1201
1213
|
sticky?: boolean;
|
|
1202
1214
|
maxHeight?: string;
|
|
1203
1215
|
clickable?: boolean;
|
|
@@ -1211,6 +1223,8 @@ emptyText: string;
|
|
|
1211
1223
|
striped: boolean;
|
|
1212
1224
|
compact: boolean;
|
|
1213
1225
|
hover: boolean;
|
|
1226
|
+
head: boolean;
|
|
1227
|
+
lines: boolean;
|
|
1214
1228
|
sticky: boolean;
|
|
1215
1229
|
maxHeight: string;
|
|
1216
1230
|
clickable: boolean;
|
|
@@ -1223,14 +1237,16 @@ onSort?: ((value: TaoTableSort | null) => any) | undefined;
|
|
|
1223
1237
|
}>, {
|
|
1224
1238
|
sort: TaoTableSort | null;
|
|
1225
1239
|
caption: string;
|
|
1240
|
+
head: boolean;
|
|
1226
1241
|
hover: boolean;
|
|
1227
1242
|
loading: boolean;
|
|
1228
1243
|
emptyText: string;
|
|
1229
1244
|
rows: Record<string, unknown>[];
|
|
1230
1245
|
maxHeight: string;
|
|
1231
1246
|
clickable: boolean;
|
|
1247
|
+
lines: boolean;
|
|
1232
1248
|
rowKey: string | ((row: Record<string, unknown>, index: number) => string | number);
|
|
1233
|
-
striped: boolean;
|
|
1249
|
+
striped: boolean | "odd" | "even";
|
|
1234
1250
|
compact: boolean;
|
|
1235
1251
|
sticky: boolean;
|
|
1236
1252
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
package/dist/index.mjs
CHANGED
|
@@ -2459,7 +2459,7 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
2459
2459
|
};
|
|
2460
2460
|
}
|
|
2461
2461
|
});
|
|
2462
|
-
const TaoTag = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["__scopeId", "data-v-
|
|
2462
|
+
const TaoTag = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["__scopeId", "data-v-cbbbf8f3"]]);
|
|
2463
2463
|
const _hoisted_1$y = ["role", "aria-hidden"];
|
|
2464
2464
|
const _hoisted_2$v = {
|
|
2465
2465
|
key: 1,
|
|
@@ -2510,7 +2510,7 @@ const _sfc_main$A = /* @__PURE__ */ defineComponent({
|
|
|
2510
2510
|
};
|
|
2511
2511
|
}
|
|
2512
2512
|
});
|
|
2513
|
-
const TaoDivider = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["__scopeId", "data-v-
|
|
2513
|
+
const TaoDivider = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["__scopeId", "data-v-b8f809ac"]]);
|
|
2514
2514
|
const _hoisted_1$x = {
|
|
2515
2515
|
key: 0,
|
|
2516
2516
|
class: "tao-fieldset__legend"
|
|
@@ -6202,9 +6202,11 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
6202
6202
|
rowKey: { type: [String, Function], default: "id" },
|
|
6203
6203
|
loading: { type: Boolean, default: false },
|
|
6204
6204
|
emptyText: { default: "Нет данных" },
|
|
6205
|
-
striped: { type: Boolean, default: false },
|
|
6205
|
+
striped: { type: [Boolean, String], default: false },
|
|
6206
6206
|
compact: { type: Boolean, default: false },
|
|
6207
6207
|
hover: { type: Boolean, default: true },
|
|
6208
|
+
head: { type: Boolean, default: true },
|
|
6209
|
+
lines: { type: Boolean, default: true },
|
|
6208
6210
|
sticky: { type: Boolean, default: false },
|
|
6209
6211
|
maxHeight: { default: "" },
|
|
6210
6212
|
clickable: { type: Boolean, default: false },
|
|
@@ -6217,6 +6219,15 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
6217
6219
|
const emit = __emit;
|
|
6218
6220
|
const colCount = computed(() => Math.max(props.columns.length, 1));
|
|
6219
6221
|
const isEmpty = computed(() => !props.rows.length && !props.loading);
|
|
6222
|
+
const stripeFrom = computed(() => {
|
|
6223
|
+
if (props.striped === "even") {
|
|
6224
|
+
return "even";
|
|
6225
|
+
}
|
|
6226
|
+
if (props.striped === "odd" || props.striped === true) {
|
|
6227
|
+
return "odd";
|
|
6228
|
+
}
|
|
6229
|
+
return null;
|
|
6230
|
+
});
|
|
6220
6231
|
function columnWidth(column) {
|
|
6221
6232
|
if (column.width == null) {
|
|
6222
6233
|
return void 0;
|
|
@@ -6267,9 +6278,12 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
6267
6278
|
}, [
|
|
6268
6279
|
createElementVNode("table", {
|
|
6269
6280
|
class: normalizeClass(["tao-table", {
|
|
6270
|
-
"tao-table--striped":
|
|
6281
|
+
"tao-table--striped": stripeFrom.value === "odd",
|
|
6282
|
+
"tao-table--striped-even": stripeFrom.value === "even",
|
|
6271
6283
|
"tao-table--compact": __props.compact,
|
|
6272
6284
|
"tao-table--hover": __props.hover,
|
|
6285
|
+
"tao-table--head": __props.head,
|
|
6286
|
+
"tao-table--lines": __props.lines,
|
|
6273
6287
|
"tao-table--clickable": __props.clickable,
|
|
6274
6288
|
"tao-table--sticky": __props.sticky
|
|
6275
6289
|
}])
|
|
@@ -6354,7 +6368,7 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
6354
6368
|
};
|
|
6355
6369
|
}
|
|
6356
6370
|
});
|
|
6357
|
-
const TaoTable = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-
|
|
6371
|
+
const TaoTable = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-497e62e7"]]);
|
|
6358
6372
|
function buildPaginationItems(page, pageCount, siblingCount = 1) {
|
|
6359
6373
|
if (pageCount <= 0) {
|
|
6360
6374
|
return [];
|