-
Notifications
You must be signed in to change notification settings - Fork 1
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
Various bug fixes #185
Various bug fixes #185
Conversation
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.
LGTM and everything was working nicely in https://districtr-v2-185-app.fly.dev/
<Text as="p" mb={'4'}> | ||
{!!errorNotification?.severity && <i>Severity: {errorNotification.severity}</i>} | ||
</Text> |
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.
PP: Not sure we need the severity here.
Q: Do you know if Sentry will capture these errors? It would be good to still have them tracked there but not pressing to figure that out
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.
I'm using severity as a way to sort alert type - dialog, toast, silent log ?
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.
I'm not super familiar with sentry but I'm sure this can integrate with it
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.
Makes sense – just not sure it needs to be exposed to the user!
@@ -16,6 +17,7 @@ export default function Map() { | |||
<MapComponent /> | |||
<MobileTopNav /> | |||
<MapContextMenu /> | |||
<ErrorNotification /> |
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.
Q: Should this be further up in the DOM in case other pages eventually need it?
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.
Possibly but I'm not sure if that will mess up SSR stuff
import {AlertDialog, Button, Flex, Text} from '@radix-ui/themes'; | ||
import * as Toast from '@radix-ui/react-toast'; | ||
|
||
export const ErrorNotification = () => { |
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.
PP: Good for now but there's probably an argument to be made either way that this should be an error dialog.
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.
Severity 1 is a dialog!
set({ | ||
errorNotification: { | ||
severity: 2, | ||
message: `Breaking this geography failed. Please refresh this page and try again. If this error persists, please share the error code below the Districtr team.`, |
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.
nice
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.
Thank you!
This PR has a few bug fixes for previous flagged issues.
Description
Reviewers
Checklist
Screenshots (if applicable):