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
662a3c33
Commit
662a3c33
authored
Nov 29, 2018
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Backport of draft-design-improvements changes
parent
938b891f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
8 deletions
+12
-8
app/assets/javascripts/notes/components/note_form.vue
app/assets/javascripts/notes/components/note_form.vue
+11
-7
app/assets/javascripts/notes/mixins/resolvable.js
app/assets/javascripts/notes/mixins/resolvable.js
+1
-1
No files found.
app/assets/javascripts/notes/components/note_form.vue
View file @
662a3c33
...
@@ -48,13 +48,19 @@ export default {
...
@@ -48,13 +48,19 @@ export default {
required
:
false
,
required
:
false
,
default
:
''
,
default
:
''
,
},
},
resolveDiscussion
:
{
type
:
Boolean
,
required
:
false
,
default
:
false
,
},
},
},
data
()
{
data
()
{
return
{
return
{
updatedNoteBody
:
this
.
noteBody
,
updatedNoteBody
:
this
.
noteBody
,
conflictWhileEditing
:
false
,
conflictWhileEditing
:
false
,
isSubmitting
:
false
,
isSubmitting
:
false
,
isResolving
:
false
,
isResolving
:
this
.
resolveDiscussion
,
isUnresolving
:
!
this
.
resolveDiscussion
,
resolveAsThread
:
true
,
resolveAsThread
:
true
,
};
};
},
},
...
@@ -149,7 +155,7 @@ export default {
...
@@ -149,7 +155,7 @@ export default {
<div
ref=
"editNoteForm"
class=
"note-edit-form current-note-edit-form js-discussion-note-form"
>
<div
ref=
"editNoteForm"
class=
"note-edit-form current-note-edit-form js-discussion-note-form"
>
<div
v-if=
"conflictWhileEditing"
class=
"js-conflict-edit-warning alert alert-danger"
>
<div
v-if=
"conflictWhileEditing"
class=
"js-conflict-edit-warning alert alert-danger"
>
This comment has changed since you started editing, please review the
This comment has changed since you started editing, please review the
<a
:href=
"noteHash"
target=
"_blank"
rel=
"noopener noreferrer"
>
updated comment
</a>
to ensure
<a
:href=
"noteHash"
target=
"_blank"
rel=
"noopener noreferrer"
>
updated comment
</a>
to ensure
information is not lost.
information is not lost.
</div>
</div>
<div
class=
"flash-container timeline-content"
></div>
<div
class=
"flash-container timeline-content"
></div>
...
@@ -174,22 +180,20 @@ export default {
...
@@ -174,22 +180,20 @@ export default {
v-model=
"updatedNoteBody"
v-model=
"updatedNoteBody"
:data-supports-quick-actions=
"!isEditing"
:data-supports-quick-actions=
"!isEditing"
name=
"note[note]"
name=
"note[note]"
class=
"note-textarea js-gfm-input js-note-text
class=
"note-textarea js-gfm-input js-note-text js-autosize markdown-area js-vue-issue-note-form js-vue-textarea qa-reply-input"
js-autosize markdown-area js-vue-issue-note-form js-vue-textarea qa-reply-input"
aria-label=
"Description"
aria-label=
"Description"
placeholder=
"Write a comment or drag your files here…"
placeholder=
"Write a comment or drag your files here…"
@
keydown.meta.enter=
"handleUpdate();"
@
keydown.meta.enter=
"handleUpdate();"
@
keydown.ctrl.enter=
"handleUpdate();"
@
keydown.ctrl.enter=
"handleUpdate();"
@
keydown.up=
"editMyLastNote();"
@
keydown.up=
"editMyLastNote();"
@
keydown.esc=
"cancelHandler(true);"
@
keydown.esc=
"cancelHandler(true);"
>
></textarea>
</textarea>
</markdown-field>
</markdown-field>
<div
class=
"note-form-actions clearfix"
>
<div
class=
"note-form-actions clearfix"
>
<button
<button
:disabled=
"isDisabled"
:disabled=
"isDisabled"
type=
"button"
type=
"button"
class=
"js-vue-issue-save btn btn-success js-comment-button
"
class=
"js-vue-issue-save btn btn-success js-comment-button"
@
click=
"handleUpdate();"
@
click=
"handleUpdate();"
>
>
{{
saveButtonTitle
}}
{{
saveButtonTitle
}}
...
...
app/assets/javascripts/notes/mixins/resolvable.js
View file @
662a3c33
...
@@ -36,7 +36,7 @@ export default {
...
@@ -36,7 +36,7 @@ export default {
const
discussion
=
this
.
resolveAsThread
;
const
discussion
=
this
.
resolveAsThread
;
const
endpoint
=
discussion
?
this
.
discussion
.
resolve_path
:
`
${
this
.
note
.
path
}
/resolve`
;
const
endpoint
=
discussion
?
this
.
discussion
.
resolve_path
:
`
${
this
.
note
.
path
}
/resolve`
;
this
.
toggleResolveNote
({
endpoint
,
isResolved
,
discussion
})
return
this
.
toggleResolveNote
({
endpoint
,
isResolved
,
discussion
})
.
then
(()
=>
{
.
then
(()
=>
{
this
.
isResolving
=
false
;
this
.
isResolving
=
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