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
01eb0571
Commit
01eb0571
authored
Nov 14, 2016
by
Clement Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Resolve MR review suggestions
parent
7f460919
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
21 deletions
+15
-21
app/assets/javascripts/filtered_search/filtered_search_bundle.js
...ets/javascripts/filtered_search/filtered_search_bundle.js
+0
-6
app/assets/javascripts/filtered_search/filtered_search_manager.js.es6
...avascripts/filtered_search/filtered_search_manager.js.es6
+14
-14
app/assets/javascripts/filtered_search/filtered_search_tokenizer.es6
...javascripts/filtered_search/filtered_search_tokenizer.es6
+1
-1
No files found.
app/assets/javascripts/filtered_search/filtered_search_bundle.js
View file @
01eb0571
/* eslint-disable */
// This is a manifest file that'll be compiled into including all the files listed below.
// Add new JavaScript code in separate files in this directory and they'll automatically
// be included in the compiled file accessible from http://example.com/assets/application.js
...
...
@@ -6,8 +5,3 @@
// the compiled file.
//
/*= require_tree . */
(
function
()
{
}).
call
(
this
);
\ No newline at end of file
app/assets/javascripts/filtered_search/filtered_search_manager.js.es6
View file @
01eb0571
...
...
@@ -18,22 +18,22 @@
param: 'name[]',
}];
function clearSearch(e
vent
) {
e
vent
.stopPropagation();
e
vent
.preventDefault();
function clearSearch(e) {
e.stopPropagation();
e.preventDefault();
document.querySelector('.filtered-search').value = '';
document.querySelector('.clear-search').classList.add('hidden');
}
function toggleClearSearchButton(e
vent
) {
function toggleClearSearchButton(e) {
const clearSearchButton = document.querySelector('.clear-search');
if (event.target.value) {
clearSearchButton.classList.remove('hidden');
} else {
clearSearchButton.classList.add('hidden');
}
clearSearchButton.classList.remove('hidden');
} else {
clearSearchButton.classList.add('hidden');
}
}
function loadSearchParamsFromURL() {
...
...
@@ -97,16 +97,16 @@
document.querySelector('.clear-search').addEventListener('click', clearSearch);
}
processInput(e
vent
) {
const input = e
vent
.target.value;
processInput(e) {
const input = e.target.value;
this.tokenizer.processTokens(input);
}
checkForEnter(e
vent
) {
checkForEnter(e) {
// Enter KeyCode
if (e
vent
.keyCode === 13) {
e
vent
.stopPropagation();
e
vent
.preventDefault();
if (e.keyCode === 13) {
e.stopPropagation();
e.preventDefault();
this.search();
}
}
...
...
app/assets/javascripts/filtered_search/filtered_search_tokenizer.es6
View file @
01eb0571
...
...
@@ -36,7 +36,7 @@
inputs.forEach((i) => {
if (incompleteToken) {
const prevToken = this.tokens
[this.tokens.length - 1]
;
const prevToken = this.tokens
.last()
;
prevToken.value += ` ${i}`;
// Remove last quotation
...
...
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