-
Notifications
You must be signed in to change notification settings - Fork 2
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(sectionedForm): initial architecture and base components #431
Conversation
✅ Deploy Preview for dhis2-maintenance-app-beta ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
d219ad6
to
e70111d
Compare
5ac15ff
to
c54fdc0
Compare
|
||
export const FORM_SECTION_PARAM_KEY = 'section' | ||
|
||
export const getSectionSearchParam = (section: string) => { |
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.
Unused
src/components/NavigationBlocker/DefaultFormNavigationBlocker.tsx
Outdated
Show resolved
Hide resolved
75b2650
to
7d887bd
Compare
* Update the selected section (in searchParams) based on the section that is in view | ||
* This keeps the selected section in sync with the section that is in view. | ||
*/ | ||
export const useSyncSelectedSectionWithScroll = () => { |
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.
Not super happy about this, but I couldn't find a better way.
156b9bb
to
78cb158
Compare
3536e6e
to
0fc665a
Compare
0fc665a
to
0d03e59
Compare
# [0.19.0](v0.18.0...v0.19.0) (2024-12-02) ### Features * **sectionedForm:** initial architecture and base components ([#431](#431)) ([74acd06](74acd06))
🎉 This PR is included in version 0.19.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
https://dhis2.atlassian.net/browse/DHIS2-18334
Implements base components for
SectionedForm
s. These are forms with a sidebar, with links to different sections.In a recent meeting it was decided we probably want to keep most section in a "scrollable"-view - ie. all fields should render.
This also implements some fields for
dataSet
"New"-forms, to showcase the use of the components.formDescriptor
. This is put in to context to allow sub-component to retrieve it.