feat(dashboard): disable branch creation behind flag and show deprecation banner#8890
Merged
Conversation
…tion banner Add a disableBranchCreation team feature flag (server-provided) that: - hides all "Create branch" entry points in the dashboard (header button, repository context menu, and the Recent page create-branch carousel) - shows a deprecation banner on the repositories and repository branches pages noting the repositories product will be removed on July 15th and that users should commit and push branch work before then Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Review or Edit in CodeSandboxOpen the branch in Web Editor • VS Code • Insiders |
The server feature flag is block_branch_creation, which maps to blockBranchCreation in the GraphQL schema (matching the blockRepoImport precedent). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Hiding the UI buttons alone was not enough: createDraftBranch creates the branch via the createBranch GraphQL mutation and then navigates to the v2 editor, which materializes the branch (POST /beta/sandboxes/github/...). Guard the action itself so branch creation is blocked end-to-end regardless of which entry point triggers it, surfacing a warning notification instead. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Read the GraphQL error message instead of JSON.stringify-ing the whole error object, so a server-side block_branch_creation rejection shows a readable message. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…tons Rather than hiding the "Create branch" buttons, keep them clickable and surface a deprecation modal (mirroring the banner content, close-only) when a user attempts to create a branch. - Add a branchCreationDeprecated modal - createDraftBranch opens it when the blockBranchCreation flag is set, and also when the server rejects with extensions.code BRANCH_CREATION_DISABLED (the stable code from the server enforcement) as a backstop - Revert the button-hiding in Header, RepositoryMenu and CreateBranchesRow - Keep the dashboard deprecation banner Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
necoline
approved these changes
Jun 16, 2026
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
Introduces a new server-provided
disableBranchCreationteam feature flag and uses it to wind down the repositories/branches product:CreateBranchesRow)How
Adds
disableBranchCreationfollowing the exact pattern of the existingblockRepoImportflag (added in #8873):teamFragmentDashboard,currentTeamInfoFragment) and generatedtypes.tsuseWorkspaceFeatureFlagshook (defaultsfalsewith no active team)The banner is a new shared
RepositoryDeprecationStripecomponent (awarningMessageStripe), placed under the header on both repository views following the existingInstallGHAppStripepattern. Both the disabling and the banner are gated on the same flag so the deprecation rolls out together.Notes
node_moduleswas not installed in the working checkout, so the typechecker was not run locally. Changes follow existing patterns;MessageStripe.Actionsupports theas="a"/href/target/relprops used (verified againstButtonProps).🤖 Generated with Claude Code