TheThingsNetwork / lorawan-stack

The Things Stack, an Open Source LoRaWAN Network Server
https://www.thethingsindustries.com/stack/
Apache License 2.0
975 stars 306 forks source link

Provide a static error HTML template for non-react handled routes #3261

Closed kschiffer closed 2 years ago

kschiffer commented 4 years ago

Summary

Following up from https://github.com/TheThingsNetwork/lorawan-stack/issues/233 we still need a Go HTML template that will render a generic and static error page for all errors that are not in Console or OAuth app context. See also: https://github.com/TheThingsIndustries/lorawan-stack/issues/1315#issuecomment-440656553

Why do we need this?

To display proper error pages for backend errors that are not in the scope of Console or OAuth app. E.g. https://github.com/TheThingsIndustries/lorawan-stack/issues/2268

What is already there? What do you see now?

Error page designs and error boundaries that render error views for routes that are handled by our frontend react apps.

What is missing? What do you want to see?

Templates that render static HTML/CSS for any route that is not handled by our frontend react apps.

How do you propose to implement this?

Implementing the design that we currently use for the react apps as static HTML/CSS template that renders for error responses.

How do you propose to test this?

Manual.

Can you do this yourself and submit a Pull Request?

Yes but anyone please feel free to pick up.

kschiffer commented 3 years ago

Blocking: https://github.com/TheThingsIndustries/lorawan-stack/issues/1813

kschiffer commented 3 years ago

@pierrephz We need a generic error page for TTS. I think you designed something like that already a while back. Can you post a recent design here? Such design should be pretty simple and contain:

NicolasMrad commented 3 years ago

@kschiffer can you please advise on how this error page will look like?

kschiffer commented 3 years ago

Yes, so we should essentially use the same design that we currently use for the react handled errors (<FullViewError />):

image

We can use a simplified footer without the buttons on the right. Also, support buttons cannot be rendered in these cases, since the config is only available in the Account app / Console.