Add space logic to base token

What does this MR do and why?

This MR allows you to search for tokens values with spaces in the token.

Currently, this is not possible because gitlab-ui filtered search token creates a new token when the user hits the space bar.

Issues

  1. Because in new filtered search, iteration and epic are stored in the URL as ids not as their title, if I type out the iteration as shown below...and hit enter (not-selecting) the value in the dropdown, the title is going to be used for the fetch but the request is expecting ids.

2021-12-03_12.48.20

As @donaldcook pointed out, we should switch iteration_id and epic_id in the URL params to be iteration_title and epic_title, however, before we do that we need to make sure that we can filter boards (lists, issuesByList, and issues) and lists by iteration and epic title in graphql.

More info here: #347158 (closed)

Conclusion

Though this issue is concerning, I think its an edge case and a step in the right direction until we can resolve the epic and iteration title conversation.

Screenshots or screen recordings

These are strongly recommended to assist reviewers and reduce the time to merge your change.

How to set up and validate locally

  1. rails c
  2. Feature.enable(:issue_boards_filtered_Search)
  3. Search for anything in the dropdown with token values with a space using the starting ".
  4. watch it work 😄

Numbered steps to set up and validate the change are strongly suggested.

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 Scott Stern

Merge request reports

Loading