Code review changes
This commit is contained in:
parent
3d0b0a6260
commit
1bfdad5c47
|
@ -84,7 +84,7 @@
|
|||
break;
|
||||
case 'projects:merge_requests:index':
|
||||
case 'projects:issues:index':
|
||||
if (document.querySelector('.filtered-search') && gl.FilteredSearchManager) {
|
||||
if (gl.FilteredSearchManager) {
|
||||
new gl.FilteredSearchManager();
|
||||
}
|
||||
Issuable.init();
|
||||
|
|
|
@ -39,7 +39,7 @@ require('../window')(function(w){
|
|||
|
||||
var loadingTemplate = document.createElement('div');
|
||||
loadingTemplate.innerHTML = config.loadingTemplate;
|
||||
loadingTemplate.setAttribute('data-loading-template', true);
|
||||
loadingTemplate.setAttribute('data-loading-template', '');
|
||||
|
||||
this.listTemplate = dynamicList.outerHTML;
|
||||
dynamicList.outerHTML = loadingTemplate.outerHTML;
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
(() => {
|
||||
class FilteredSearchTokenizer {
|
||||
static processTokens(input) {
|
||||
// Regex extracts `(token):(symbol)(value)`
|
||||
// Values that start with a double quote must end in a double quote (same for single)
|
||||
const tokenRegex = /(\w+):([~%@]?)(?:('[^']*'{0,1})|("[^"]*"{0,1})|(\S+))/g;
|
||||
const tokens = [];
|
||||
let lastToken = null;
|
||||
|
|
Loading…
Reference in New Issue