Repository navigation
Save publication contributors as users, not names - #568
Merged
Merged
Conversation
The wizard picked real users but saved only their display names in `authors`. On reload it rebuilt fake ids from those names, so the duplicate check never matched and the same person could be added twice (#560). The wizard now sends `contributorIds` and loads `contributors` with their real ids, so a reloaded contributor is recognised. The review step, wizard progress, preview and public page (cover, information, SEO data and citation) read the contributors' names instead of `authors`.
anantjain341
had a problem deploying
to
development
November 26, 2026 18:01 — with
GitHub Actions
Failure
…ames The list now comes from contributors and the page labels it "Contributors", so the old `authors` name was misleading. The schema.org `author` field and the citation keep the word author.
anantjain341
had a problem deploying
to
development
November 26, 2026 18:27 — with
GitHub Actions
Failure
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Depends on CivicDataLab/DataSpaceBackend#333. Merge only after that is live on dev: this PR uses the new
contributorsfield andcontributorIdsinput, so codegen and the build fail against a backend without them.Fixes #560. The wizard picked real users but saved only their display names in
authors. On reload it rebuilt fake ids from those names (author-${index}-${name}), so the duplicate check never matched and the same person could be added twice.Changes
publications/queries.ts,model.ts,components/DetailsStep.tsx):contributorIds(the ids fromsearchUsers) instead ofauthors.contributors { id fullName username profilePicture { url } }, so a reloaded contributor keeps their real id, name, username and picture, and adding them again is ignored.ReviewStep.tsx,WizardShell.tsx,preview/[id]/page.tsx): the "at least one contributor" check and the names shown usecontributors.queries.ts,page.tsx,publication-detail.ts): asks forcontributors { id fullName }. New helperpublicationContributorNamesgives each name once; the cover, information panel (their prop is nowcontributorNames), SEO data and citation all use it.Behaviour
authorsis no longer read or sent anywhere. When contributor ids are saved, the backend clears the old names on that publication.