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
566d6ac4
Commit
566d6ac4
authored
Feb 08, 2018
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added change icon to file in IDE file list
parent
d7f74d4b
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
41 additions
and
32 deletions
+41
-32
app/assets/javascripts/ide/components/changed_file_icon.vue
app/assets/javascripts/ide/components/changed_file_icon.vue
+31
-0
app/assets/javascripts/ide/components/repo_file.vue
app/assets/javascripts/ide/components/repo_file.vue
+6
-11
app/assets/javascripts/ide/components/repo_tab.vue
app/assets/javascripts/ide/components/repo_tab.vue
+4
-10
app/assets/stylesheets/pages/repo.scss
app/assets/stylesheets/pages/repo.scss
+0
-11
No files found.
app/assets/javascripts/ide/components/changed_file_icon.vue
0 → 100644
View file @
566d6ac4
<
script
>
import
icon
from
'
../../vue_shared/components/icon.vue
'
;
export
default
{
components
:
{
icon
,
},
props
:
{
file
:
{
type
:
Object
,
required
:
true
,
},
},
computed
:
{
changedIcon
()
{
return
this
.
file
.
tempFile
?
'
file-addition
'
:
'
file-modified
'
;
},
changedIconClass
()
{
return
`multi-file-changed-icon
${
this
.
file
.
tempFile
?
'
multi-file-addition
'
:
'
multi-file-modified
'
}
`
;
},
},
};
</
script
>
<
template
>
<icon
:name=
"changedIcon"
:size=
"12"
:css-classes=
"changedIconClass"
/>
</
template
>
app/assets/javascripts/ide/components/repo_file.vue
View file @
566d6ac4
...
@@ -5,6 +5,7 @@
...
@@ -5,6 +5,7 @@
import
fileStatusIcon
from
'
./repo_file_status_icon.vue
'
;
import
fileStatusIcon
from
'
./repo_file_status_icon.vue
'
;
import
newDropdown
from
'
./new_dropdown/index.vue
'
;
import
newDropdown
from
'
./new_dropdown/index.vue
'
;
import
fileIcon
from
'
../../vue_shared/components/file_icon.vue
'
;
import
fileIcon
from
'
../../vue_shared/components/file_icon.vue
'
;
import
changedFileIcon
from
'
./changed_file_icon.vue
'
;
export
default
{
export
default
{
components
:
{
components
:
{
...
@@ -12,6 +13,7 @@
...
@@ -12,6 +13,7 @@
newDropdown
,
newDropdown
,
fileStatusIcon
,
fileStatusIcon
,
fileIcon
,
fileIcon
,
changedFileIcon
,
},
},
mixins
:
[
mixins
:
[
timeAgoMixin
,
timeAgoMixin
,
...
@@ -61,11 +63,6 @@
...
@@ -61,11 +63,6 @@
}
}
return
''
;
return
''
;
},
},
changedClass
()
{
return
{
'
fa-circle unsaved-icon
'
:
this
.
file
.
changed
||
this
.
file
.
tempFile
,
};
},
},
},
updated
()
{
updated
()
{
if
(
this
.
file
.
type
===
'
blob
'
&&
this
.
file
.
active
)
{
if
(
this
.
file
.
type
===
'
blob
'
&&
this
.
file
.
active
)
{
...
@@ -118,13 +115,11 @@
...
@@ -118,13 +115,11 @@
:path=
"file.path"
:path=
"file.path"
:parent=
"file"
:parent=
"file"
/>
/>
<i
<changed-file-icon
class=
"fa"
v-if=
"file.changed || file.tempFile"
v-if=
"file.changed || file.tempFile"
:class=
"changedClass"
:file=
"file"
aria-hidden=
"true"
class=
"prepend-top-5 pull-right"
>
/>
</i>
<template
v-if=
"isSubmodule && file.id"
>
<template
v-if=
"isSubmodule && file.id"
>
@
@
<span
class=
"commit-sha"
>
<span
class=
"commit-sha"
>
...
...
app/assets/javascripts/ide/components/repo_tab.vue
View file @
566d6ac4
...
@@ -3,12 +3,14 @@
...
@@ -3,12 +3,14 @@
import
fileStatusIcon
from
'
./repo_file_status_icon.vue
'
;
import
fileStatusIcon
from
'
./repo_file_status_icon.vue
'
;
import
fileIcon
from
'
../../vue_shared/components/file_icon.vue
'
;
import
fileIcon
from
'
../../vue_shared/components/file_icon.vue
'
;
import
icon
from
'
../../vue_shared/components/icon.vue
'
;
import
icon
from
'
../../vue_shared/components/icon.vue
'
;
import
changedFileIcon
from
'
./changed_file_icon.vue
'
;
export
default
{
export
default
{
components
:
{
components
:
{
fileStatusIcon
,
fileStatusIcon
,
fileIcon
,
fileIcon
,
icon
,
icon
,
changedFileIcon
,
},
},
props
:
{
props
:
{
tab
:
{
tab
:
{
...
@@ -31,12 +33,6 @@
...
@@ -31,12 +33,6 @@
showChangedIcon
()
{
showChangedIcon
()
{
return
this
.
tab
.
changed
?
!
this
.
tabMouseOver
:
false
;
return
this
.
tab
.
changed
?
!
this
.
tabMouseOver
:
false
;
},
},
changedIcon
()
{
return
this
.
tab
.
tempFile
?
'
file-addition
'
:
'
file-modified
'
;
},
changedIconClass
()
{
return
this
.
tab
.
tempFile
?
'
multi-file-addition
'
:
'
multi-file-modified
'
;
},
},
},
methods
:
{
methods
:
{
...
@@ -77,11 +73,9 @@
...
@@ -77,11 +73,9 @@
name=
"close"
name=
"close"
:size=
"12"
:size=
"12"
/>
/>
<icon
<
changed-file-
icon
v-else
v-else
:name=
"changedIcon"
:file=
"tab"
:size=
"12"
:css-classes=
"changedIconClass"
/>
/>
</button>
</button>
...
...
app/assets/stylesheets/pages/repo.scss
View file @
566d6ac4
...
@@ -50,13 +50,6 @@
...
@@ -50,13 +50,6 @@
text-overflow
:
ellipsis
;
text-overflow
:
ellipsis
;
}
}
.unsaved-icon
{
color
:
$indigo-700
;
float
:
right
;
font-size
:
smaller
;
line-height
:
20px
;
}
.repo-new-btn
{
.repo-new-btn
{
display
:
none
;
display
:
none
;
margin-top
:
-4px
;
margin-top
:
-4px
;
...
@@ -67,10 +60,6 @@
...
@@ -67,10 +60,6 @@
.repo-new-btn
{
.repo-new-btn
{
display
:
block
;
display
:
block
;
}
}
.unsaved-icon
{
display
:
none
;
}
}
}
&
.folder
{
&
.folder
{
...
...
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