Skip to content

Commit 07527ca

Browse files
authored
Merge pull request #18 from ArielMAJ/feat/pre-commit
v0.3.1
2 parents 5748d90 + bb99cab commit 07527ca

7 files changed

Lines changed: 105 additions & 121 deletions

File tree

api/poetry.lock

Lines changed: 1 addition & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "api"
3-
version = "0.3.0"
3+
version = "0.3.1"
44
description = ""
55
authors = ["ArielMAJ <ariel.maj@hotmail.com>"]
66
readme = "README.md"

api/src/main.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import asyncio
2-
from random import random
32
import re
3+
from random import random
44

55
import requests
66
import uvicorn
@@ -26,12 +26,17 @@ async def data(username: str, information: str):
2626
gh_repositories = get_paginated_data(username)
2727
return calc_repo_info_for_plotly(gh_repositories, information)
2828

29+
2930
def calc_repo_info_for_plotly(gh_repositories, information: str):
3031
return [
3132
{
3233
"values": [
3334
count := len(
34-
list(filter(lambda repo: repo.get(information, False), gh_repositories))
35+
list(
36+
filter(
37+
lambda repo: repo.get(information, False), gh_repositories
38+
)
39+
)
3540
),
3641
len(gh_repositories) - count,
3742
],
@@ -41,6 +46,7 @@ def calc_repo_info_for_plotly(gh_repositories, information: str):
4146
}
4247
]
4348

49+
4450
def get_paginated_data(username: str):
4551
def parse_data(data):
4652
if data is None:

vue-front/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "docs",
3-
"version": "0.3.0",
3+
"version": "0.3.1",
44
"private": true,
55
"scripts": {
66
"serve": "vue-cli-service serve",
Lines changed: 45 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,83 @@
11
<template>
2-
<div class="lds-ellipsis">
3-
<div></div>
4-
<div></div>
5-
<div></div>
6-
<div></div>
7-
</div>
2+
<div class="lds-ellipsis">
3+
<div></div>
4+
<div></div>
5+
<div></div>
6+
<div></div>
7+
</div>
88
</template>
99

1010
<script>
11-
1211
export default {
13-
name: "loading-dots",
12+
name: "loading-dots",
1413
};
1514
</script>
1615

1716
<style scoped>
1817
.lds-ellipsis {
19-
display: inline-block;
20-
position: relative;
21-
width: 80px;
22-
height: 80px;
18+
display: inline-block;
19+
position: relative;
20+
width: 80px;
21+
height: 80px;
2322
}
2423
2524
.lds-ellipsis div {
26-
position: absolute;
27-
top: 33px;
28-
width: 13px;
29-
height: 13px;
30-
border-radius: 50%;
31-
background: #fff;
32-
animation-timing-function: cubic-bezier(0, 1, 1, 0);
25+
position: absolute;
26+
top: 33px;
27+
width: 13px;
28+
height: 13px;
29+
border-radius: 50%;
30+
background: #fff;
31+
animation-timing-function: cubic-bezier(0, 1, 1, 0);
3332
}
3433
3534
.lds-ellipsis div:nth-child(1) {
36-
left: 8px;
37-
animation: lds-ellipsis1 0.6s infinite;
35+
left: 8px;
36+
animation: lds-ellipsis1 0.6s infinite;
3837
}
3938
4039
.lds-ellipsis div:nth-child(2) {
41-
left: 8px;
42-
animation: lds-ellipsis2 0.6s infinite;
40+
left: 8px;
41+
animation: lds-ellipsis2 0.6s infinite;
4342
}
4443
4544
.lds-ellipsis div:nth-child(3) {
46-
left: 32px;
47-
animation: lds-ellipsis2 0.6s infinite;
45+
left: 32px;
46+
animation: lds-ellipsis2 0.6s infinite;
4847
}
4948
5049
.lds-ellipsis div:nth-child(4) {
51-
left: 56px;
52-
animation: lds-ellipsis3 0.6s infinite;
50+
left: 56px;
51+
animation: lds-ellipsis3 0.6s infinite;
5352
}
5453
5554
@keyframes lds-ellipsis1 {
56-
0% {
57-
transform: scale(0);
58-
}
55+
0% {
56+
transform: scale(0);
57+
}
5958
60-
100% {
61-
transform: scale(1);
62-
}
59+
100% {
60+
transform: scale(1);
61+
}
6362
}
6463
6564
@keyframes lds-ellipsis3 {
66-
0% {
67-
transform: scale(1);
68-
}
65+
0% {
66+
transform: scale(1);
67+
}
6968
70-
100% {
71-
transform: scale(0);
72-
}
69+
100% {
70+
transform: scale(0);
71+
}
7372
}
7473
7574
@keyframes lds-ellipsis2 {
76-
0% {
77-
transform: translate(0, 0);
78-
}
75+
0% {
76+
transform: translate(0, 0);
77+
}
7978
80-
100% {
81-
transform: translate(24px, 0);
82-
}
79+
100% {
80+
transform: translate(24px, 0);
81+
}
8382
}
84-
</style>
83+
</style>
Lines changed: 46 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,79 +1,78 @@
11
<template>
2-
<div class="lds-heart">
3-
<div></div>
4-
</div>
2+
<div class="lds-heart">
3+
<div></div>
4+
</div>
55
</template>
66

77
<script>
8-
98
export default {
10-
name: "loading-heart",
9+
name: "loading-heart",
1110
};
1211
</script>
1312

1413
<style scoped>
1514
.lds-heart {
16-
display: inline-block;
17-
position: relative;
18-
width: 80px;
19-
height: 80px;
20-
transform: rotate(45deg);
21-
transform-origin: 40px 40px;
15+
display: inline-block;
16+
position: relative;
17+
width: 80px;
18+
height: 80px;
19+
transform: rotate(45deg);
20+
transform-origin: 40px 40px;
2221
}
2322
2423
.lds-heart div {
25-
top: 32px;
26-
left: 32px;
27-
position: absolute;
28-
width: 32px;
29-
height: 32px;
30-
background: #dfc;
31-
animation: lds-heart 1.2s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
24+
top: 32px;
25+
left: 32px;
26+
position: absolute;
27+
width: 32px;
28+
height: 32px;
29+
background: #dfc;
30+
animation: lds-heart 1.2s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
3231
}
3332
3433
.lds-heart div:after,
3534
.lds-heart div:before {
36-
content: " ";
37-
position: absolute;
38-
display: block;
39-
width: 32px;
40-
height: 32px;
41-
background: #dfc;
35+
content: " ";
36+
position: absolute;
37+
display: block;
38+
width: 32px;
39+
height: 32px;
40+
background: #dfc;
4241
}
4342
4443
.lds-heart div:before {
45-
left: -24px;
46-
border-radius: 50% 0 0 50%;
44+
left: -24px;
45+
border-radius: 50% 0 0 50%;
4746
}
4847
4948
.lds-heart div:after {
50-
top: -24px;
51-
border-radius: 50% 50% 0 0;
49+
top: -24px;
50+
border-radius: 50% 50% 0 0;
5251
}
5352
5453
@keyframes lds-heart {
55-
0% {
56-
transform: scale(0.95);
57-
}
54+
0% {
55+
transform: scale(0.95);
56+
}
5857
59-
5% {
60-
transform: scale(1.1);
61-
}
58+
5% {
59+
transform: scale(1.1);
60+
}
6261
63-
39% {
64-
transform: scale(0.85);
65-
}
62+
39% {
63+
transform: scale(0.85);
64+
}
6665
67-
45% {
68-
transform: scale(1);
69-
}
66+
45% {
67+
transform: scale(1);
68+
}
7069
71-
60% {
72-
transform: scale(0.95);
73-
}
70+
60% {
71+
transform: scale(0.95);
72+
}
7473
75-
100% {
76-
transform: scale(0.9);
77-
}
74+
100% {
75+
transform: scale(0.9);
76+
}
7877
}
79-
</style>
78+
</style>

vue-front/src/components/PlotlyChart.vue

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export default {
4646
return {};
4747
},
4848
mounted() {
49-
console.log(this.divId, this.chartData)
49+
console.log(this.divId, this.chartData);
5050
this.newPlot();
5151
this.bindEvents();
5252
},
@@ -77,20 +77,10 @@ export default {
7777
},
7878
7979
newPlot() {
80-
Plotly.newPlot(
81-
this.divId,
82-
this.chartData,
83-
this.layout,
84-
this.config
85-
);
80+
Plotly.newPlot(this.divId, this.chartData, this.layout, this.config);
8681
},
8782
update() {
88-
Plotly.react(
89-
this.divId,
90-
this.chartData,
91-
this.layout,
92-
this.config
93-
);
83+
Plotly.react(this.divId, this.chartData, this.layout, this.config);
9484
},
9585
},
9686
};

0 commit comments

Comments
 (0)