Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

We intend to modify the search functionality in the new MFE such that:

...

Figma mockups: https://www.figma.com/file/LVFnO9oRHYiamoicZuXDAC/Discussion-page?node-id=1604%3A1338

Search functionality in general

...

Tab selected

Show Search info bar

Show Filter/ sort bar

Placeholder text

Search box logic

My posts

Yes

Yes (with same options as without search, reset to default sort upon search)

Search all posts

Same as in legacy. Searches for provided string in post title, content, response and comments.

All posts

Yes

Yes (with same options as without search, reset to default sort upon search)

Search all posts

Same as in legacy. Searches for provided string in post title, content, response and comments.

Topics

Yes

No

Search topics

Same as legacy. Filters topics based on provided string on the frontend.

Learners

Yes

Yes (with same options as without search, reset to default sort upon search)

Search all learners

Same as legacy. Filters users based on provided string. It will still search users when a particular user is selected.

Searching content

The following behaviour is illustrated for when All Posts and My Posts tab is selected.

Action

Mockup

Default view of All Posts or My Posts tab.

  1. User enters a string in search bar.

  1. User clicks the search icon in search bar.

  1. Search info bar appears on top of list pane. Posts filter bar and post summaries are pushed below the search info bar.

  2. Search info bar shows the number of search results and the search string.

  3. “Clear results” option can be used to clear search results and return to default state of view in All posts or My posts tab.

  4. Filter bar shall remain available.

All filtering/sorting in filter bar will be done on frontend. This is supported by legacy as well.

Legacy view:

Image RemovedImage Added

Warping long search strings.

...

Actions

Mockup

  1. User enters the search string in search bar.

  1. Search info bar appears on top of list pane. Topic lists or post summaries are pushed below the search info bar.

  2. Search info bar shows the number of search results and the search string.

  3. “Clear results” option can be used to clear search results and return to default state of view in Topics tab.

Will we search 3rd level of hierarchy? How will those results be rendered?

Searching users

The following behaviour is illustrated for when Learners tab is selected.

Actions

Mockup

Search bar will still search learners even if a learner is already selected.