vueless 0.0.665 → 0.0.666
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/package.json +1 -1
- package/ui.data-table/UTableRow.vue +10 -2
package/package.json
CHANGED
|
@@ -46,7 +46,9 @@ const toggleIconConfig = computed(() => {
|
|
|
46
46
|
const nestedRow = props.row?.row;
|
|
47
47
|
let isShown = false;
|
|
48
48
|
|
|
49
|
-
if (
|
|
49
|
+
if (props.row.nestedData) {
|
|
50
|
+
isShown = Boolean(props.row.nestedData.isShown);
|
|
51
|
+
} else if (Array.isArray(nestedRow)) {
|
|
50
52
|
isShown = nestedRow.some((row) => row.isShown);
|
|
51
53
|
} else {
|
|
52
54
|
isShown = Boolean(nestedRow?.isShown);
|
|
@@ -76,10 +78,16 @@ const isNestedRowEmpty = computed(() => {
|
|
|
76
78
|
return !Object.keys(mapRowColumns(props.row.row, props.columns)).length;
|
|
77
79
|
});
|
|
78
80
|
|
|
81
|
+
const isNestedDataEmpty = computed(() => {
|
|
82
|
+
if (!props.row.nestedData) return true;
|
|
83
|
+
|
|
84
|
+
return !props.row.nestedData.rows || !props.row.nestedData.rows.length;
|
|
85
|
+
});
|
|
86
|
+
|
|
79
87
|
const isShownToggleIcon = computed(() => {
|
|
80
88
|
return (
|
|
81
89
|
(props.row.row && !isNestedRowEmpty.value) ||
|
|
82
|
-
(props.row.nestedData && hasSlotContent(slots["nested-content"]))
|
|
90
|
+
(props.row.nestedData && !isNestedDataEmpty.value && hasSlotContent(slots["nested-content"]))
|
|
83
91
|
);
|
|
84
92
|
});
|
|
85
93
|
|