Skip to content

Conversation

@weinaike
Copy link

@weinaike weinaike commented Jan 6, 2026

This commit introduces a comprehensive tag expansion and command completion system across the application, enabling users to use shorthand tag commands (e.g., /tag_name arguments) that automatically expand to their full content.

Core Features:

  1. Tag Command Expansion Library (tagExpansion.ts)

    • Parse /tag_name syntax with optional arguments
    • Expand tag commands by replacing placeholders (, {args}, {{args}})
    • Support multiple commands in the same text
    • Handle Markdown escape characters properly
  2. Multi-Source Autocomplete (multi-file-search-textarea.tsx)

    • Added unified search for both tags and files
    • Support @ and / triggers for tag/command completion
    • Visual separation between tags and files in dropdown
    • Smart insertion logic based on trigger character
  3. WYSIWYG Editor Integration (file-tag-typeahead-plugin.tsx)

    • Extended typeahead to support both @ and / triggers
    • Different behavior based on trigger:
      • @tag_name: inserts full tag content
      • /tag_name: inserts command syntax for expansion
    • Improved text node replacement logic
  4. Task Form Integration (TaskFormDialog.tsx)

    • Automatically expand tag commands before task creation/update
    • Seamless integration with existing form submission flow
    • Error handling for expansion failures
  5. Follow-up Message Integration (TaskFollowUpSection.tsx, useFollowUpSend.ts)

    • Enable tag expansion for follow-up messages
    • Support tag commands in queued messages
    • Configurable expansion via expandTags flag

Technical Implementation:

  • Command parsing supports multiple /commands in the same text
  • Position-aware replacement (processes from end to start)
  • Graceful fallback if expansion fails
  • Unified search utility (searchTagsAndFiles) for consistent UX
  • Async expansion to support future enhancements

User Benefits:

  • Faster task creation with reusable templates
  • Consistent messaging with predefined tag content
  • Flexible argument passing for dynamic content
  • Intuitive autocomplete across the application

This commit introduces a comprehensive tag expansion and command completion system across the application, enabling users to use shorthand tag commands (e.g., /tag_name arguments) that automatically expand to their full content.

**Core Features:**

1. **Tag Command Expansion Library** (tagExpansion.ts)
   - Parse /tag_name syntax with optional arguments
   - Expand tag commands by replacing placeholders (, {args}, {{args}})
   - Support multiple commands in the same text
   - Handle Markdown escape characters properly

2. **Multi-Source Autocomplete** (multi-file-search-textarea.tsx)
   - Added unified search for both tags and files
   - Support @ and / triggers for tag/command completion
   - Visual separation between tags and files in dropdown
   - Smart insertion logic based on trigger character

3. **WYSIWYG Editor Integration** (file-tag-typeahead-plugin.tsx)
   - Extended typeahead to support both @ and / triggers
   - Different behavior based on trigger:
     - @tag_name: inserts full tag content
     - /tag_name: inserts command syntax for expansion
   - Improved text node replacement logic

4. **Task Form Integration** (TaskFormDialog.tsx)
   - Automatically expand tag commands before task creation/update
   - Seamless integration with existing form submission flow
   - Error handling for expansion failures

5. **Follow-up Message Integration** (TaskFollowUpSection.tsx, useFollowUpSend.ts)
   - Enable tag expansion for follow-up messages
   - Support tag commands in queued messages
   - Configurable expansion via expandTags flag

**Technical Implementation:**

- Command parsing supports multiple /commands in the same text
- Position-aware replacement (processes from end to start)
- Graceful fallback if expansion fails
- Unified search utility (searchTagsAndFiles) for consistent UX
- Async expansion to support future enhancements

**User Benefits:**

- Faster task creation with reusable templates
- Consistent messaging with predefined tag content
- Flexible argument passing for dynamic content
- Intuitive autocomplete across the application
@vibe-kanban-cloud
Copy link

Review Complete

Your review story is ready!

View Story

Comment !reviewfast on this PR to re-generate the story.

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.

1 participant