That's my fork of your script. It was working for me on Firefox with Windows 11, but I got the same results as you did when I tried it on Firefox on Windows 10. Since I use my Windows 10 computer less, I checked whether Firefox was up to date. It was at version 137.0.2, and I updated it to version 138.0.1. Upon doing this, the Interactive Diagram worked as it should. Since Firefox was up to 138.0.3 on my Windows 11 computer, I did another update of Firefox on Windows 10 to bring it completely up to date.
Since Windows 7 is no longer supported by Microsoft, it's possible that it will not support the latest version of Firefox. The first thing you should do is make sure Firefox is up to date. Go to "About Firefox" under the Help menu, where it will check for updates and tell you whether you have the latest version. If you're not up to date, it will try to download the update and ask you to restart Firefox to install it. Note what version you currently have installed and what version you're able to update to. If you cannot update to the latest version, 138.0.3, you may want to consider updating your OS to Windows 10 or replacing your computer. Assuming you can still use the latest version of Firefox, I would hope you are using Windows 7 with 0patch, which will provide you with security updates now that Microsoft is no longer doing that for Windows 7.
That's my fork of your script. It was working for me on Firefox with Windows 11, but I got the same results as you did when I tried it on Firefox on Windows 10. Since I use my Windows 10 computer less, I checked whether Firefox was up to date. It was at version 137.0.2, and I updated it to version 138.0.1. Upon doing this, the Interactive Diagram worked as it should. Since Firefox was up to 138.0.3 on my Windows 11 computer, I did another update of Firefox on Windows 10 to bring it completely up to date.
Since Windows 7 is no longer supported by Microsoft, it's possible that it will not support the latest version of Firefox. The first thing you should do is make sure Firefox is up to date. Go to "About Firefox" under the Help menu, where it will check for updates and tell you whether you have the latest version. If you're not up to date, it will try to download the update and ask you to restart Firefox to install it. Note what version you currently have installed and what version you're able to update to. If you cannot update to the latest version, 138.0.3, you may want to consider updating your OS to Windows 10 or replacing your computer. Assuming you can still use the latest version of Firefox, I would hope you are using Windows 7 with 0patch, which will provide you with security updates now that Microsoft is no longer doing that for Windows 7.