Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feat][New Feature]: Added a new instruction selector dropdown menu #54

Merged
merged 6 commits into from
Dec 2, 2024

Conversation

lumpinif
Copy link
Collaborator

@lumpinif lumpinif commented Dec 2, 2024

New Feature: Instruction Selector Dropdown menu

Screenshot 2024-12-02 064643

Overview

  • The feature provides an intuitive way to quickly select and manage instructions in the chat interface.
  • Directly use updated instructions from the quick selection dropdown menu in the new chat - no copy & paste instructions anymore

UI/UX Improvements

New Selection Interface

  • Implemented a clean, non-intrusive selection component that integrates seamlessly with Claude's existing UI
  • Added dynamic instruction detection and highlighting for better visual feedback
  • Enhanced text insertion reliability to ensure smooth user interaction

User Experience Enhancements

  • Quick access to instruction selection without disrupting the chat flow
  • Intelligent container management that adapts to Claude's input area
  • Smooth cleanup and state management when switching between conversations

Technical Implementation

Architecture

  • Built using a modular approach with dedicated feature scoping
  • Implemented reactive DOM observation for reliable input container detection
  • Clean separation of concerns between selection, content handling, and UI management

Key Components

  • TCInstructionSelector: Core feature class managing initialization and lifecycle
  • Dynamic input container processing with automatic cleanup
  • Mutation observer integration for reliable DOM updates

Testing Instructions

  1. Open a new chat with Claude
  2. Observe the new instruction selector interface
  3. Try selecting different instructions
  4. Verify smooth insertion into the chat input
  5. Test across different chat contexts and page refreshes

Version

  • Version bump to 3.2.0

Documentation

  • Updated CHANGELOG.md with feature details
  • Added inline documentation for key components

…selecting instruction

- Add new instruction UI components (description, item, select)
- Implement input selector feature with container processing
- Update extension manager with new feature and new observer
- Update tailwind config and constants
- Add clipboard-based text insertion with retry mechanism
- Implement async/await for better insertion control
- Refactor instruction selector components
- Add content sync between UI and input
- Add new utility functions for text handling
- Improve mutation observer configuration
@lumpinif lumpinif added enhancement New feature or request feature labels Dec 2, 2024
@lumpinif lumpinif self-assigned this Dec 2, 2024
@richards199999 richards199999 merged commit 6c4f798 into richards199999:main Dec 2, 2024
2 checks passed
@richards199999
Copy link
Owner

I have reviewed and tested. Wow! It's just fantastic. Thank you @lumpinif !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants