-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix displaying error messages on unsupported layers #553
Conversation
Deployed to Cloudflare Pages
|
92209bf
to
3f59f2c
Compare
when we render layout with unsupported layer, do we need to hide network/ParaTime picker? |
In it's current form, yes we should hide it, because otherwise it might give us further errors. So for now I will just hide it. User can still click on the Oasis logo and start overf. |
3f59f2c
to
0b8b15a
Compare
Updated the code accordingly. |
0b8b15a
to
8b0e5e6
Compare
- Don't throw more errors while already trying to display error - Use the most specific error message possible - Teach useScopeParam() to also return info about validity - Hide network selector and freshness info on invalid scopes
8b0e5e6
to
1d441c1
Compare
scope.valid = false | ||
if (!error) | ||
throw new Error( | ||
'You must either specify both network and layer or none of them. You can not have one but not the other.', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are we encoding this here? Isn't it a consequence of routes, not scope param, so add a 404 route instead
Before:
After: