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
c4201f10
Commit
c4201f10
authored
Apr 18, 2018
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added changes count to web IDE folder
#44846
parent
8a1b6b78
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
4 deletions
+16
-4
app/assets/javascripts/ide/components/repo_file.vue
app/assets/javascripts/ide/components/repo_file.vue
+11
-2
app/assets/javascripts/ide/stores/getters.js
app/assets/javascripts/ide/stores/getters.js
+3
-0
app/assets/stylesheets/pages/repo.scss
app/assets/stylesheets/pages/repo.scss
+2
-2
No files found.
app/assets/javascripts/ide/components/repo_file.vue
View file @
c4201f10
<
script
>
import
{
mapActions
}
from
'
vuex
'
;
import
{
mapActions
,
mapGetters
}
from
'
vuex
'
;
import
skeletonLoadingContainer
from
'
~/vue_shared/components/skeleton_loading_container.vue
'
;
import
fileIcon
from
'
~/vue_shared/components/file_icon.vue
'
;
import
router
from
'
../ide_router
'
;
...
...
@@ -29,6 +29,10 @@ export default {
},
},
computed
:
{
...
mapGetters
([
'
getChangesInFolder
'
]),
folderChangedCount
()
{
return
this
.
getChangesInFolder
(
this
.
file
.
path
);
},
isTree
()
{
return
this
.
file
.
type
===
'
tree
'
;
},
...
...
@@ -101,9 +105,14 @@ export default {
<mr-file-icon
v-if=
"file.mrChange"
/>
<span
v-if=
"isTree && folderChangedCount > 0"
>
{{
folderChangedCount
}}
</span>
<changed-file-icon
v-else-if=
"file.changed || file.tempFile"
:file=
"file"
v-if=
"file.changed || file.tempFile"
/>
</span>
<new-dropdown
...
...
app/assets/javascripts/ide/stores/getters.js
View file @
c4201f10
...
...
@@ -35,3 +35,6 @@ export const currentIcon = state =>
export
const
hasChanges
=
state
=>
!!
state
.
changedFiles
.
length
;
export
const
hasMergeRequest
=
state
=>
!!
state
.
currentMergeRequestId
;
export
const
getChangesInFolder
=
state
=>
path
=>
state
.
changedFiles
.
filter
(
f
=>
f
.
path
.
indexOf
(
path
)
===
0
&&
!
f
.
tempFile
).
length
;
app/assets/stylesheets/pages/repo.scss
View file @
c4201f10
...
...
@@ -601,11 +601,11 @@
}
.multi-file-addition
{
fill
:
$green-500
;
color
:
$green-500
;
}
.multi-file-modified
{
fill
:
$orange-500
;
color
:
$orange-500
;
}
.multi-file-commit-list-collapsed
{
...
...
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