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
f05696dc
Commit
f05696dc
authored
Sep 14, 2020
by
Thomas Randolph
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Expand the collapsed file UI and make it more visible
parent
9c5a27f0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
6 deletions
+19
-6
app/assets/javascripts/diffs/components/diff_file.vue
app/assets/javascripts/diffs/components/diff_file.vue
+13
-6
locale/gitlab.pot
locale/gitlab.pot
+6
-0
No files found.
app/assets/javascripts/diffs/components/diff_file.vue
View file @
f05696dc
<
script
>
import
{
mapActions
,
mapGetters
,
mapState
}
from
'
vuex
'
;
import
{
escape
}
from
'
lodash
'
;
import
{
GlLoadingIcon
,
GlSafeHtmlDirective
as
SafeHtml
}
from
'
@gitlab/ui
'
;
import
{
Gl
Button
,
Gl
LoadingIcon
,
GlSafeHtmlDirective
as
SafeHtml
}
from
'
@gitlab/ui
'
;
import
glFeatureFlagsMixin
from
'
~/vue_shared/mixins/gl_feature_flags_mixin
'
;
import
{
__
,
sprintf
}
from
'
~/locale
'
;
import
{
deprecatedCreateFlash
as
createFlash
}
from
'
~/flash
'
;
...
...
@@ -15,6 +15,7 @@ export default {
components
:
{
DiffFileHeader
,
DiffContent
,
GlButton
,
GlLoadingIcon
,
},
directives
:
{
...
...
@@ -205,11 +206,17 @@ export default {
<div
v-safe-html=
"errorMessage"
class=
"nothing-here-block"
></div>
</div>
<template
v-else
>
<div
v-show=
"isCollapsed"
class=
"nothing-here-block diff-collapsed"
>
{{
__
(
'
This diff is collapsed.
'
)
}}
<a
class=
"click-to-expand js-click-to-expand"
href=
"#"
@
click.prevent=
"handleToggle"
>
{{
__
(
'
Click to expand it.
'
)
}}
</a>
<div
v-show=
"isCollapsed"
class=
"gl-p-7 gl-text-center collapsed-file-warning"
>
<p
class=
"gl-mb-8 gl-mt-5"
>
{{
__
(
'
This file is collapsed.
'
)
}}
</p>
<gl-button
class=
"gl-alert-action gl-mb-5"
data-testid=
"expandButton"
@
click=
"handleToggle"
>
{{
__
(
'
Expand file
'
)
}}
</gl-button>
</div>
<diff-content
v-show=
"!isCollapsed && !isFileTooLarge"
...
...
locale/gitlab.pot
View file @
f05696dc
...
...
@@ -10357,6 +10357,9 @@ msgstr ""
msgid "Expand dropdown"
msgstr ""
msgid "Expand file"
msgstr ""
msgid "Expand milestones"
msgstr ""
...
...
@@ -25739,6 +25742,9 @@ msgstr ""
msgid "This field is required."
msgstr ""
msgid "This file is collapsed."
msgstr ""
msgid "This group"
msgstr ""
...
...
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