SimplyStaking / panic

PANIC Monitoring and Alerting For Blockchains
Apache License 2.0
81 stars 31 forks source link

CSS not loading properly when navigating back and forth from the Alerts page #346

Closed dillu24 closed 2 years ago

dillu24 commented 2 years ago

Rationale

Sometimes when navigating the installer using the PANIC UI navigation buttons the CSS is not rendered properly, especially when navigating back and fort from the alerts page. This is also breaking the toasts, because it was noted that if the css is broken then the toast are not raised.

For ticket closure

The aim of this ticket is to identify the problem and solve it

dillu24 commented 2 years ago

See screenshot below:

image

This was obtained when adding a new Substrate subchain from the CRUD journey, just after adding a substrate node.

itsciccio commented 2 years ago

It should be noted that this occurs throughout all installer steps... what triggers it is the mystery. However we think it is an issue with the new router.

itsciccio commented 2 years ago

Could be that the css file for the respective page is not being loaded

zimaah commented 2 years ago

TLDR: The raiseToast() function was appending the "toast" as child of svc-app tag and this was messing up the styles, since svc-app needs the "content container" as first child and not the svc-toast element. The correct approach is to append the svc-toast as child of body element.