Refactor: Rename agent to operator across client and console#144
Merged
Conversation
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.
Summary
This PR renames the "agent" concept to "operator" throughout the client library and console components, aligning the codebase with updated domain terminology. The refactor touches the core console UI component, its associated tests, mock definitions, and the upstream
@robosystems/client-clientspackage dependency.Changes
Terminology Rename (agent → operator)
ConsoleContent.tsx: Updated all references from "agent" to "operator" in props, state variables, event handlers, and rendered UI text. This includes renaming props/interfaces, internal logic, and any user-facing labels within the console component.ConsoleContent.test.tsx: Updated test cases to reflect the new "operator" naming — adjusted mock data, assertions, and test descriptions to match the renamed component API.src/__mocks__/@robosystems/client-clients.js: Updated mock implementations to use "operator" naming, ensuring test infrastructure stays consistent with the real module API.Dependency Update
package.json/package-lock.json: Bumped@robosystems/client-clientsto a version that reflects the same agent → operator rename upstream, keeping the client library and this application in sync.Repository Structure
src/lib/core/to align with the upstream core library commit (2360f69), ensuring the refactored code is properly synced.Key UI/UX Improvements
Breaking Changes
ConsoleContentcomponent API:agent(e.g.,agentId,agentName,onAgentChange, etc.) are now renamed to theiroperatorequivalents.@robosystems/client-clientsdependency version has changed; downstream consumers must also update to the compatible version.Testing Notes for Reviewers
ConsoleContent.test.tsxhas been revised to cover the renamed API. Runnpm testornpx jest ConsoleContentto verify all pass.@robosystems/client-clientsmock exports match the new operator-based API surface — checksrc/__mocks__/@robosystems/client-clients.jsfor correctness.agent(case-insensitive) in component code to confirm no references were missed.Browser Compatibility Considerations
🤖 Generated with Claude Code
Branch Info:
refactor/operator-agent-renamemainCo-Authored-By: Claude noreply@anthropic.com