Slightly prettier UI
This commit is contained in:
parent
7832f6e6b8
commit
9a14492e47
6
main.py
6
main.py
@ -671,6 +671,12 @@ def serve_maskable_icon():
|
||||
return send_from_directory("static", 'icon512_maskable.png',
|
||||
mimetype='image/png')
|
||||
|
||||
@app.route('/screenshot1.png')
|
||||
def serve_screenshot_1():
|
||||
return send_from_directory("static", 'screenshot1.png',
|
||||
mimetype='image/png')
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
# Start Qt process
|
||||
qt_proc = multiprocessing.Process(target=qt_process)
|
||||
|
||||
@ -2,6 +2,14 @@
|
||||
"theme_color":"#222222",
|
||||
"background_color":"#222222",
|
||||
"start_url": "/",
|
||||
"screenshots":
|
||||
[
|
||||
{
|
||||
"src": "screenshot1.png",
|
||||
"type": "image/png",
|
||||
"sizes": "1080x2017"
|
||||
}
|
||||
],
|
||||
"icons":
|
||||
[
|
||||
{
|
||||
|
||||
BIN
static/screenshot1.png
Normal file
BIN
static/screenshot1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 89 KiB |
@ -1,5 +1,6 @@
|
||||
<!-- Updated HTML/CSS for the index() function in Flask -->
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>IPMPV</title>
|
||||
<link rel="manifest" href="/manifest.json">
|
||||
@ -17,6 +18,8 @@
|
||||
--text-color: white;
|
||||
--on-state: #007700;
|
||||
--off-state: #770000;
|
||||
--on-border: #229922;
|
||||
--off-border: #992222;
|
||||
--border-radius: 15px;
|
||||
}
|
||||
|
||||
@ -26,7 +29,7 @@
|
||||
|
||||
body {
|
||||
background-color: var(--primary-bg);
|
||||
font-family: Fira Sans Regular, Arial, sans-serif;
|
||||
font-family: "Fira Sans", Arial, sans-serif;
|
||||
color: var(--text-color);
|
||||
text-align: center;
|
||||
padding: 10px;
|
||||
@ -89,13 +92,14 @@
|
||||
}
|
||||
|
||||
button {
|
||||
font-family: "Fira Sans", Arial, sans-serif;
|
||||
padding: 12px;
|
||||
min-width: 120px;
|
||||
min-width: 200px;
|
||||
margin: 5px;
|
||||
font-size: 16px;
|
||||
border: 1px solid #353535;
|
||||
color: var(--text-color);
|
||||
border: none;
|
||||
transition: background-color 0.2s, transform 0.1s;
|
||||
transition: background-color 0.2s, transform 0.1s, border-color 0.2s;
|
||||
background-color: var(--secondary-bg);
|
||||
border-radius: var(--border-radius);
|
||||
cursor: pointer;
|
||||
@ -121,12 +125,13 @@
|
||||
}
|
||||
|
||||
input {
|
||||
font-family: "Fira Sans", Arial, sans-serif;
|
||||
padding: 12px;
|
||||
flex-grow: 1;
|
||||
margin: 5px 0;
|
||||
font-size: 16px;
|
||||
color: var(--text-color);
|
||||
border: none;
|
||||
border: 1px solid #444444;
|
||||
background-color: var(--input-bg);
|
||||
border-radius: var(--border-radius);
|
||||
min-width: 200px;
|
||||
@ -135,19 +140,21 @@
|
||||
.osd-toggle {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin: 10px 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
#osd-on-btn {
|
||||
border-radius: var(--border-radius) 0 0 var(--border-radius);
|
||||
min-width: 80px;
|
||||
margin-right: 0;
|
||||
border-right: 0;
|
||||
}
|
||||
|
||||
#osd-off-btn {
|
||||
border-radius: 0 var(--border-radius) var(--border-radius) 0;
|
||||
min-width: 80px;
|
||||
margin-left: 0;
|
||||
border-left: 0;
|
||||
}
|
||||
|
||||
#latency-btn {
|
||||
@ -156,17 +163,21 @@
|
||||
margin: 5px 0;
|
||||
border-radius: 0;
|
||||
flex: 0 0 auto;
|
||||
border-right: 0;
|
||||
border-left: 0;
|
||||
}
|
||||
|
||||
.custom-url-input {
|
||||
border-radius: var(--border-radius) 0 0 var(--border-radius);
|
||||
margin-right: 0;
|
||||
border-right: 0;
|
||||
}
|
||||
|
||||
.input-btn {
|
||||
border-radius: 0 var(--border-radius) var(--border-radius) 0;
|
||||
display: block;
|
||||
margin: 5px 0;
|
||||
border-left: 0;
|
||||
}
|
||||
|
||||
button:hover {
|
||||
@ -180,10 +191,12 @@
|
||||
|
||||
button.OFF {
|
||||
background-color: var(--off-state);
|
||||
border: 1px solid var(--off-border);
|
||||
}
|
||||
|
||||
button.ON {
|
||||
background-color: var(--on-state);
|
||||
border: 1px solid var(--on-border);
|
||||
}
|
||||
|
||||
/* Sections */
|
||||
@ -217,12 +230,8 @@
|
||||
flex-wrap: nowrap;
|
||||
}
|
||||
|
||||
.custom-url-input {
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
.input-btn {
|
||||
min-width: 120px;
|
||||
min-width: 200px;
|
||||
}
|
||||
}
|
||||
|
||||
@ -240,10 +249,26 @@
|
||||
|
||||
/* Mobile touch improvements */
|
||||
@media (max-width: 767px) {
|
||||
button, input {
|
||||
padding: 14px; /* Larger touch targets */
|
||||
|
||||
button,
|
||||
input {
|
||||
padding: 14px;
|
||||
/* Larger touch targets */
|
||||
margin: 8px 4px;
|
||||
width: 90%;
|
||||
}
|
||||
|
||||
input {
|
||||
min-width: unset;
|
||||
width: 90%;
|
||||
}
|
||||
|
||||
.section {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.group-container {
|
||||
@ -255,34 +280,63 @@
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.osd-toggle {
|
||||
width: 85%;
|
||||
margin: 8px 4px;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.control-button {
|
||||
width: 100%;
|
||||
width: 90%;
|
||||
max-width: none;
|
||||
}
|
||||
|
||||
.url-input-group {
|
||||
width: 100%;
|
||||
flex-direction: column;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.custom-url-input {
|
||||
width: 100%;
|
||||
width: 90%;
|
||||
min-width: 200px;
|
||||
border-right: 1px solid #444444;
|
||||
border-radius: var(--border-radius);
|
||||
}
|
||||
|
||||
#latency-btn {
|
||||
width: 100%;
|
||||
width: 90%;
|
||||
border-radius: var(--border-radius);
|
||||
margin-top: 8px;
|
||||
}
|
||||
|
||||
.input-btn {
|
||||
width: 100%;
|
||||
width: 90%;
|
||||
border-radius: var(--border-radius);
|
||||
border-left: 1px solid #353535;
|
||||
margin-top: 8px;
|
||||
}
|
||||
|
||||
#osd-on-btn {
|
||||
margin-top: 8px;
|
||||
margin-bottom: 8px;
|
||||
margin-left: 4px;
|
||||
min-width: 100px;
|
||||
}
|
||||
|
||||
#osd-off-btn {
|
||||
margin-top: 8px;
|
||||
margin-bottom: 8px;
|
||||
margin-right: 4px;
|
||||
min-width: 100px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1>Welcome to IPMPV</h1>
|
||||
@ -471,4 +525,5 @@
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Loading…
Reference in New Issue
Block a user