Skip to content

Commit

Permalink
Added no internet view and update app.py
Browse files Browse the repository at this point in the history
  • Loading branch information
amalthomas-exe committed Jan 29, 2021
1 parent 8814fee commit 27f7dd1
Show file tree
Hide file tree
Showing 8 changed files with 387 additions and 278 deletions.
562 changes: 288 additions & 274 deletions app.py

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion data/misc/dummy.txt
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
dummy file
1 change: 0 additions & 1 deletion data/user/dummy.txt
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
dummy file
1 change: 1 addition & 0 deletions static/images/no_conn_img.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
71 changes: 71 additions & 0 deletions static/styles/not-connected.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
:root{
font-family: 'Roboto', sans-serif;
}
#main{
display: flex;
flex-direction: column;
text-align: center;
align-items: center;
font-size: 22px;
}
#img{
display: flex;
flex-direction: column;
text-align: center;
}
#footer{
display: flex;
flex-direction: column;
text-align: center;
}
#view{
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 100%;
height: 100vh;
}
#git{
font-size: 1.7rem;
color: black;
}
#git:hover{
transform: translateY(-8px);
}
.tooltip {
position: relative;
display: inline-block;
border-bottom: 1px ;
}

.tooltip .tooltiptext {
visibility: hidden;
width: 120px;
top: 100%;
left: 50%;
margin-left: -60px;
background-color: black;
color: #fff;
text-align: center;
padding: 5px 0;
border-radius: 6px;
position: absolute;
z-index: 1;
opacity: 0;
transition: opacity 1s;
}
.tooltip .tooltiptext::after {
content: " ";
position: absolute;
bottom: 100%;
left: 50%;
margin-left: -5px;
border-width: 5px;
border-style: solid;
border-color: transparent transparent black transparent;
}
.tooltip:hover .tooltiptext {
visibility: visible;
opacity: 0.7;
}
1 change: 0 additions & 1 deletion templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
</section>
<script src='https://use.fontawesome.com/releases/v5.0.13/js/all.js'></script>
<script src ="{{ url_for('static', filename='scripts/script.js') }}"></script>

</body>

</html>
2 changes: 1 addition & 1 deletion templates/new-user.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</head>
<body>
<div id="container">
<p id="title">Hey, we see that you are a new user. Please provide us a few details before we proceed. 😊</p>
<p id="title">Hey, we see that you are a new user. Please provide us a few details before we proceed.😊</p>
<div id="form-box">
<form id="user-data" action="/success" method="post">
<label class = "label" id="label-name-first" for="first-name">First Name</label><br>
Expand Down
26 changes: 26 additions & 0 deletions templates/not-connected.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="{{ url_for('static', filename='styles/not-connected.css') }}">
<link href="https://fonts.googleapis.com/css2?family=Roboto&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.8.1/css/all.css" integrity="sha384-50oBUHEmvpQ+1lW4y57PTFmhCaXp0ML5d60M1M7uH2+nqUivzIebhndOJK28anvf" crossorigin="anonymous">
<title>Not Connected</title>
</head>
<body>
<section id="view">
<div id="main">
<p id="message">Oops! Looks like you are not connected.</p>
<p id="mess2">Please connect to the internet and restart the app</p>
</div>
<div id="img">
<img
src="{{url_for('static', filename='images/no_conn_img.svg')}}"
alt="No connected image"
height="400"
width="400" />
</div>
</section>
</body>
</html>

0 comments on commit 27f7dd1

Please sign in to comment.