Skip to content

Commit

Permalink
Invisible github (TODO)
Browse files Browse the repository at this point in the history
Sergey Polyarus committed Mar 5, 2024
1 parent 3d20d09 commit 97bff8e
Showing 3 changed files with 235 additions and 232 deletions.
2 changes: 1 addition & 1 deletion _layouts/default.html
Original file line number Diff line number Diff line change
@@ -8,7 +8,7 @@
{{ content }}

{% if page.url == "/" %}
<section class="github section">
<section class="github section invisible">
<div class="section-inner shadow-sm rounded">
<h2 class="heading">Mon activité sur GitHub</h2>
<div id="github-graph" class="github-graph"></div><!--//github-graph-->
5 changes: 4 additions & 1 deletion assets/plugins/github-activity/src/github-activity.js
Original file line number Diff line number Diff line change
@@ -193,6 +193,8 @@ var GitHubActivity = (function() {
var request = new XMLHttpRequest();
request.open('GET', url);
request.setRequestHeader('Accept', 'application/vnd.github.v3+json');
// SPOK: added header to avoid 403 error
request.setRequestHeader('User-Agent', 'request');
if (config.credentials && config.credentials.username && config.credentials.personalAccessToken) {
request.setRequestHeader('Authorization', 'Basic ' + btoa(config.credentials.username + ':' + config.credentials.personalAccessToken));
}
@@ -242,7 +244,8 @@ var GitHubActivity = (function() {
var selector = options.selector,
userUrl = 'https://api.github.com/users/' + options.username,
eventsUrl = userUrl + '/events',
header,
// SPOK: added header to avoid 403 error
header = 'User-Agent: request',
activity;

if (!!options.repository){
460 changes: 230 additions & 230 deletions assets/plugins/github-calendar/dist/github-calendar-responsive.css
Original file line number Diff line number Diff line change
@@ -1,231 +1,231 @@
:root {
--color-calendar-graph-day-bg: #dddbdb;
--color-calendar-graph-day-L1-bg: #39dd34;
--color-calendar-graph-day-L2-bg: #45a045;
--color-calendar-graph-day-L3-bg: #047526;
--color-calendar-graph-day-L4-bg: #0a4208;
}

.ContributionCalendar-day[data-level='0'] {
background-color: var(--color-calendar-graph-day-bg);
}

.ContributionCalendar-day[data-level='1'] {
background-color: var(--color-calendar-graph-day-L1-bg);
}

.ContributionCalendar-day[data-level='2'] {
background-color: var(--color-calendar-graph-day-L2-bg);
}

.ContributionCalendar-day[data-level='3'] {
background-color: var(--color-calendar-graph-day-L3-bg);
}

.ContributionCalendar-day[data-level='4'] {
background-color: var(--color-calendar-graph-day-L4-bg);
}

table.ContributionCalendar-grid {
margin-bottom: 0pt;
}

table.ContributionCalendar-grid td {
padding: 4pt;
}

table.ContributionCalendar-grid td span.sr-only {
display: none;
}

td.ContributionCalendar-label span[aria-hidden='true'] {
font-size: 8pt;
left: -1pt;
}

tool-tip {
display: none;
}

.calendar .width-full > .float-left {
display: none;
}

.calendar {
font-family: Helvetica, arial;
border: 1px solid #DDDDDD;
border-radius: 3px;
min-height: 243px;
text-align: center;
margin: 0 auto;
}

.calendar-graph text.wday,
.calendar-graph text.month {
font-size: 10px;
fill: #aaa;
}

div.px-md-5 {
height: 2rem;
}

div.float-right {
text-align: right;
padding: 0 14px 10px 0;
display: inline-block;
float: right;
}

div.float-right div {
display: inline-block;
list-style: none;
margin: 0 5px;
position: relative;
bottom: -1px;
padding: 0;
}

div.float-right span.sr-only {
display: none;
}

.contrib-legend .legend li {
display: inline-block;
width: 10px;
height: 10px;
}

.text-small {
font-size: 12px;
color: #767676;
}

.calendar-graph {
padding: 5px 0 0;
text-align: center;
}

.contrib-column {
padding: 15px 0;
text-align: center;
border-left: 1px solid #ddd;
border-top: 1px solid #ddd;
font-size: 11px;
}

.contrib-column-first {
border-left: 0;
}

.table-column {
box-sizing: border-box;
display: table-cell;
width: 1%;
padding-right: 10px;
padding-left: 10px;
vertical-align: top;
}

.contrib-number {
font-weight: 300;
line-height: 1.3em;
font-size: 24px;
display: block;
color: #333;
}

.calendar img.spinner {
width: 70px;
margin-top: 50px;
min-height: 70px;
}

.monospace {
text-align: center;
color: #000;
font-family: monospace;
}

.monospace a {
color: #1D75AB;
text-decoration: none;
}

.contrib-footer {
font-size: 11px;
padding: 0 10px 12px;
text-align: left;
width: 100%;
box-sizing: border-box;
height: 26px;
}

.left.text-muted {
float: left;
margin-left: 9px;
color: #767676;
}
.left.text-muted a {
color: #4078c0;
text-decoration: none;
}
.left.text-muted a:hover,
.monospace a:hover {
text-decoration: underline;
}

h2.f4.text-normal.mb-3 {
display: none;
}

.float-left.text-gray {
float: left;
}
#user-activity-overview{
display:none;
}

.day-tooltip {
white-space: nowrap;
position: absolute;
z-index: 99999;
padding: 10px;
font-size: 12px;
color: #959da5;
text-align: center;
background: rgba(0,0,0,.85);
border-radius: 3px;
display: none;
pointer-events: none;
}
.day-tooltip strong {
color: #dfe2e5;
}
.day-tooltip.is-visible {
display: block;
}
.day-tooltip:after {
position: absolute;
bottom: -10px;
left: 50%;
width: 5px;
height: 5px;
box-sizing: border-box;
margin: 0 0 0 -5px;
content: " ";
border: 5px solid transparent;
border-top-color: rgba(0,0,0,.85)
}

text.ContributionCalendar-label {
fill: #ccc;
font-size: 11px;
}

@media screen and (max-width: 768px) {
.table-column {
display: block;
width: 100%;
}
}
--color-calendar-graph-day-bg: #dddbdb;
--color-calendar-graph-day-L1-bg: #39dd34;
--color-calendar-graph-day-L2-bg: #45a045;
--color-calendar-graph-day-L3-bg: #047526;
--color-calendar-graph-day-L4-bg: #0a4208;
}
.ContributionCalendar-day[data-level='0'] {
background-color: var(--color-calendar-graph-day-bg);
}
.ContributionCalendar-day[data-level='1'] {
background-color: var(--color-calendar-graph-day-L1-bg);
}
.ContributionCalendar-day[data-level='2'] {
background-color: var(--color-calendar-graph-day-L2-bg);
}
.ContributionCalendar-day[data-level='3'] {
background-color: var(--color-calendar-graph-day-L3-bg);
}
.ContributionCalendar-day[data-level='4'] {
background-color: var(--color-calendar-graph-day-L4-bg);
}
table.ContributionCalendar-grid {
margin-bottom: 0pt;
}
table.ContributionCalendar-grid td {
padding: 4pt;
}
table.ContributionCalendar-grid td span.sr-only {
display: none;
}
td.ContributionCalendar-label span[aria-hidden='true'] {
font-size: 8pt;
left: -1pt;
}
tool-tip {
display: none;
}
.calendar .width-full > .float-left {
display: none;
}
.calendar {
font-family: Helvetica, arial;
border: 1px solid #DDDDDD;
border-radius: 3px;
min-height: 250px;
text-align: center;
margin: 0 auto;
}
.calendar-graph text.wday,
.calendar-graph text.month {
font-size: 10px;
fill: #aaa;
}
div.px-md-5 {
height: 2rem;
}
div.float-right {
text-align: right;
padding: 0 14px 10px 0;
display: inline-block;
float: right;
}
div.float-right div {
display: inline-block;
list-style: none;
margin: 0 5px;
position: relative;
bottom: -1px;
padding: 0;
}
div.float-right span.sr-only {
display: none;
}
.contrib-legend .legend li {
display: inline-block;
width: 10px;
height: 10px;
}
.text-small {
font-size: 12px;
color: #767676;
}
.calendar-graph {
padding: 5px 0 0;
text-align: center;
}
.contrib-column {
padding: 15px 0;
text-align: center;
border-left: 1px solid #ddd;
border-top: 1px solid #ddd;
font-size: 11px;
}
.contrib-column-first {
border-left: 0;
}
.table-column {
box-sizing: border-box;
display: table-cell;
width: 1%;
padding-right: 10px;
padding-left: 10px;
vertical-align: top;
}
.contrib-number {
font-weight: 300;
line-height: 1.3em;
font-size: 24px;
display: block;
color: #333;
}
.calendar img.spinner {
width: 70px;
margin-top: 50px;
min-height: 70px;
}
.monospace {
text-align: center;
color: #000;
font-family: monospace;
}
.monospace a {
color: #1D75AB;
text-decoration: none;
}
.contrib-footer {
font-size: 11px;
padding: 0 10px 12px;
text-align: left;
width: 100%;
box-sizing: border-box;
height: 26px;
}
.left.text-muted {
float: left;
margin-left: 9px;
color: #767676;
}
.left.text-muted a {
color: #4078c0;
text-decoration: none;
}
.left.text-muted a:hover,
.monospace a:hover {
text-decoration: underline;
}
h2.f4.text-normal.mb-3 {
display: none;
}
.float-left.text-gray {
float: left;
}
#user-activity-overview{
display:none;
}
.day-tooltip {
white-space: nowrap;
position: absolute;
z-index: 99999;
padding: 10px;
font-size: 12px;
color: #959da5;
text-align: center;
background: rgba(0,0,0,.85);
border-radius: 3px;
display: none;
pointer-events: none;
}
.day-tooltip strong {
color: #dfe2e5;
}
.day-tooltip.is-visible {
display: block;
}
.day-tooltip:after {
position: absolute;
bottom: -10px;
left: 50%;
width: 5px;
height: 5px;
box-sizing: border-box;
margin: 0 0 0 -5px;
content: " ";
border: 5px solid transparent;
border-top-color: rgba(0,0,0,.85)
}
text.ContributionCalendar-label {
fill: #ccc;
font-size: 11px;
}
@media screen and (max-width: 768px) {
.table-column {
display: block;
width: 100%;
}
}

0 comments on commit 97bff8e

Please sign in to comment.