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
f518f8e3
Commit
f518f8e3
authored
Oct 12, 2018
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'upstream/master' into ce-to-ee-2018-10-12
parents
840c3381
a5ecb5bb
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
27 additions
and
8 deletions
+27
-8
app/assets/javascripts/diffs/components/diff_file_header.vue
app/assets/javascripts/diffs/components/diff_file_header.vue
+7
-3
app/assets/javascripts/notes/components/diff_with_note.vue
app/assets/javascripts/notes/components/diff_with_note.vue
+1
-0
changelogs/unreleased/50185-fix-broken-file-name-navigation.yml
...logs/unreleased/50185-fix-broken-file-name-navigation.yml
+5
-0
doc/administration/integration/plantuml.md
doc/administration/integration/plantuml.md
+2
-2
spec/javascripts/diffs/components/diff_file_header_spec.js
spec/javascripts/diffs/components/diff_file_header_spec.js
+12
-3
No files found.
app/assets/javascripts/diffs/components/diff_file_header.vue
View file @
f518f8e3
...
@@ -20,6 +20,11 @@ export default {
...
@@ -20,6 +20,11 @@ export default {
Tooltip
,
Tooltip
,
},
},
props
:
{
props
:
{
discussionPath
:
{
type
:
String
,
required
:
false
,
default
:
''
,
},
diffFile
:
{
diffFile
:
{
type
:
Object
,
type
:
Object
,
required
:
true
,
required
:
true
,
...
@@ -65,8 +70,7 @@ export default {
...
@@ -65,8 +70,7 @@ export default {
if
(
this
.
diffFile
.
submodule
)
{
if
(
this
.
diffFile
.
submodule
)
{
return
this
.
diffFile
.
submoduleTreeUrl
||
this
.
diffFile
.
submoduleLink
;
return
this
.
diffFile
.
submoduleTreeUrl
||
this
.
diffFile
.
submoduleLink
;
}
}
return
this
.
discussionPath
;
return
`#
${
this
.
diffFile
.
fileHash
}
`
;
},
},
filePath
()
{
filePath
()
{
if
(
this
.
diffFile
.
submodule
)
{
if
(
this
.
diffFile
.
submodule
)
{
...
@@ -152,7 +156,7 @@ export default {
...
@@ -152,7 +156,7 @@ export default {
v-once
v-once
ref=
"titleWrapper"
ref=
"titleWrapper"
:href=
"titleLink"
:href=
"titleLink"
class=
"append-right-4"
class=
"append-right-4
js-title-wrapper
"
>
>
<file-icon
<file-icon
:file-name=
"filePath"
:file-name=
"filePath"
...
...
app/assets/javascripts/notes/components/diff_with_note.vue
View file @
f518f8e3
...
@@ -94,6 +94,7 @@ export default {
...
@@ -94,6 +94,7 @@ export default {
class=
"diff-file file-holder"
class=
"diff-file file-holder"
>
>
<diff-file-header
<diff-file-header
:discussion-path=
"discussion.discussionPath"
:diff-file=
"diffFile"
:diff-file=
"diffFile"
:can-current-user-fork=
"false"
:can-current-user-fork=
"false"
:discussions-expanded=
"isDiscussionsExpanded"
:discussions-expanded=
"isDiscussionsExpanded"
...
...
changelogs/unreleased/50185-fix-broken-file-name-navigation.yml
0 → 100644
View file @
f518f8e3
---
title
:
Fix broken file name navigation on MRs
merge_request
:
22109
author
:
type
:
fixed
doc/administration/integration/plantuml.md
View file @
f518f8e3
...
@@ -80,10 +80,10 @@ our AsciiDoc snippets, wikis and repos using delimited blocks:
...
@@ -80,10 +80,10 @@ our AsciiDoc snippets, wikis and repos using delimited blocks:
```
```
[plantuml, format="png", id="myDiagram", width="200px"]
[plantuml, format="png", id="myDiagram", width="200px"]
--
--
--
Bob->Alice : hello
Bob->Alice : hello
Alice -> Bob : Go Away
Alice -> Bob : Go Away
--
--
--
```
```
-
**reStructuredText**
-
**reStructuredText**
...
...
spec/javascripts/diffs/components/diff_file_header_spec.js
View file @
f518f8e3
...
@@ -6,6 +6,8 @@ import DiffFileHeader from '~/diffs/components/diff_file_header.vue';
...
@@ -6,6 +6,8 @@ import DiffFileHeader from '~/diffs/components/diff_file_header.vue';
import
{
convertObjectPropsToCamelCase
}
from
'
~/lib/utils/common_utils
'
;
import
{
convertObjectPropsToCamelCase
}
from
'
~/lib/utils/common_utils
'
;
import
{
mountComponentWithStore
}
from
'
spec/helpers/vue_mount_component_helper
'
;
import
{
mountComponentWithStore
}
from
'
spec/helpers/vue_mount_component_helper
'
;
Vue
.
use
(
Vuex
);
const
discussionFixture
=
'
merge_requests/diff_discussion.json
'
;
const
discussionFixture
=
'
merge_requests/diff_discussion.json
'
;
describe
(
'
diff_file_header
'
,
()
=>
{
describe
(
'
diff_file_header
'
,
()
=>
{
...
@@ -58,19 +60,19 @@ describe('diff_file_header', () => {
...
@@ -58,19 +60,19 @@ describe('diff_file_header', () => {
describe
(
'
titleLink
'
,
()
=>
{
describe
(
'
titleLink
'
,
()
=>
{
beforeEach
(()
=>
{
beforeEach
(()
=>
{
props
.
discussionPath
=
'
link://to/discussion
'
;
Object
.
assign
(
props
.
diffFile
,
{
Object
.
assign
(
props
.
diffFile
,
{
fileHash
:
'
badc0ffee
'
,
submoduleLink
:
'
link://to/submodule
'
,
submoduleLink
:
'
link://to/submodule
'
,
submoduleTreeUrl
:
'
some://tree/url
'
,
submoduleTreeUrl
:
'
some://tree/url
'
,
});
});
});
});
it
(
'
returns the
fileHas
h for files
'
,
()
=>
{
it
(
'
returns the
discussionPat
h for files
'
,
()
=>
{
props
.
diffFile
.
submodule
=
false
;
props
.
diffFile
.
submodule
=
false
;
vm
=
mountComponentWithStore
(
Component
,
{
props
,
store
});
vm
=
mountComponentWithStore
(
Component
,
{
props
,
store
});
expect
(
vm
.
titleLink
).
toBe
(
`#
${
props
.
diffFile
.
fileHash
}
`
);
expect
(
vm
.
titleLink
).
toBe
(
props
.
discussionPath
);
});
});
it
(
'
returns the submoduleTreeUrl for submodules
'
,
()
=>
{
it
(
'
returns the submoduleTreeUrl for submodules
'
,
()
=>
{
...
@@ -91,6 +93,13 @@ describe('diff_file_header', () => {
...
@@ -91,6 +93,13 @@ describe('diff_file_header', () => {
expect
(
vm
.
titleLink
).
toBe
(
props
.
diffFile
.
submoduleLink
);
expect
(
vm
.
titleLink
).
toBe
(
props
.
diffFile
.
submoduleLink
);
});
});
it
(
'
sets the correct path to the discussion
'
,
()
=>
{
props
.
discussionPath
=
'
link://to/discussion
'
;
vm
=
mountComponentWithStore
(
Component
,
{
props
,
store
});
const
href
=
vm
.
$el
.
querySelector
(
'
.js-title-wrapper
'
).
getAttribute
(
'
href
'
);
expect
(
href
).
toBe
(
vm
.
discussionPath
);
});
});
});
describe
(
'
filePath
'
,
()
=>
{
describe
(
'
filePath
'
,
()
=>
{
...
...
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