Skip to content

Feature: Built-in search bar to find events by title or description #3

@thbst16

Description

@thbst16

Description

For timelines with many events, users need a way to quickly locate specific events by searching text content rather than manually scrolling through decades.

Use Case

A user viewing NFL history wants to find all events related to "Packers" or "Super Bowl" without manually panning through 100+ years of history.

Proposed Solution

  • Add showSearch prop to render a search input
  • Search should match against title, description, and optionally custom fields
  • Matching events should be highlighted and the timeline should auto-pan to the first result
  • Provide prev/next navigation for multiple matches
  • Support onSearch callback for custom search implementations

Example API

<Timeline
  data={data}
  showSearch={true}
  searchFields={['title', 'description']}
  onSearch={(query, results) => console.log(`Found ${results.length} events`)}
/>

Issue generated from user feedback while building an NFL history timeline

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions