BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
a958a046
Commit
a958a046
authored
Aug 11, 2016
by
Clement Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix contributions calendar month label truncation
parent
f7b64a46
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
1 deletion
+16
-1
CHANGELOG
CHANGELOG
+1
-0
calendar.js
app/assets/javascripts/users/calendar.js
+15
-1
No files found.
CHANGELOG
View file @
a958a046
...
...
@@ -55,6 +55,7 @@ v 8.12.0 (unreleased)
- Ability to manage project issues, snippets, wiki, merge requests and builds access level
- Remove inconsistent font weight for sidebar's labels (ClemMakesApps)
- Align add button on repository view (ClemMakesApps)
- Fix contributions calendar month label truncation (ClemMakesApps)
- Added tests for diff notes
- Add a button to download latest successful artifacts for branches and tags !5142
- Remove redundant pipeline tooltips (ClemMakesApps)
...
...
app/assets/javascripts/users/calendar.js
View file @
a958a046
...
...
@@ -52,8 +52,22 @@
this
.
initTooltips
();
}
// Add extra padding for the last month label if it is also the last column
Calendar
.
prototype
.
getExtraWidthPadding
=
function
(
group
)
{
var
extraWidthPadding
=
0
;
var
lastColMonth
=
this
.
timestampsTmp
[
group
-
1
][
0
].
date
.
getMonth
();
var
secondLastColMonth
=
this
.
timestampsTmp
[
group
-
2
][
0
].
date
.
getMonth
();
if
(
lastColMonth
!=
secondLastColMonth
)
{
extraWidthPadding
=
3
;
}
return
extraWidthPadding
;
}
Calendar
.
prototype
.
renderSvg
=
function
(
group
)
{
return
this
.
svg
=
d3
.
select
(
'.js-contrib-calendar'
).
append
(
'svg'
).
attr
(
'width'
,
(
group
+
1
)
*
this
.
daySizeWithSpace
).
attr
(
'height'
,
167
).
attr
(
'class'
,
'contrib-calendar'
);
var
width
=
(
group
+
1
)
*
this
.
daySizeWithSpace
+
this
.
getExtraWidthPadding
(
group
);
return
this
.
svg
=
d3
.
select
(
'.js-contrib-calendar'
).
append
(
'svg'
).
attr
(
'width'
,
width
).
attr
(
'height'
,
167
).
attr
(
'class'
,
'contrib-calendar'
);
};
Calendar
.
prototype
.
renderDays
=
function
()
{
...
...
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