-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat(initial submission): Set up New Submission triage options #140
Conversation
@@ -0,0 +1,10 @@ | |||
/** TODO: Implement enum values where `to` or `href` is currently just a string. */ | |||
export enum ROUTES { |
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.
To prevent circular imports between router.tsx
and the components/pages using ROUTES
, they've been broken out into their own file -- this can be something of an "all constants" file in the future if we need it. Without this separation, the circular dependency between files leads to an undefined
error when importing and using the constant values.
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.
semantic html, routing consts, unit tests, inline comments and a thorough pr write up... oh my good heavens!
🎉 This PR is included in version 1.5.0-val.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Purpose
This PR adds in the triage of navigation options for the New Submission screen, so a user can select the authority type, document type, and navigate to the desired page.
Linked Issues to Close
https://qmacbis.atlassian.net/browse/OY2-25391
Approach
We have a single component that acts as a reusable page (
OptionsPage
) made of sub-components that handle styling. Each route links to a specific instance of theOptionsPage
fed with different OptionData values. These values dictate the title, description, and path linked to.Let's say you arrive at
/new-submission
, this is what powers the page of initial options:And this will be one of your options:
The above example links to
/new-submission/spa
, and on that page, we render:which will have subsequent options with subsequent links.
The router includes the following to wire this up:
Assorted Notes/Considerations/Learning
I fixed up the
CardWithTopBorder
styles a bit. The gradient bar wasn't rounded, and the border was overlapping it a bit, so I yanked some of the styles from OneMAC to patch it up and added padding back where necessary, hence some seemingly rogue changes in the PR (faq and description used the component)