Skip to content

fix(web): keep grouped project renames - #7831

Open
MohtashamMurshid wants to merge 3 commits into
pingdotgg:mainfrom
MohtashamMurshid:fix/project-settings-group-rename
Open

fix(web): keep grouped project renames#7831
MohtashamMurshid wants to merge 3 commits into
pingdotgg:mainfrom
MohtashamMurshid:fix/project-settings-group-rename

Conversation

@MohtashamMurshid

@MohtashamMurshid MohtashamMurshid commented Aug 21, 2026

Copy link
Copy Markdown

Problem

Project settings compared a requested group title with group.displayName. That label can come from repository metadata when checkout titles differ, so a valid rename could return before sending any update.

Fix

Treat the rename as a no-op only when every stored member title already matches the requested title. Add focused coverage for divergent and converged project groups.

Tests

  • vp test run apps/web/src/components/settings/ProjectSettingsPanel.logic.test.ts packages/client-runtime/src/state/projectGrouping.test.ts
  • vp lint apps/web/src/components/settings/ProjectSettingsPanel.tsx apps/web/src/components/settings/ProjectSettingsPanel.logic.ts apps/web/src/components/settings/ProjectSettingsPanel.logic.test.ts
  • vp run -F @t3tools/web typecheck

Closes #7510

Built with gpt-5.6-sol through the Codex harness in T3 Code.


Note

Low Risk
Narrow UI rename-guard change with unit tests; no auth or data-model changes beyond existing project title updates.

Overview
Fixes grouped project rename in settings so a valid name is no longer dropped when it matches the derived displayName but member titles still differ.

renameGroup now uses projectGroupTitleNeedsUpdate: it writes only if the user actually edited the field and at least one member title differs from the requested name. Untouched blur (including when the shown label is a repo-derived name) is a no-op. Adds unit coverage for those cases.

Reviewed by Cursor Bugbot for commit 95b5b83. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Fix grouped project renames to only trigger on actual edits

  • Adds projectGroupTitleNeedsUpdate util in ProjectSettingsPanel.logic.ts that returns true only when the input was edited and at least one member title differs from the target title.
  • Updates ProjectDetail in ProjectSettingsPanel.tsx to track edit state via a ref (projectNameEditedRef) and pass a wasEdited flag to renameGroup.
  • Replaces prior equality checks (against group.displayName and per-member titles) with a single call to the new util.
  • Adds test coverage in ProjectSettingsPanel.logic.test.ts for edited/divergent, blur-without-edit, and all-members-matching cases.
  • Risk: blur on the Name field no longer triggers a rename when the input was not edited, even if the derived label differs from member titles; verify no flows rely on blur-triggered auto-rename.

Macroscope summarized 95b5b83.

@coderabbitai

coderabbitai Bot commented Aug 21, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 188d7216-8a13-4cb1-ac96-beb56d9ce9cd

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added vouch:unvouched PR author is not yet trusted in the VOUCHED list. size:S 10-29 changed lines (additions + deletions). labels Aug 21, 2026

@cursor cursor Bot left a comment

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.

Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want fixes drafted automatically? Bugbot Autofix can create code changes for findings. A team admin can enable Autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit ad191f0. Configure here.

Comment thread apps/web/src/components/settings/ProjectSettingsPanel.tsx
@github-actions github-actions Bot added size:M 30-99 changed lines (additions + deletions). and removed size:S 10-29 changed lines (additions + deletions). labels Aug 21, 2026
…ngs-group-rename-conflict

# Conflicts:
#	apps/web/src/components/settings/ProjectSettingsPanel.tsx
@MohtashamMurshid
MohtashamMurshid marked this pull request as ready for review August 22, 2026 05:34
@macroscopeapp

macroscopeapp Bot commented Aug 22, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Skipped

Macroscope did not run approvability analysis for this PR. Macroscope could not determine whether this PR modifies its approvability configuration, so the PR was not approved automatically. A PR that may change the rules that govern approval is never approved automatically.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M 30-99 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]:

1 participant