dfish-widget 1.0.49 → 1.0.50
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/lib/index.esm.js +17 -11
- package/lib/index.esm.js.map +1 -1
- package/package.json +1 -1
package/lib/index.esm.js
CHANGED
|
@@ -6237,9 +6237,9 @@ const props = __props;
|
|
|
6237
6237
|
a = p;
|
|
6238
6238
|
}
|
|
6239
6239
|
}
|
|
6240
|
-
a &&
|
|
6241
|
-
return item
|
|
6240
|
+
a && doToggle(a, true);
|
|
6242
6241
|
}
|
|
6242
|
+
return item
|
|
6243
6243
|
};
|
|
6244
6244
|
|
|
6245
6245
|
const showList = computed(() => {
|
|
@@ -6256,14 +6256,8 @@ const props = __props;
|
|
|
6256
6256
|
showCount.value = Math.ceil(flow.value.height / itemHeight);
|
|
6257
6257
|
};
|
|
6258
6258
|
|
|
6259
|
-
|
|
6260
|
-
|
|
6261
|
-
initShowCount();
|
|
6262
|
-
}, {immediate: true});
|
|
6263
|
-
watch(() => props.children, (children) => {
|
|
6264
|
-
flatList.value = toFlat(children);
|
|
6265
|
-
}, {immediate: true});
|
|
6266
|
-
watch(() => props.current, (current) => {
|
|
6259
|
+
const watchCurrent = async (current) => {
|
|
6260
|
+
await nextTick();
|
|
6267
6261
|
if (!showList.value.find(n => n[propValue] === current)) {
|
|
6268
6262
|
const item = expandTo(current);
|
|
6269
6263
|
const i = flatList.value.indexOf(item);
|
|
@@ -6273,7 +6267,19 @@ const props = __props;
|
|
|
6273
6267
|
});
|
|
6274
6268
|
}
|
|
6275
6269
|
}
|
|
6276
|
-
}
|
|
6270
|
+
};
|
|
6271
|
+
|
|
6272
|
+
onMounted(async () => {
|
|
6273
|
+
watch(() => root.value.wScrollSizeY, (ssy) => {
|
|
6274
|
+
initShowCount();
|
|
6275
|
+
}, {immediate: true});
|
|
6276
|
+
watch(() => props.children, async (children) => {
|
|
6277
|
+
flatList.value = toFlat(children);
|
|
6278
|
+
if (props.current) {
|
|
6279
|
+
watchCurrent(props.current);
|
|
6280
|
+
}
|
|
6281
|
+
}, {immediate: true});
|
|
6282
|
+
watch(() => props.current, watchCurrent);
|
|
6277
6283
|
const src = props.src && props.src();
|
|
6278
6284
|
if (src) {
|
|
6279
6285
|
loading.value = true;
|