zzz-pc-view 0.0.170 → 0.0.171
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/src/index.es.js +5 -3
- package/src/index.umd.js +1 -1
package/package.json
CHANGED
package/src/index.es.js
CHANGED
|
@@ -4238,13 +4238,15 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
|
4238
4238
|
emit("ready", chartInstance);
|
|
4239
4239
|
setChartOption();
|
|
4240
4240
|
};
|
|
4241
|
-
const destroy = () => {
|
|
4241
|
+
const destroy = (clear2 = true) => {
|
|
4242
4242
|
const chartInstance = chartInstanceRef.value;
|
|
4243
4243
|
if (!chartInstance) {
|
|
4244
4244
|
return;
|
|
4245
4245
|
}
|
|
4246
4246
|
emit("destroy", chartInstance);
|
|
4247
|
-
|
|
4247
|
+
if (clear2) {
|
|
4248
|
+
chartInstance.clear();
|
|
4249
|
+
}
|
|
4248
4250
|
chartInstance.dispose();
|
|
4249
4251
|
chartInstanceRef.value = void 0;
|
|
4250
4252
|
};
|
|
@@ -4272,7 +4274,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
|
|
|
4272
4274
|
if (!chartInstance) {
|
|
4273
4275
|
return;
|
|
4274
4276
|
}
|
|
4275
|
-
destroy();
|
|
4277
|
+
destroy(false);
|
|
4276
4278
|
init();
|
|
4277
4279
|
if (chartOption) {
|
|
4278
4280
|
chartInstanceRef.value.setOption(chartOption, true);
|