Skip to content

MBS-12744: Convert Edit artist credit page to React#3656

Merged
reosarevok merged 5 commits intometabrainz:masterfrom
reosarevok:MBS-12744
Feb 3, 2026
Merged

MBS-12744: Convert Edit artist credit page to React#3656
reosarevok merged 5 commits intometabrainz:masterfrom
reosarevok:MBS-12744

Conversation

@reosarevok
Copy link
Copy Markdown
Member

@reosarevok reosarevok commented Oct 24, 2025

Implement MBS-12744

Description

On top of #2836
Straightforward conversion, but it reuses the form added for SplitArtist. Since only the documentation shown as part of the form is really any different, I moved the documentation bits for both files to a different div out of the form so that only the actual form bits are reused and hydrated. It does add a bit more space between the collaborators list and the form than in prod but I actually like that, personally.

Testing

Manually, both SplitArtist and the new EditArtistCredit.

reosarevok and others added 3 commits October 24, 2025 13:48
This seems entirely unused.
We have cases where we just edit an artist credit directly and
no containing entity is involved.

This allows passing an artistCredit directly to createInitialState
and in that case prefers that over the one in the (now optional)
passed entity.

I enforced entity existing as an invariant in the places where
we actually needed.

For the button id we don't need entity and in fact it would seem
that state.id (which is supposed to be unique) is preferable.
This is just a straightforward conversion. In the future I
will try to make some bits of the form parameterized so it can
be shared with Edit artist credit.
@reosarevok reosarevok added the React PRs directly related with React conversion label Oct 24, 2025
This is basically just SplitArtistForm with a different text,
so this renames that to EditArtistCreditForm and puts the doc
text for each form in a separate div outside the form.

I cannot see a significant reason why the docs need to be
inside the form to begin with, and having them outside
makes it easier to reuse (passing them as children to the
hydrated form from the components is not doable, and
I prefer having the form component be the full form if possible).
Also change the quotes to Unicode since I'm changing
the string already.
@reosarevok reosarevok marked this pull request as ready for review October 24, 2025 13:03
Copy link
Copy Markdown
Member

@mwiencek mwiencek left a comment

Choose a reason for hiding this comment

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

Tested both forms locally and didn't have any trouble entering/accepting the edits in either case.

@reosarevok reosarevok merged commit 6b32ad4 into metabrainz:master Feb 3, 2026
7 checks passed
@reosarevok reosarevok deleted the MBS-12744 branch February 3, 2026 08:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

React PRs directly related with React conversion

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants