Merge pull request #1845 from Safelite/CSR-2072-fix-ampersand-issue-found-by-qa

CSR-2072 fix ampersand issue.
This commit is contained in:
bmauger 2024-05-07 11:33:27 -04:00 committed by GitHub
commit 67b9559db6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -150,21 +150,10 @@ export default {
},
minLength: 0, // Necessary to display fmenu when clearing input
// Bold matching letters as you type in the input
search: function (event, ui) {
setTimeout(() => {
let w = $(this).autocomplete("widget").find("div");
let regExpString = "(" + this.value + ")";
let re = new RegExp(regExpString, "i");
w.html((i, html) =>
html.replace(re, "<span style='font-weight: bold;'>$1</span>")
);
}, 5);
},
select: function (event, ui) {
select: function (ui) {
select(ui.item.value);
},
change: function (event, ui) {
change: function (ui) {
select(ui?.item?.value);
},
});