mirror of
https://github.com/skoelle/mvg-departures.git
synced 2026-09-17 18:40:23 +00:00
new template
This commit is contained in:
+133
-92
@@ -5,100 +5,9 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Abfahrten</title>
|
||||
<meta http-equiv="refresh" content="{{ refresh_seconds }}">
|
||||
<style>
|
||||
* { box-sizing: border-box; }
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 8px;
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
||||
background: #111417;
|
||||
color: #eaeaea;
|
||||
font-size: 20px;
|
||||
}
|
||||
h1 {
|
||||
font-size: 24px;
|
||||
margin: 4px 0 10px 4px;
|
||||
color: #9aa5b1;
|
||||
font-weight: 500;
|
||||
}
|
||||
.updated {
|
||||
font-size: 14px;
|
||||
color: #6b7280;
|
||||
margin-left: 4px;
|
||||
}
|
||||
table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
tr {
|
||||
border-bottom: 1px solid #23272d;
|
||||
}
|
||||
td {
|
||||
padding: 12px 6px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.icon {
|
||||
display: inline-block;
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
text-align: center;
|
||||
border-radius: 6px;
|
||||
font-weight: 700;
|
||||
font-size: 16px;
|
||||
color: #111417;
|
||||
}
|
||||
.icon-U { background: #005ca9; color: #fff; }
|
||||
.icon-S { background: #00933b; color: #fff; }
|
||||
.icon-T { background: #e2001a; color: #fff; }
|
||||
.icon-B { background: #55545a; color: #fff; }
|
||||
.line {
|
||||
font-weight: 700;
|
||||
font-size: 18px;
|
||||
display: block;
|
||||
}
|
||||
.station {
|
||||
font-size: 14px;
|
||||
color: #6b7280;
|
||||
}
|
||||
.destination {
|
||||
font-size: 18px;
|
||||
}
|
||||
.time {
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
font-weight: 700;
|
||||
font-size: 20px;
|
||||
}
|
||||
.delay {
|
||||
font-size: 12px;
|
||||
font-weight: 700;
|
||||
color: #f59e0b;
|
||||
display: block;
|
||||
text-align: right;
|
||||
}
|
||||
.delay.high { color: #ef4444; }
|
||||
.cancelled {
|
||||
color: #ef4444;
|
||||
font-weight: 700;
|
||||
font-size: 12px;
|
||||
display: block;
|
||||
text-align: right;
|
||||
}
|
||||
.messages {
|
||||
font-size: 11px;
|
||||
color: #f59e0b;
|
||||
padding: 0 4px 8px 42px;
|
||||
border-bottom: 1px solid #23272d;
|
||||
}
|
||||
.empty {
|
||||
color: #6b7280;
|
||||
padding: 20px 4px;
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div style="max-width: 375px; margin: 0 auto; width: 100%;">
|
||||
<h1>Abfahrten <span class="updated">Stand: {{ generated_at }}</span></h1>
|
||||
{% if departures %}
|
||||
<table>
|
||||
@@ -131,5 +40,137 @@
|
||||
{% else %}
|
||||
<div class="empty">Keine Abfahrten verfügbar.</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<style>
|
||||
* { box-sizing: border-box; }
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 8px;
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
||||
background: #111417;
|
||||
color: #eaeaea;
|
||||
font-size: 20px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
min-height: 100vh;
|
||||
}
|
||||
h1 {
|
||||
font-size: 24px;
|
||||
margin: 4px 0 10px 4px;
|
||||
color: #9aa5b1;
|
||||
font-weight: 500;
|
||||
}
|
||||
.updated {
|
||||
font-size: 14px;
|
||||
color: #6b7280;
|
||||
margin-left: 4px;
|
||||
}
|
||||
table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
tr {
|
||||
border-bottom: 1px solid #23272d;
|
||||
}
|
||||
td {
|
||||
padding: 12px 6px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.icon {
|
||||
display: inline-block;
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
text-align: center;
|
||||
border-radius: 6px;
|
||||
font-weight: 700;
|
||||
font-size: 16px;
|
||||
color: #111417;
|
||||
}
|
||||
.icon-U { background: #005ca9; color: #fff; }
|
||||
.icon-S { background: #00933b; color: #fff; }
|
||||
.icon-T { background: #e2001a; color: #fff; }
|
||||
.icon-B { background: #55545a; color: #fff; }
|
||||
.line {
|
||||
font-weight: 700;
|
||||
font-size: 18px;
|
||||
display: block;
|
||||
}
|
||||
.station {
|
||||
font-size: 14px;
|
||||
color: #6b7280;
|
||||
}
|
||||
.destination {
|
||||
font-size: 18px;
|
||||
}
|
||||
.time {
|
||||
text-align: right;
|
||||
white-space: nowrap;
|
||||
font-weight: 700;
|
||||
font-size: 20px;
|
||||
}
|
||||
.delay {
|
||||
font-size: 12px;
|
||||
font-weight: 700;
|
||||
color: #f59e0b;
|
||||
display: block;
|
||||
text-align: right;
|
||||
}
|
||||
.delay.high { color: #ef4444; }
|
||||
.cancelled {
|
||||
color: #ef4444;
|
||||
font-weight: 700;
|
||||
font-size: 12px;
|
||||
display: block;
|
||||
text-align: right;
|
||||
}
|
||||
.messages {
|
||||
font-size: 11px;
|
||||
color: #f59e0b;
|
||||
padding: 0 4px 8px 42px;
|
||||
border-bottom: 1px solid #23272d;
|
||||
}
|
||||
.empty {
|
||||
color: #6b7280;
|
||||
padding: 20px 4px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* Mobile styles - full width */
|
||||
@media (max-width: 375px) {
|
||||
body {
|
||||
padding: 4px;
|
||||
}
|
||||
h1 {
|
||||
font-size: 20px;
|
||||
margin: 4px 0 8px 4px;
|
||||
}
|
||||
.updated {
|
||||
font-size: 12px;
|
||||
}
|
||||
td {
|
||||
padding: 8px 4px;
|
||||
}
|
||||
.icon {
|
||||
width: 26px;
|
||||
height: 26px;
|
||||
line-height: 26px;
|
||||
font-size: 13px;
|
||||
}
|
||||
.line {
|
||||
font-size: 16px;
|
||||
}
|
||||
.station {
|
||||
font-size: 12px;
|
||||
}
|
||||
.destination {
|
||||
font-size: 16px;
|
||||
}
|
||||
.time {
|
||||
font-size: 18px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user