Skip to content
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

Adding 404 page on edit route #7727

Conversation

Aryanshu919
Copy link
Contributor

Proposed Changes

Redirecting the user to an existing 404 page whenever user go on "/edit" route.

Screenshot 2024-04-27 at 10 10 04 PM

@coronasafe/care-fe-code-reviewers @coronasafe/code-reviewers

Merge Checklist

  • Add specs that demonstrate bug / test a new feature.
  • Update product documentation.
  • Ensure that UI text is kept in I18n files.
  • Prep screenshot or demo video for changelog entry, and attach it to issue.
  • Request for Peer Reviews
  • Completion of QA

@Aryanshu919 Aryanshu919 requested a review from a team as a code owner April 28, 2024 06:40
Copy link

vercel bot commented Apr 28, 2024

@Aryanshu919 is attempting to deploy a commit to the Open Healthcare Network Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

netlify bot commented Apr 28, 2024

Deploy Preview for care-egov-staging ready!

Name Link
🔨 Latest commit 4385538
🔍 Latest deploy log https://app.netlify.com/sites/care-egov-staging/deploys/6631b84ff47fe00008ca12d7
😎 Deploy Preview https://deploy-preview-7727--care-egov-staging.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@nihal467
Copy link
Member

@Aryanshu919 clear the merge conflict

@Aryanshu919
Copy link
Contributor Author

@nihal467 Done. Could you review it?

@@ -100,7 +100,7 @@ const TextFormField = forwardRef((props: TextFormFieldProps, ref) => {
);
const _trailing =
trailing === trailingFocused ? (
<div className="absolute inset-y-0 right-0 flex items-center pr-3">
<div className="relative inset-y-0 right-0 flex items-center pr-3">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why was this changed? Unrelated to the issue being solved right?

Feel free to create a separate issue if this solves an issue 😄

Comment on lines +26 to +28
"/facility/:facilityId/patient/:patientId/consultation/:id/edit": () => (
<Error404 />
),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The intention of the issue is, that any invalid links should show a 404 page, not just /edit.

This can be achieved by having a fallback to Error404 component if none of the URLs has matched with the current URL.

@Aryanshu919 Aryanshu919 closed this May 1, 2024
@Aryanshu919 Aryanshu919 deleted the issue/7723/handle_wrong_links branch May 1, 2024 05:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Handle the wrong links in the platform properly
3 participants