From 7c25fac4564fac07cad8d4b1bee30db8b07d46e6 Mon Sep 17 00:00:00 2001 From: "you@example.com" Date: Tue, 23 Jul 2024 18:22:22 +0900 Subject: [PATCH] f --- src/Tray.js | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/Tray.js b/src/Tray.js index 140f3ff..36d0a02 100644 --- a/src/Tray.js +++ b/src/Tray.js @@ -1683,14 +1683,18 @@ class NetworkTray extends Tray { this.downloadData() .then(downloaded => { // Update the current tray with the downloaded data - Object.assign(this, downloaded); - this.updateAppearance(); - this.updateNetworkInfo(); + let parent = this.element.parentElement.__trayInstance + this.deleteTray(); + parent.appendChild(downloaded) + + // Object.assign(this, downloaded); + // this.updateAppearance(); + // this.updateNetworkInfo(); // If there are children, recursively update them - this.children.forEach((child, index) => { - Object.assign(child, downloaded.children[index]); - child.updateAppearance(); - }); + // this.children.forEach((child, index) => { + // Object.assign(child, downloaded.children[index]); + // child.updateAppearance(); + // }); }) .catch(error => { console.error('Download failed:', error);