8000 Front-End Engineering Onsite Task: Implementing "/" Command for Data Source Attachment · Issue #13264 · dust-tt/dust · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Front-End Engineering Onsite Task: Implementing "/" Command for Data Source Attachment #13264
Open
@JulesBelveze

Description

@JulesBelveze

Ambition

Implement a "/" command in the input bar that allows users to search and attach data sources from their workspace, replicating the functionality of the "Attach file" button in a more keyboard-friendly way.

Inspirations

  • Slack's "/" commands for quick actions
  • Notion's "/" command for block insertion
  • Discord's "/" commands for interactive elements
  • Similar to our existing "Attach file" button workflow but triggered via keyboard

Task for the day

Implement a "/" command that opens a search interface for workspace data sources and allows attaching them as chips in the input bar.

Core Requirements

Trigger Mechanism

  • Detect "/" typed at the beginning of input or after a space
  • Show search interface overlay positioned near the input cursor
  • Handle escape/click outside to dismiss

Search Functionality

  • Search through workspace data sources (same as "Attach file" functionality)
  • Display results with data source names and types
  • Support keyboard navigation (arrow keys, enter to select)
  • Filter results as user continues typing after "/"

Attachment & UI

  • On selection, attach the data source as an attachment
  • Add a removable chip in the input bar showing the attached source
  • Remove the "/" command text from input
  • Allow multiple data source attachments

Guidelines

  1. Focus on user experience - smooth, intuitive interaction flow
  2. Reuse existing components from our sparkle design system where possible
  3. Integration - work with your task buddy for minimal codebase integration
  4. Flexibility - use any tools/libraries/frameworks you prefer for implementation

Tips

  • Study the existing "Attach file" button implementation for data source search logic
  • Consider accessibility (keyboard navigation, screen readers)
  • Handle edge cases (empty search, no results, network errors)
  • Test the interaction flow thoroughly before integrating

Success Criteria

  • "/" command reliably triggers search interface
  • Users can search and select data sources via keyboard
  • Selected sources appear as chips and are properly attached
  • Interface dismisses appropriately and doesn't interfere with normal typing

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0