Skip to content

🐛 Bugfix: Disable tool and skill selection when user is not in edit mode#3064

Merged
WMC001 merged 6 commits into
developfrom
xyq/bugfix_frontend
May 29, 2026
Merged

🐛 Bugfix: Disable tool and skill selection when user is not in edit mode#3064
WMC001 merged 6 commits into
developfrom
xyq/bugfix_frontend

Conversation

@xuyaqist
Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings May 28, 2026 08:26
@xuyaqist xuyaqist requested review from Dallas98 and WMC001 as code owners May 28, 2026 08:26
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR aims to prevent users from changing tool/skill selections when they are not in an editable agent context (e.g., no agent selected / not in create mode), by tightening read-only detection and ensuring the Tool management UI relies on the store-derived read-only state.

Changes:

  • Update isReadOnly() logic to treat “not creating + no current agent selected” as read-only.
  • Remove the isReadOnly prop wiring into ToolManagement and rely on useAgentConfigStore().isReadOnly() directly.
  • Minor UI prop change to the Import button in the agent selector header.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
frontend/stores/agentConfigStore.ts Updates read-only determination to cover the “no agent selected” state.
frontend/app/[locale]/agents/components/AgentSelectorHeader.tsx Removes type="text" from the Import button.
frontend/app/[locale]/agents/components/AgentConfigComp.tsx Stops passing isReadOnly into ToolManagement.
frontend/app/[locale]/agents/components/agentConfig/ToolManagement.tsx Simplifies read-only handling to always use the store value.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread frontend/stores/agentConfigStore.ts
Comment thread frontend/stores/agentConfigStore.ts
@xuyaqist xuyaqist changed the title Bugfix: Disable tool and skill selection when user is not in edit mode 🐛 Bugfix: Disable tool and skill selection when user is not in edit mode May 28, 2026
@WMC001 WMC001 merged commit 0302eab into develop May 29, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants