feat(chat): support skills choose in chat#928
Conversation
- Added a new API endpoint to handle quick access skills. - Integrated skill selection UI in the ChatInput component with search functionality. - Updated translations for skill-related terms in English, Japanese, Russian, and Chinese. - Enhanced unit tests to cover new skill selection behavior.
…e agent directory resolution - Changed skill source from 'system' to 'agents' in QuickAccessSkill interface. - Enhanced the buildDescriptors function to support personal and project-level agent directories. - Updated tests to reflect changes in skill prioritization and source labeling for agents. - Removed unused resolveSystemRoots function to streamline code.
… legacy support - Introduced support for legacy skill sources in QuickAccessSkill interface. - Updated collectQuickAccessSkills to include legacy skill roots with lower priority. - Implemented filterEnabledQuickAccessSkills to manage skill visibility based on runtime and configuration states. - Enhanced unit tests to validate new legacy skill handling and filtering logic.
- Updated text size from 15px to a consistent 'text-sm' class in multiple components including ChannelConfigModal, ProvidersSettings, and ChatInput. - Enhanced readability and uniformity in UI elements by applying consistent styling to CardDescription and related text elements. - Adjusted related tests to ensure alignment with the new text size standards.
…t and responsiveness - Updated badge components in SkillDetailDialog to use 'shrink-0' and 'whitespace-nowrap' classes for improved layout. - Adjusted flex properties to ensure proper wrapping and alignment of skill metadata. - Enhanced overall UI consistency and responsiveness in the skill detail view.
…styling - Expanded Tailwind configuration to include ClawX-specific design tokens for font sizes, font families, and colors. - Updated components across the application (e.g., ChannelConfigModal, Sidebar, ProvidersSettings) to utilize new design tokens for improved consistency and readability. - Standardized text sizes and background colors to align with ClawX's visual language, enhancing overall UI coherence. - Adjusted various components to replace hardcoded styles with semantic class names, improving maintainability and responsiveness.
- Modified class order in the Chat component to enhance layout consistency. - Ensured that the component maintains proper spacing and alignment based on content state (empty vs. filled). - Improved overall readability and maintainability of the styling.
- Changed "Skill" to "Skills" in English, Japanese, and Russian chat localization files for consistency. - Ensured proper formatting by adding a newline at the end of each file.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 879f757ae6
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
|
||
| const leadingSpace = needsLeadingSkillSpace(nextValue, adjustedStart) ? ' ' : ''; | ||
| nextValue = `${nextValue.slice(0, adjustedStart)}${leadingSpace}${nextToken}${nextValue.slice(adjustedEnd)}`; | ||
| setSelectedSkill(null); |
There was a problem hiding this comment.
Store selected skill when inserting a token
The skill-option click handler clears selectedSkill instead of recording the chosen skill, so selectedSkill stays null for the entire session. That breaks the cleanup path in the currentAgentId effect (which relies on selectedSkill to remove an inserted token on agent switch), allowing a stale /skill token from the previous agent context to remain in the composer and be sent against the wrong workspace/skill set.
Useful? React with 👍 / 👎.
Summary
feat(chat): implement quick access skills feature in ChatInput component
refactor(tailwind-config): enhance ClawX design tokens and component styling
Related Issue(s)
Type of Change
Validation
Checklist