Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
47c1009c
Commit
47c1009c
authored
Jan 19, 2017
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed filter issue
parent
8a7299db
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
6 deletions
+6
-6
app/assets/javascripts/filtered_search/dropdown_non_user.js.es6
...sets/javascripts/filtered_search/dropdown_non_user.js.es6
+1
-1
app/assets/javascripts/filtered_search/dropdown_utils.js.es6
app/assets/javascripts/filtered_search/dropdown_utils.js.es6
+2
-1
app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js.es6
...s/filtered_search/filtered_search_dropdown_manager.js.es6
+3
-4
No files found.
app/assets/javascripts/filtered_search/dropdown_non_user.js.es6
View file @
47c1009c
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
loadingTemplate: this.loadingTemplate,
loadingTemplate: this.loadingTemplate,
},
},
droplabFilter: {
droplabFilter: {
filterFunction: gl.DropdownUtils.filterWithSymbol.bind(null, this.symbol),
filterFunction: gl.DropdownUtils.filterWithSymbol.bind(null, this.symbol
, input
),
},
},
};
};
}
}
...
...
app/assets/javascripts/filtered_search/dropdown_utils.js.es6
View file @
47c1009c
...
@@ -20,8 +20,9 @@
...
@@ -20,8 +20,9 @@
return escapedText;
return escapedText;
}
}
static filterWithSymbol(filterSymbol, i
tem, query
) {
static filterWithSymbol(filterSymbol, i
nput, item
) {
const updatedItem = item;
const updatedItem = item;
const query = gl.DropdownUtils.getSearchInput(input).trim();
const { lastToken, searchToken } = gl.FilteredSearchTokenizer.processTokens(query);
const { lastToken, searchToken } = gl.FilteredSearchTokenizer.processTokens(query);
if (lastToken !== searchToken) {
if (lastToken !== searchToken) {
...
...
app/assets/javascripts/filtered_search/filtered_search_dropdown_manager.js.es6
View file @
47c1009c
...
@@ -90,10 +90,9 @@
...
@@ -90,10 +90,9 @@
this.font = window.getComputedStyle(this.filteredSearchInput).font;
this.font = window.getComputedStyle(this.filteredSearchInput).font;
}
}
const inputText = gl.DropdownUtils.getSearchInput(this.filteredSearchInput).trim();
const filterIconPadding = 27;
const filterIconPadding = 27;
const offset = gl.text
const offset = gl.text.getTextWidth(inputText, this.font) + filterIconPadding;
.getTextWidth(gl.DropdownUtils.getSearchInput(this.filteredSearchInput).trim(), this.font)
+ filterIconPadding;
this.mapping[key].reference.setOffset(offset);
this.mapping[key].reference.setOffset(offset);
}
}
...
@@ -151,7 +150,7 @@
...
@@ -151,7 +150,7 @@
const { lastToken, searchToken } = this.tokenizer
const { lastToken, searchToken } = this.tokenizer
.processTokens(gl.DropdownUtils.getSearchInput(this.filteredSearchInput));
.processTokens(gl.DropdownUtils.getSearchInput(this.filteredSearchInput));
if (this.
filteredSearchInput.value.split('').last() === ' '
) {
if (this.
currentDropdown
) {
this.updateCurrentDropdownOffset();
this.updateCurrentDropdownOffset();
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment