Repository navigation
OpenConceptLab/ocl_issues#2945 | show Add to Collection on an open concept to anyone signed in - #70
Merged
Merged
Conversation
…open concept to anyone signed in The open concept's Add to Collection button was gated on owning the page's URL owner, so it was missing on other owners' repos and in global search. It now needs only a sign-in, like the bulk button in the results toolbar. Edit, retire, clone and create-similar keep their existing checks. The button label now uses the existing addToCollection.add_to_collection key in ConceptHeader and ConceptCard. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TjM9dGow2KV1Gwr2dWQdph
paynejd
commented
Oct 22, 2026
paynejd
left a comment
Member
Author
There was a problem hiding this comment.
Codex review, pass 1 (codex-cli 0.163.0, commit a6e7f0d)
Verdict: clean. No findings.
findings.json
{
"reviewer": "codex-cli 0.163.0",
"perspective": "defects",
"mode": "full",
"commit": "a6e7f0d2",
"verdict": "clean",
"prior": [],
"findings": []
}
paynejd
commented
Oct 22, 2026
paynejd
left a comment
Member
Author
There was a problem hiding this comment.
Simplification review (fresh Claude subagent, commit a6e7f0d)
Verdict: clean. Nothing to cut. No commits landed after Codex pass 1, so no follow-up Codex check is needed.
simplify.json
{
"reviewer": "claude subagent",
"perspective": "simplify",
"mode": "full",
"commit": "a6e7f0d224a02765ebe63393dc64b8158d08da1d",
"verdict": "clean",
"prior": [],
"findings": []
}
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.
What changed and why
An open concept's Add to Collection button (
ConceptHeader) showed only whencurrentUserHasAccess()was true, which checks whether the signed-in user owns the page's URL owner. So the button was missing on other owners' repos (CIEL, for example), on collection pages and in global search, which is where people find concepts to add to their own collections. The bulk Add to Collection button in the results toolbar already needed only a sign-in.isLoggedIn()), matching the bulk button. Signed out, it doesn't show.ConceptHeaderandConceptCardnow uses the existingaddToCollection.add_to_collectionkey instead of hard-coded English. No new keys. pt-BR now shows the existing "Adicionar à coleção". es and zh have noaddToCollectionsection yet (a gap that predates this PR: the dialog already falls back to English there), so the label falls back to English as before.ConceptHeaderrenders in one place (ConceptHome), which serves the side panel in global search, repo and collection pages, and the full concept page (/orgs/.../concepts/<id>/), so all four behave the same.How I verified it
eslint --ext .jsx,.js src/: clean.npm test: 20/20 pass.is_staff: false, no orgs; a staff user would makecurrentUserHasAccess()true and hide the bug), then signed out. Before (origin/main) vs after:/orgs/CIEL/sources/CIEL/concepts/116128/malaria, Source = CIEL)/orgs/CIEL/collections/MPX/Selected checkboxes in the results list were 0 before and 0 after opening a concept, in every case. Clicking the button opens the unchanged Add to Collection dialog.
Full concept page, signed in (non-staff): before / after
Global search, signed in (non-staff): before / after
More screenshots: collection page, dialog, signed out
The
screenshots/ocl_issues-2945branch holds only these images and can be deleted after review.closes OpenConceptLab/ocl_issues#2945
🤖 Generated with Claude Code
https://claude.ai/code/session_01TjM9dGow2KV1Gwr2dWQdph