Samantha-uk / one

One - A monorepo. Home of Zigzag.
17 stars 17 forks source link

The zigzag panel is just blank #7

Closed TheZoker closed 3 years ago

TheZoker commented 3 years ago

Describe the bug

The zigzag panel is just blank

My config looks like this:

panel_custom:
  - name: zigzag
    sidebar_title: Zigzag
    sidebar_icon: mdi:zigbee
    url_path: zigzag
    module_url: /local/zigzag/zigzag-panel.esm.js
    trust_external_script: true
    config:
      who: world
      zigzag:
        plugin-path: "/local/zigzag/plugins"
        plugin-data:
          type: "zha"
        plugin-layout:
          type: "d3"
        plugin-render:
          type: "three" 

I also tried pixi as render plugin, but same issue.

To Reproduce Steps to reproduce the behavior:

  1. Go to zigzag panel

Expected behaviour Display panel

Browser console Screenshot_2021 01 17_13h26m18s_007_

Screenshots Blank panel: Screenshot_2021 01 17_13h24m27s_006_

The script is loaded: Screenshot_2021 01 17_13h23m43s_004_

This is what the html element looks like: Screenshot_2021 01 17_13h24m14s_005_

Desktop (please complete the following information):

I also tried firefox, same issue

Home Assistant:

Additional context none

Samantha-uk commented 3 years ago

Very odd! I would expect at the very least to see more info in the browser console, such as image

I run OSX but note you're on Windows. I'll try to fire up a Windows VM on my Proxmox server to see if I can replicate what you are seeing. Just to check, you are using the latest files from https://github.com/Samantha-uk/one/tree/main/home-assistant/zigzag-panel/zigzag ?

DrCoolzic commented 3 years ago

I do not see the PixiJS 5.35.7 info? I have the following image

TheZoker commented 3 years ago

@Samantha-uk Yes these are exactly the files I installed: Screenshot_2021 01 17_17h17m46s_008_

I have no clue, why there are no logs in the console....

Is there anything else I can check on my end?

Samantha-uk commented 3 years ago

I'm not sure what else you can check just now to be honest. I'm still building my Windows VM to try to replicate the issue you are seeing. Could you jump to the Zigzag discord so we can chat more interactively? https://discord.gg/SF7PnZDj

Samantha-uk commented 3 years ago

It took me a while to spot the issue, perhaps my mind was focused on the new 18Tb NAS that arrived a couple of hours ago! 😃 When I loaded your config in my system, I experienced exactly what you described, which was a good start (Don't we all hate issues that are hard to reproduce!)

In the Home Assistant configuration.yaml, it is vital that the name element reflects the Web Component name of whatever you want to load. For Zigzag, it's Web Component name is custom-panel-zigzag.

By changing your config as follows, it seemed to work OK here. Not working

panel_custom:
  - name: zigzag
 ...

Working

panel_custom:
  - name: custom-panel-zigzag
  ...

Could you try the same change on your system and let me know if the issue is resolved or persists?

TheZoker commented 3 years ago

Yes that was the issue. Thank you very much for your extensive help! I should be more careful when customizing code before trying the initial code 😅

PS: Have fun with you new NAS, these things are amazing 😄

Samantha-uk commented 3 years ago

Thank you. "Old NAS" Synology DS210+ ... circa 2010. 2Tb RAID 1 image

"New NAS TrueNAS VM on NUC: ZFS RAIDZ . 15Tb (With just 4 of 8 bays used)

image Because ... I'm worth it! lol

And I need somewhere to keep Zigzag safe :)

DrCoolzic commented 3 years ago

Nice :O