Skip to content

Don't escape search term in modal twice

What does this MR do and why?

The "Search or go to..." modal escapes the search term with sprintf in the bottom segment, which is unnecessary since the search term is already escaped by Vue when it gets displayed.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After
Screenshot_2024-02-19_at_09-54-11_Files___sv_dont-escape-search-twice___GitLab_Community___GitLab_Community_Fork___GitLab Screenshot_2024-02-19_at_09-50-55_I_User1___Lab_Coat___GitLab

How to set up and validate locally

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

  1. Click on the "Search or go to..." on a repo
  2. Enter a search query with a "
  3. Observe that there are no HTML entities displayed

Merge request reports