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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
9830f9a2
Commit
9830f9a2
authored
May 25, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated subscribe icon
parent
051dc1d2
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
4 deletions
+27
-4
app/assets/javascripts/subscription.js.coffee
app/assets/javascripts/subscription.js.coffee
+5
-0
app/assets/stylesheets/pages/labels.scss
app/assets/stylesheets/pages/labels.scss
+16
-0
app/views/projects/labels/_label.html.haml
app/views/projects/labels/_label.html.haml
+6
-4
No files found.
app/assets/javascripts/subscription.js.coffee
View file @
9830f9a2
...
@@ -19,3 +19,8 @@ class @Subscription
...
@@ -19,3 +19,8 @@ class @Subscription
action
=
if
status
==
'subscribed'
then
'Unsubscribe'
else
'Subscribe'
action
=
if
status
==
'subscribed'
then
'Unsubscribe'
else
'Subscribe'
btn
.
find
(
'span'
).
text
(
action
)
btn
.
find
(
'span'
).
text
(
action
)
@
subscription_status
.
find
(
'>div'
).
toggleClass
(
'hidden'
)
@
subscription_status
.
find
(
'>div'
).
toggleClass
(
'hidden'
)
if
btn
.
attr
(
'data-original-title'
)
btn
.
tooltip
(
'hide'
)
.
attr
(
'data-original-title'
,
action
)
.
tooltip
(
'fixTitle'
)
app/assets/stylesheets/pages/labels.scss
View file @
9830f9a2
...
@@ -166,3 +166,19 @@
...
@@ -166,3 +166,19 @@
.label-options-toggle
{
.label-options-toggle
{
width
:
100%
;
width
:
100%
;
}
}
.label-subscribe-button
{
.label-subscribe-button-loading
{
display
:
none
;
}
&
.disabled
{
.label-subscribe-button-icon
{
display
:
none
;
}
.label-subscribe-button-loading
{
display
:
block
;
}
}
}
app/views/projects/labels/_label.html.haml
View file @
9830f9a2
...
@@ -32,16 +32,18 @@
...
@@ -32,16 +32,18 @@
-
if
current_user
-
if
current_user
.label-subscription.inline
{
data:
{
url:
toggle_subscription_namespace_project_label_path
(
@project
.
namespace
,
@project
,
label
)
}
}
.label-subscription.inline
{
data:
{
url:
toggle_subscription_namespace_project_label_path
(
@project
.
namespace
,
@project
,
label
)
}
}
%button
.js-subscribe-button.label-subscribe-button.btn.btn-transparent.btn-action.subscription-status
{
type:
"button"
,
data:
{
toggle:
"tooltip"
,
status:
label_subscription_status
(
label
)
}
}
%button
.js-subscribe-button.label-subscribe-button.btn.btn-transparent.btn-action.subscription-status
{
type:
"button"
,
title:
label_subscription_toggle_button_text
(
label
),
data:
{
toggle:
"tooltip"
,
status:
label_subscription_status
(
label
)
}
}
%span
=
label_subscription_toggle_button_text
(
label
)
%span
.sr-only
=
label_subscription_toggle_button_text
(
label
)
=
icon
(
'eye'
,
class:
'label-subscribe-button-icon'
)
=
icon
(
'spinner spin'
,
class:
'label-subscribe-button-loading'
)
-
if
can?
current_user
,
:admin_label
,
@project
-
if
can?
current_user
,
:admin_label
,
@project
=
link_to
edit_namespace_project_label_path
(
@project
.
namespace
,
@project
,
label
),
title:
"Edit"
,
class:
'btn btn-transparent btn-action'
,
data:
{
toggle:
"tooltip"
}
do
=
link_to
edit_namespace_project_label_path
(
@project
.
namespace
,
@project
,
label
),
title:
"Edit"
,
class:
'btn btn-transparent btn-action'
,
data:
{
toggle:
"tooltip"
}
do
%span
.sr-only
Edit
%span
.sr-only
Edit
%i
.fa.fa-pencil-square-o
=
icon
(
'pencil-square-o'
)
=
link_to
namespace_project_label_path
(
@project
.
namespace
,
@project
,
label
),
title:
"Delete"
,
class:
'btn btn-transparent btn-action remove-row'
,
method: :delete
,
remote:
true
,
data:
{
confirm:
"Remove this label? Are you sure?"
,
toggle:
"tooltip"
}
do
=
link_to
namespace_project_label_path
(
@project
.
namespace
,
@project
,
label
),
title:
"Delete"
,
class:
'btn btn-transparent btn-action remove-row'
,
method: :delete
,
remote:
true
,
data:
{
confirm:
"Remove this label? Are you sure?"
,
toggle:
"tooltip"
}
do
%span
.sr-only
Delete
%span
.sr-only
Delete
%i
.fa.fa-trash-o
=
icon
(
'trash-o'
)
-
if
current_user
-
if
current_user
:javascript
:javascript
...
...
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