Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 59 additions & 0 deletions TranSafe/src/app/statistic/statistics.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale = 1.0">
<title>Transafe</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<header><h1>Speed Rate</h1></header>
<div class="container">
<div class="card">
<div class="box">
<div class="percent">
<svg>
<circle cx="70" cy="70" r="70"></circle>
<circle cx="70" cy="70" r="70"></circle>
</svg>
<div class="number">
<h2>90<span>%</span></h2>
</div>
</div>
<h2 class="text">Daily</h2>
</div>
</div>

<div class="card">
<div class="box">
<div class="percent">
<svg>
<circle cx="70" cy="70" r="70"></circle>
<circle cx="70" cy="70" r="70"></circle>
</svg>
<div class="number">
<h2>85<span>%</span></h2>
</div>
</div>
<h2 class="text">Weekly</h2>
</div>
</div>

<div class="card">
<div class="box">
<div class="percent">
<svg>
<circle cx="70" cy="70" r="70"></circle>
<circle cx="70" cy="70" r="70"></circle>
</svg>
<div class="number">
<h2>60<span>%</span></h2>
</div>
</div>
<h2 class="text">Monthly</h2>
</div>
</div>
</div>

</body>
</html>
176 changes: 176 additions & 0 deletions TranSafe/src/app/statistic/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,176 @@
*
{
margin: 0;
padding: 0;
font-family: 'Roboto', sans-serif;
}

body
{
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
background: #101010;
}

header
{
position: fixed;
padding: 10px 0;
top: 0;
padding-left: 267px;
color: white;
}

.container
{
position: relative;
width: 900px;
display: flex;
justify-content: space-around;
margin-top: 80px;
}

.container .card
{
position: relative;
width: 250px;
background: linear-gradient(0deg,#1b1b1b,#222,#1b1b1b);
display: flex;
justify-content: center;
align-items: center;
height: 300px;
border-radius: 4px;
text-align: center;
overflow: hidden;
transition: 0.5s;
}

.container .card:hover
{
transform: translateY(-10px);
box-shadow: 0 15px 35px rgba(0,0,0,.5);
}

.container .card:before
{
content: '';
position: absolute;
top: 0;
left: -50%;
width: 100%;
height: 100%;
background: rgba(255,255,255,.03);
pointer-events: none;
z-index: 1;
}

.percent
{
position: relative;
width: 150px;
height: 150px;
border-radius: 50%;
box-shadow: inset 0 0 50px #000;
background: #222;
z-index: 1000;
}

.percent .number
{
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
border-radius: 50%;
}

.percent .number h2
{
color: #777;
font-weight: 700;
font-size: 40px;
transition: 0.5s;
}

.card:hover .percent .number h2
{
color: #fff;
font-size: 60px;
}

.percent .number h2 span
{
font-size: 24px;
color: #777;
transition: 0.5s;
}

.card:hover .percent .number h2 span
{
color: #fff;
}

.text
{
position: relative;
color: #777;
margin-top: 20px;
font-weight: 700;
font-size: 18px;
letter-spacing: 1px;
text-transform: uppercase;
transform: 0.5s;
}
.card:hover .text
{
color: #fff;
}

svg
{
position: relative;
width: 150px;
height: 150px;
z-index: 1000;
}

svg circle
{
width: 100%;
height: 100;
fill: none;
stroke: #191919;
stroke-width:10;
stroke-linecap: round;
transform: translate(5px, 5px);
}

svg circle:nth-child(2)
{
stroke-dasharray: 220;
stroke-dashoffset: 220;
}

.card:nth-child(1) svg circle:nth-child(2)
{
stroke-dashoffset: calc(220 - (220 * 90) / 100);
stroke:#00ff43;
}

.card:nth-child(2) svg circle:nth-child(2)
{
/*stroke-dashoffset: calc(440 - (440 * 85) / 100);*/
stroke:#00a1ff;
}

.card:nth-child(3) svg circle:nth-child(2)
{
/*stroke-dashoffset: calc(440 - (440 * 60) / 100);*/
stroke:#ff04f7;
}