openedx / openedx/paragon

Provide better "search on type" support for `SearchField` component

Open
#3,767 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
140
Forks
100
Avg merge
1h 3m
Merged PRs (30d)
30

Description

The new frontend-app-catalog MFE is using the SearchField component in a way that allows users to search as they type

onChange={(value: string) => setSearchValue(value)}
onKeyDown={(e: React.KeyboardEvent<HTMLInputElement>) => {
  if (e.key === 'Enter') {
    e.preventDefault();
    handleSearch();
  }
}}
onSubmit={() => {}}

It'd be nice for consumers to be able to configure the SearchField component to use a "live search" mode without needing to preventDefault.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the SearchField implementation and its existing tests, then compare the linked frontend-app-catalog HomeBanner.tsx usage. Define how a configurable live-search mode should handle onChange and submit without requiring preventDefault, and verify the behavior with focused component tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.