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
76d03f69
Commit
76d03f69
authored
Apr 25, 2017
by
Clement Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[skip ci] refactor into options argument
parent
57de747c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
2 deletions
+9
-2
app/assets/javascripts/gl_dropdown.js
app/assets/javascripts/gl_dropdown.js
+6
-1
app/assets/javascripts/users_select.js
app/assets/javascripts/users_select.js
+3
-1
No files found.
app/assets/javascripts/gl_dropdown.js
View file @
76d03f69
...
...
@@ -350,7 +350,12 @@ GitLabDropdown = (function() {
selectedObj
=
selected
?
selected
[
0
]
:
null
;
isMarking
=
selected
?
selected
[
1
]
:
null
;
if
(
this
.
options
.
clicked
)
{
this
.
options
.
clicked
.
call
(
this
,
selectedObj
,
$el
,
e
,
isMarking
);
this
.
options
.
clicked
.
call
(
this
,
{
user
:
selectedObj
,
$el
,
e
,
isMarking
,
});
}
// Update label right after all modifications in dropdown has been done
...
...
app/assets/javascripts/users_select.js
View file @
76d03f69
...
...
@@ -290,7 +290,9 @@ import eventHub from './sidebar/event_hub';
},
multiSelect
:
$dropdown
.
hasClass
(
'
js-multiselect
'
),
vue
:
$dropdown
.
hasClass
(
'
js-issue-board-sidebar
'
),
clicked
:
function
(
user
,
$el
,
e
,
isMarking
)
{
clicked
:
function
(
options
)
{
const
{
user
,
$el
,
e
,
isMarking
}
=
options
;
if
(
$dropdown
.
hasClass
(
'
js-multiselect
'
))
{
const
isActive
=
$el
.
hasClass
(
'
is-active
'
);
const
previouslySelected
=
$dropdown
.
closest
(
'
.selectbox
'
)
...
...
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