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
d1d4b576
Commit
d1d4b576
authored
Apr 29, 2020
by
Thomas Randolph
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a mutation to change the `viewer` of a diffFile
parent
9d960418
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
+7
-0
app/assets/javascripts/diffs/store/mutation_types.js
app/assets/javascripts/diffs/store/mutation_types.js
+2
-0
app/assets/javascripts/diffs/store/mutations.js
app/assets/javascripts/diffs/store/mutations.js
+5
-0
No files found.
app/assets/javascripts/diffs/store/mutation_types.js
View file @
d1d4b576
...
...
@@ -41,6 +41,8 @@ export const SET_CURRENT_VIEW_DIFF_FILE_LINES = 'SET_CURRENT_VIEW_DIFF_FILE_LINE
export
const
ADD_CURRENT_VIEW_DIFF_FILE_LINES
=
'
ADD_CURRENT_VIEW_DIFF_FILE_LINES
'
;
export
const
TOGGLE_DIFF_FILE_RENDERING_MORE
=
'
TOGGLE_DIFF_FILE_RENDERING_MORE
'
;
export
const
SET_DIFF_FILE_VIEWER
=
'
SET_DIFF_FILE_VIEWER
'
;
export
const
SET_SHOW_SUGGEST_POPOVER
=
'
SET_SHOW_SUGGEST_POPOVER
'
;
export
const
TOGGLE_LINE_DISCUSSIONS
=
'
TOGGLE_LINE_DISCUSSIONS
'
;
app/assets/javascripts/diffs/store/mutations.js
View file @
d1d4b576
...
...
@@ -383,6 +383,11 @@ export default {
file
.
renderingLines
=
!
file
.
renderingLines
;
},
[
types
.
SET_DIFF_FILE_VIEWER
](
state
,
{
filePath
,
viewer
})
{
const
file
=
findDiffFile
(
state
.
diffFiles
,
filePath
,
'
file_path
'
);
file
.
viewer
=
viewer
;
},
[
types
.
SET_SHOW_SUGGEST_POPOVER
](
state
)
{
state
.
showSuggestPopover
=
false
;
},
...
...
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