Skip to content

fix(CreatibutorsField): Mount CreatibutorsModal only when opened#2353

Merged
kpsherva merged 1 commit into
inveniosoftware:masterfrom
sakshamarora1:fix/deposit_form_rendering
Jun 11, 2026
Merged

fix(CreatibutorsField): Mount CreatibutorsModal only when opened#2353
kpsherva merged 1 commit into
inveniosoftware:masterfrom
sakshamarora1:fix/deposit_form_rendering

Conversation

@sakshamarora1

Copy link
Copy Markdown
Contributor

Partly addresses: inveniosoftware/invenio-app-rdm#3006

  • This change fixes the Creator/Contirbutor section in the deposit form where every CreatibutorsFieldItem unconditionally rendered a CreatibutorsModal, and inside each modal the Formik instance with enableReinitialize and a Yup schema instantiated at class-definition time for each author/creator, which led to every stroke triggering a redraw and re-mount for all the modals

addLabel,
editLabel,
initialCreatibutor,
displayName,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think we should leave this as a prop, because people might have already overridden this component and removing it will require a major release, since you are changing the function interface. I would leave it as a param, and in case the value is given - us the value, otherwise use creatibutorNameDisplay(initialCreatibutor), like you do in L63

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yeah, you're right. Thanks! Updated!

@kpsherva kpsherva moved this from In review 🔍 to In progress in Sprint Q2 2026 ☀️ Jun 9, 2026
  * This change fixes the Creator/Contributor section in the deposit form where every CreatibutorsFieldItem unconditionally rendered a CreatibutorsModal, and inside each modal the Formik instance with enableReinitialize and a Yup schema instantiated at class-definition time for each author/creator, which led to every stroke triggering a redraw and re-mount for all the modals
@sakshamarora1 sakshamarora1 force-pushed the fix/deposit_form_rendering branch from 42e996c to 87cf960 Compare June 10, 2026 15:23
@sakshamarora1 sakshamarora1 moved this from In progress to In review 🔍 in Sprint Q2 2026 ☀️ Jun 10, 2026
@kpsherva kpsherva merged commit fe1ed1c into inveniosoftware:master Jun 11, 2026
4 checks passed
@github-project-automation github-project-automation Bot moved this from In review 🔍 to To release 🤖 in Sprint Q2 2026 ☀️ Jun 11, 2026
@kpsherva kpsherva moved this from To release 🤖 to Released ✔️ in Sprint Q2 2026 ☀️ Jun 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Released ✔️

Development

Successfully merging this pull request may close these issues.

2 participants