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
Boxiang Sun
gitlab-ce
Commits
492e0062
Commit
492e0062
authored
Jun 02, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Corrected all sidebar font weights to correctly match the design
parent
ffd07382
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
28 additions
and
30 deletions
+28
-30
app/assets/javascripts/due_date_select.js.coffee
app/assets/javascripts/due_date_select.js.coffee
+3
-2
app/assets/javascripts/labels_select.js.coffee
app/assets/javascripts/labels_select.js.coffee
+1
-1
app/assets/javascripts/milestone_select.js.coffee
app/assets/javascripts/milestone_select.js.coffee
+2
-6
app/assets/javascripts/users_select.js.coffee
app/assets/javascripts/users_select.js.coffee
+3
-3
app/assets/stylesheets/pages/issuable.scss
app/assets/stylesheets/pages/issuable.scss
+4
-0
app/helpers/projects_helper.rb
app/helpers/projects_helper.rb
+1
-1
app/views/shared/issuable/_sidebar.html.haml
app/views/shared/issuable/_sidebar.html.haml
+14
-17
No files found.
app/assets/javascripts/due_date_select.js.coffee
View file @
492e0062
...
@@ -32,7 +32,7 @@ class @DueDateSelect
...
@@ -32,7 +32,7 @@ class @DueDateSelect
date
=
new
Date
value
.
replace
(
new
RegExp
(
'-'
,
'g'
),
','
)
date
=
new
Date
value
.
replace
(
new
RegExp
(
'-'
,
'g'
),
','
)
mediumDate
=
$
.
datepicker
.
formatDate
'M d, yy'
,
date
mediumDate
=
$
.
datepicker
.
formatDate
'M d, yy'
,
date
else
else
mediumDate
=
'No
n
e'
mediumDate
=
'No
due dat
e'
data
=
{}
data
=
{}
data
[
abilityName
]
=
{}
data
[
abilityName
]
=
{}
...
@@ -50,7 +50,8 @@ class @DueDateSelect
...
@@ -50,7 +50,8 @@ class @DueDateSelect
$selectbox
.
hide
()
$selectbox
.
hide
()
$value
.
css
(
'display'
,
''
)
$value
.
css
(
'display'
,
''
)
$valueContent
.
html
(
mediumDate
)
cssClass
=
if
mediumDate
is
"No due date"
then
'no-value'
else
'bold'
$valueContent
.
html
(
"<span class='
#{
cssClass
}
'>
#{
mediumDate
}
</span>"
)
$sidebarValue
.
html
(
mediumDate
)
$sidebarValue
.
html
(
mediumDate
)
if
value
isnt
''
if
value
isnt
''
...
...
app/assets/javascripts/labels_select.js.coffee
View file @
492e0062
...
@@ -39,7 +39,7 @@ class @LabelsSelect
...
@@ -39,7 +39,7 @@ class @LabelsSelect
</a>
</a>
<% }); %>'
<% }); %>'
)
)
labelNoneHTMLTemplate
=
_
.
template
(
'<
div class="light">None</div
>'
)
labelNoneHTMLTemplate
=
_
.
template
(
'<
span class="no-value">None</span
>'
)
if
newLabelField
.
length
if
newLabelField
.
length
...
...
app/assets/javascripts/milestone_select.js.coffee
View file @
492e0062
...
@@ -24,14 +24,10 @@ class @MilestoneSelect
...
@@ -24,14 +24,10 @@ class @MilestoneSelect
if
issueUpdateURL
if
issueUpdateURL
milestoneLinkTemplate
=
_
.
template
(
milestoneLinkTemplate
=
_
.
template
(
'<a href="/<%= namespace %>/<%= path %>/milestones/<%= iid %>">
'<a href="/<%= namespace %>/<%= path %>/milestones/<%= iid %>" class="bold has-tooltip" data-container="body" title="<%= remaining %>"><%= _.escape(title) %></a>'
<span class="has-tooltip" data-container="body" title="<%= remaining %>">
<%= _.escape(title) %>
</span>
</a>'
)
)
milestoneLinkNoneTemplate
=
'<
div class="light">None</div
>'
milestoneLinkNoneTemplate
=
'<
span class="no-value">None</span
>'
collapsedSidebarLabelTemplate
=
_
.
template
(
collapsedSidebarLabelTemplate
=
_
.
template
(
'<span class="has-tooltip" data-container="body" title="<%= remaining %>" data-placement="left">
'<span class="has-tooltip" data-container="body" title="<%= remaining %>" data-placement="left">
...
...
app/assets/javascripts/users_select.js.coffee
View file @
492e0062
...
@@ -72,7 +72,7 @@ class @UsersSelect
...
@@ -72,7 +72,7 @@ class @UsersSelect
assigneeTemplate
=
_
.
template
(
assigneeTemplate
=
_
.
template
(
'<% if (username) { %>
'<% if (username) { %>
<a class="author_link " href="/u/<%= username %>">
<a class="author_link
bold
" href="/u/<%= username %>">
<% if( avatar ) { %>
<% if( avatar ) { %>
<img width="32" class="avatar avatar-inline s32" alt="" src="<%= avatar %>">
<img width="32" class="avatar avatar-inline s32" alt="" src="<%= avatar %>">
<% } %>
<% } %>
...
@@ -82,9 +82,9 @@ class @UsersSelect
...
@@ -82,9 +82,9 @@ class @UsersSelect
</span>
</span>
</a>
</a>
<% } else { %>
<% } else { %>
<span class="assign-yourself">
<span class="
no-value
assign-yourself">
No assignee -
No assignee -
<a href="#" class="
light
js-assign-yourself">
<a href="#" class="js-assign-yourself">
assign yourself
assign yourself
</a>
</a>
</span>
</span>
...
...
app/assets/stylesheets/pages/issuable.scss
View file @
492e0062
...
@@ -153,6 +153,10 @@
...
@@ -153,6 +153,10 @@
font-weight
:
normal
;
font-weight
:
normal
;
}
}
.no-value
{
color
:
$gl-placeholder-color
;
}
.sidebar-collapsed-icon
{
.sidebar-collapsed-icon
{
display
:
none
;
display
:
none
;
}
}
...
...
app/helpers/projects_helper.rb
View file @
492e0062
...
@@ -49,7 +49,7 @@ module ProjectsHelper
...
@@ -49,7 +49,7 @@ module ProjectsHelper
author_html
=
author_html
.
html_safe
author_html
=
author_html
.
html_safe
if
opts
[
:name
]
if
opts
[
:name
]
link_to
(
author_html
,
user_path
(
author
),
class:
"author_link
#{
"
#{
opts
[
:mobile_classes
]
}
"
if
opts
[
:mobile_classes
]
}
"
).
html_safe
link_to
(
author_html
,
user_path
(
author
),
class:
"author_link
#{
"
#{
opts
[
:
extra_class
]
}
"
if
opts
[
:extra_class
]
}
#{
"
#{
opts
[
:
mobile_classes
]
}
"
if
opts
[
:mobile_classes
]
}
"
).
html_safe
else
else
title
=
opts
[
:title
].
sub
(
":name"
,
sanitize
(
author
.
name
))
title
=
opts
[
:title
].
sub
(
":name"
,
sanitize
(
author
.
name
))
link_to
(
author_html
,
user_path
(
author
),
class:
"author_link has-tooltip"
,
title:
title
,
data:
{
container:
'body'
}
).
html_safe
link_to
(
author_html
,
user_path
(
author
),
class:
"author_link has-tooltip"
,
title:
title
,
data:
{
container:
'body'
}
).
html_safe
...
...
app/views/shared/issuable/_sidebar.html.haml
View file @
492e0062
...
@@ -17,19 +17,18 @@
...
@@ -17,19 +17,18 @@
=
icon
(
'spinner spin'
,
class:
'block-loading'
)
=
icon
(
'spinner spin'
,
class:
'block-loading'
)
-
if
can_edit_issuable
-
if
can_edit_issuable
=
link_to
'Edit'
,
'#'
,
class:
'edit-link pull-right'
=
link_to
'Edit'
,
'#'
,
class:
'edit-link pull-right'
.value.
bold.
hide-collapsed
.value.hide-collapsed
-
if
issuable
.
assignee
-
if
issuable
.
assignee
=
link_to_member
(
@project
,
issuable
.
assignee
,
size:
32
)
do
=
link_to_member
(
@project
,
issuable
.
assignee
,
size:
32
,
extra_class:
'bold'
)
do
-
if
issuable
.
instance_of?
(
MergeRequest
)
&&
!
issuable
.
can_be_merged_by?
(
issuable
.
assignee
)
-
if
issuable
.
instance_of?
(
MergeRequest
)
&&
!
issuable
.
can_be_merged_by?
(
issuable
.
assignee
)
%span
.pull-right.cannot-be-merged
{
data:
{
toggle:
'tooltip'
,
placement:
'left'
},
title:
'Not allowed to merge'
}
%span
.pull-right.cannot-be-merged
{
data:
{
toggle:
'tooltip'
,
placement:
'left'
},
title:
'Not allowed to merge'
}
=
icon
(
'exclamation-triangle'
)
=
icon
(
'exclamation-triangle'
)
%span
.username
%span
.username
=
issuable
.
assignee
.
to_reference
=
issuable
.
assignee
.
to_reference
-
else
-
else
%span
.assign-yourself
%span
.assign-yourself
.no-value
No assignee
No assignee
-
if
can_edit_issuable
-
if
can_edit_issuable
%span
.light
\-
\-
%a
.js-assign-yourself
{
href:
'#'
}
%a
.js-assign-yourself
{
href:
'#'
}
assign yourself
assign yourself
...
@@ -52,13 +51,11 @@
...
@@ -52,13 +51,11 @@
=
icon
(
'spinner spin'
,
class:
'block-loading'
)
=
icon
(
'spinner spin'
,
class:
'block-loading'
)
-
if
can_edit_issuable
-
if
can_edit_issuable
=
link_to
'Edit'
,
'#'
,
class:
'edit-link pull-right'
=
link_to
'Edit'
,
'#'
,
class:
'edit-link pull-right'
.value.
bold.
hide-collapsed
.value.hide-collapsed
-
if
issuable
.
milestone
-
if
issuable
.
milestone
=
link_to
namespace_project_milestone_path
(
@project
.
namespace
,
@project
,
issuable
.
milestone
)
do
=
link_to
issuable
.
milestone
.
title
,
namespace_project_milestone_path
(
@project
.
namespace
,
@project
,
issuable
.
milestone
),
class:
"bold has-tooltip"
,
title:
milestone_remaining_days
(
issuable
.
milestone
),
data:
{
container:
"body"
,
html:
1
}
%span
.has-tooltip
{
title:
milestone_remaining_days
(
issuable
.
milestone
),
data:
{
container:
'body'
,
html:
1
}}
=
issuable
.
milestone
.
title
-
else
-
else
None
%span
.no-value
None
.selectbox.hide-collapsed
.selectbox.hide-collapsed
=
f
.
hidden_field
'milestone_id'
,
value:
issuable
.
milestone_id
,
id:
nil
=
f
.
hidden_field
'milestone_id'
,
value:
issuable
.
milestone_id
,
id:
nil
...
@@ -75,14 +72,14 @@
...
@@ -75,14 +72,14 @@
=
icon
(
'spinner spin'
,
class:
'block-loading'
)
=
icon
(
'spinner spin'
,
class:
'block-loading'
)
-
if
can?
(
current_user
,
:"admin_
#{
issuable
.
to_ability_name
}
"
,
@project
)
-
if
can?
(
current_user
,
:"admin_
#{
issuable
.
to_ability_name
}
"
,
@project
)
=
link_to
'Edit'
,
'#'
,
class:
'edit-link pull-right'
=
link_to
'Edit'
,
'#'
,
class:
'edit-link pull-right'
.value.
bold.
hide-collapsed
.value.hide-collapsed
%span
.value-content
%span
.value-content
-
if
issuable
.
due_date
-
if
issuable
.
due_date
=
issuable
.
due_date
.
to_s
(
:medium
)
%span
.bold
=
issuable
.
due_date
.
to_s
(
:medium
)
-
else
-
else
Non
e
%span
.no-value
No due dat
e
-
if
can?
(
current_user
,
:"admin_
#{
issuable
.
to_ability_name
}
"
,
@project
)
-
if
can?
(
current_user
,
:"admin_
#{
issuable
.
to_ability_name
}
"
,
@project
)
%span
.
light
.js-remove-due-date-holder
{
class:
(
"hidden"
if
issuable
.
due_date
.
nil?
)
}
%span
.
no-value
.js-remove-due-date-holder
{
class:
(
"hidden"
if
issuable
.
due_date
.
nil?
)
}
\-
\-
%a
.js-remove-due-date
{
href:
"#"
,
role:
"button"
}
%a
.js-remove-due-date
{
href:
"#"
,
role:
"button"
}
remove due date
remove due date
...
@@ -114,7 +111,7 @@
...
@@ -114,7 +111,7 @@
-
issuable
.
labels_array
.
each
do
|
label
|
-
issuable
.
labels_array
.
each
do
|
label
|
=
link_to_label
(
label
,
type:
issuable
.
to_ability_name
)
=
link_to_label
(
label
,
type:
issuable
.
to_ability_name
)
-
else
-
else
None
%span
.no-value
None
.selectbox.hide-collapsed
.selectbox.hide-collapsed
-
issuable
.
labels_array
.
each
do
|
label
|
-
issuable
.
labels_array
.
each
do
|
label
|
=
hidden_field_tag
"
#{
issuable
.
to_ability_name
}
[label_names][]"
,
label
.
id
,
id:
nil
=
hidden_field_tag
"
#{
issuable
.
to_ability_name
}
[label_names][]"
,
label
.
id
,
id:
nil
...
...
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