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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
0ab8264e
Commit
0ab8264e
authored
Jul 01, 2016
by
Phil Hughes
Committed by
Douwe Maan
Jul 24, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
VueJS updates
parent
70b46b28
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
13 additions
and
10 deletions
+13
-10
app/assets/javascripts/line_comments/application.js.coffee
app/assets/javascripts/line_comments/application.js.coffee
+6
-2
app/assets/javascripts/line_comments/components/resolve_all.js.coffee
...avascripts/line_comments/components/resolve_all.js.coffee
+1
-3
app/assets/javascripts/line_comments/components/resolve_btn.js.coffee
...avascripts/line_comments/components/resolve_btn.js.coffee
+4
-3
app/views/projects/merge_requests/_show.html.haml
app/views/projects/merge_requests/_show.html.haml
+1
-1
app/views/projects/notes/_note.html.haml
app/views/projects/notes/_note.html.haml
+1
-1
No files found.
app/assets/javascripts/line_comments/application.js.coffee
View file @
0ab8264e
...
...
@@ -2,9 +2,13 @@
#= require_directory ./stores
#= require_directory ./components
$
-
>
new
Vue
$
=
>
@
DiffNotesApp
=
new
Vue
el
:
'#notes'
components
:
'resolve-btn'
:
ResolveBtn
new
Vue
el
:
'#resolve-all-app'
components
:
'resolve-all'
:
ResolveAll
app/assets/javascripts/line_comments/components/resolve_all.js.coffee
View file @
0ab8264e
ResolveAll
=
Vue
.
extend
@
ResolveAll
=
Vue
.
extend
data
:
->
{
comments
:
CommentsStore
.
state
}
computed
:
...
...
@@ -15,5 +15,3 @@ ResolveAll = Vue.extend
updateAll
:
->
resolveAll
=
!
(
this
.
resolved
is
this
.
commentsCount
)
CommentsStore
.
updateAll
(
resolveAll
)
Vue
.
component
'resolve-all'
,
ResolveAll
app/assets/javascripts/line_comments/components/resolve_btn.js.coffee
View file @
0ab8264e
ResolveBtn
=
Vue
.
extend
@
ResolveBtn
=
Vue
.
extend
props
:
noteId
:
Number
resolved
:
Boolean
...
...
@@ -18,7 +18,8 @@ ResolveBtn = Vue.extend
this
.
$nextTick
this
.
updateTooltip
compiled
:
->
$
(
this
.
$el
).
tooltip
()
destroyed
:
->
console
.
log
this
.
noteId
created
:
->
console
.
log
this
.
noteId
CommentsStore
.
create
(
this
.
noteId
,
this
.
resolved
)
Vue
.
component
'resolve-btn'
,
ResolveBtn
app/views/projects/merge_requests/_show.html.haml
View file @
0ab8264e
...
...
@@ -47,7 +47,7 @@
#resolve-all-app
{
"v-cloak"
=>
true
}
%resolve-all
{
"inline-template"
=>
true
}
.line-resolve-all
{
"v-show"
=>
"commentsCount > 0"
}
%button
.btn.btn-gray
{
type:
"button"
,
"aria-label"
=>
"Resolve all"
,
"
v-on:
click"
=>
"updateAll"
}
%button
.btn.btn-gray
{
type:
"button"
,
"aria-label"
=>
"Resolve all"
,
"
@
click"
=>
"updateAll"
}
{{ buttonText }}
%span
.line-resolve-text
{{ resolved }}/{{ commentsCount }} comments resolved
...
...
app/views/projects/notes/_note.html.haml
View file @
0ab8264e
...
...
@@ -22,7 +22,7 @@
%span
.note-role.hidden-xs
=
access
-
unless
note
.
system
%resolve-btn
{
":note-id"
=>
note
.
id
,
":resolved"
=>
"false"
,
"inline-template"
=>
true
}
%button
.note-action-button.line-resolve-btn
{
type:
"button"
,
"
v-bind:class"
=>
"{ 'is-active': isResolved }"
,
"v-bind:aria-label"
=>
"buttonText"
,
"v-on:click"
=>
"resolve"
,
"v-bind
:title"
=>
"buttonText"
}
%button
.note-action-button.line-resolve-btn
{
type:
"button"
,
"
:class"
=>
"{ 'is-active': isResolved }"
,
":aria-label"
=>
"buttonText"
,
"@click"
=>
"resolve"
,
"
:title"
=>
"buttonText"
}
=
icon
(
"check"
)
-
if
current_user
and
not
note
.
system
=
link_to
'#'
,
title:
'Award Emoji'
,
class:
'note-action-button note-emoji-button js-add-award js-note-emoji'
,
data:
{
position:
'right'
}
do
...
...
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