Skip to content

Add some filtered search token improvements and fixes

Coung Ngo requested to merge cngo-filtered-search-improvements into master

What does this MR do and why?

This MR adds some filtered search token improvements and fixes.

  • Allow any token component that implements BaseToken to get recentSuggestionsStorageKey from the config, so we don't have to do :recent-suggestions-storage-key="config.recentSuggestionsStorageKey" in every implementing token
  • Fix bug where activeTokenValue parameter of handleTokenValueSelected in BaseToken is undefined
  • Show No matches found when there are no results from a search
  • On group/project issues list, add recent suggestions for various tokens
  • On group/project issues list, match filtered bar labels search on title only. GraphQL doesn't allow title-only filtering so this is done in the frontend for now (backend issue: #346353)

Screenshots or screen recordings

no matches found recently used
Screenshot_2021-11-23_at_11.59.16_am Screenshot_2021-11-23_at_11.59.05_am
BEFORE: activeTokenValue undefined bug (selection does not get added to recently used section) AFTER: activeTokenValue undefined bug fixed (selection gets added to recently used section)
Screen_Recording_2021-12-01_at_11.25.05_am Screen_Recording_2021-12-01_at_11.25.33_am

How to set up and validate locally

  1. In rails console enable the feature flag
    Feature.enable(:vue_issues_list)
  2. Visit any group or project issues list page such as http://127.0.0.1:3000/groups/flightjs/-/issues
  3. Test the MR

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Coung Ngo

Merge request reports