BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
8c22568d
Commit
8c22568d
authored
May 23, 2018
by
Filipa Lacerda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merge branch 'ide-file-finder-improve-order' into 'master'
Fixed IDE file finder ordering See merge request gitlab-org/gitlab-ce!18948
parent
d9734c25
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
5 deletions
+12
-5
index.vue
app/assets/javascripts/ide/components/file_finder/index.vue
+2
-4
ide.vue
app/assets/javascripts/ide/components/ide.vue
+4
-1
ide_spec.js
spec/javascripts/ide/components/ide_spec.js
+6
-0
No files found.
app/assets/javascripts/ide/components/file_finder/index.vue
View file @
8c22568d
...
...
@@ -39,12 +39,10 @@ export default {
return
this
.
allBlobs
.
slice
(
0
,
MAX_FILE_FINDER_RESULTS
);
}
return
fuzzaldrinPlus
.
filter
(
this
.
allBlobs
,
searchText
,
{
return
fuzzaldrinPlus
.
filter
(
this
.
allBlobs
,
searchText
,
{
key
:
'path'
,
maxResults
:
MAX_FILE_FINDER_RESULTS
,
})
.
sort
((
a
,
b
)
=>
b
.
lastOpenedAt
-
a
.
lastOpenedAt
);
});
},
filteredBlobsLength
()
{
return
this
.
filteredBlobs
.
length
;
...
...
app/assets/javascripts/ide/components/ide.vue
View file @
8c22568d
...
...
@@ -52,7 +52,10 @@ export default {
methods
:
{
...
mapActions
([
'toggleFileFinder'
]),
mousetrapStopCallback
(
e
,
el
,
combo
)
{
if
(
combo
===
't'
&&
el
.
classList
.
contains
(
'dropdown-input-field'
))
{
if
(
(
combo
===
't'
&&
el
.
classList
.
contains
(
'dropdown-input-field'
))
||
el
.
classList
.
contains
(
'inputarea'
)
)
{
return
true
;
}
else
if
(
combo
===
'command+p'
||
combo
===
'ctrl+p'
)
{
return
false
;
...
...
spec/javascripts/ide/components/ide_spec.js
View file @
8c22568d
...
...
@@ -107,5 +107,11 @@ describe('ide component', () => {
vm
.
mousetrapStopCallback
(
null
,
vm
.
$el
.
querySelector
(
'.dropdown-input-field'
),
't'
),
).
toBe
(
true
);
});
it
(
'stops callback in monaco editor'
,
()
=>
{
setFixtures
(
'<div class="inputarea"></div>'
);
expect
(
vm
.
mousetrapStopCallback
(
null
,
document
.
querySelector
(
'.inputarea'
),
't'
)).
toBe
(
true
);
});
});
});
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