Trikolon / liquidradio

Frontend for music station Liquid Radio
https://liquidradio.pro
MIT License
7 stars 2 forks source link

Visualizer not showing if initial visibility state false #14

Closed Trikolon closed 7 years ago

Trikolon commented 7 years ago

When the page is loaded with visualizer set to false enabling it via the switch in the navigation does not work.

Endebert commented 7 years ago

@Trikolon This is not a bug of the visualizer. The visualizer is created and running, even if initial visibility is false.

However, in case of the component being hidden initially, its canvas width and height are 0. The problem will solve itself once we switch from v-show to v-if.

Until then, some workaround has to be found, but I believe that is outside of the scope of the visualizer component.

Trikolon commented 7 years ago

Yes, you are right. I'll try to get the v-if working. Basically we need to find a way to hand over the audio element to the component on page-load already.

Trikolon commented 7 years ago

7bda307 fixed it partially, but now there is no audio (when initial visibility is false).