diff --git a/src/lib/components/ui/station-board/StaffServicesTable.svelte b/src/lib/components/ui/station-board/StaffServicesTable.svelte index d86edd3..1cb02b4 100644 --- a/src/lib/components/ui/station-board/StaffServicesTable.svelte +++ b/src/lib/components/ui/station-board/StaffServicesTable.svelte @@ -9,6 +9,24 @@ + + + + + + + + + + + + + + + + + + @@ -29,10 +47,19 @@ {#each services as service (getRowKey(service))} - + - - + + @@ -95,9 +122,16 @@ {/if} + {#if service.o} + + + + {/if} {#if service.c && service.cr?.r} -
{service.h}{service.og.t}{service.dt.t}{service.og.t}{service.dt.t} {service.p || '-'}
+ {service.o} +
+ {service.cr.r} {#if service.cr.l} {service.cr.n ? 'near' : 'at'} @@ -126,12 +160,14 @@ width: 100%; margin: 5px auto; border-collapse: collapse; + table-layout: fixed; } .departure-board td { font-family: 'Inconsolata Variable', monospace; font-size: clamp(1rem, 0.475rem + 2.8vw, 1.35rem); font-variant-ligatures: additional-ligatures; + overflow: hidden; } thead, @@ -147,11 +183,15 @@ background: var(--color-bg-dark); } - abbr { - text-decoration: none; - border-bottom: none; - cursor:help; -} + abbr { + text-decoration: none; + border-bottom: none; + cursor: help; + } + + tbody tr:first-child td { + border-top: 5px solid transparent; + } /* Row Logic */ .serviceCancelled { @@ -163,22 +203,22 @@ font-weight: 200; } - .serviceNonPassenger td { - opacity: 0.5; - font-weight: 200; - font-style: italic; - } + .serviceNonPassenger td { + opacity: 0.5; + font-weight: 290; + font-style: italic; + } /* Special Row Styles */ .cancel-row td, .delay-row td { font-size: 0.88rem; - padding-bottom: 8px; + text-align: left; } .cancel-row td[colspan], .delay-row td[colspan] { - padding-left: 0.75ch; + padding-left: 0ch; } .cancel-row td { @@ -190,18 +230,64 @@ color: var(--delay-orange); font-style: italic; } + @media (min-width: 375px) { + .cancel-row td, + .delay-row td { + font-size: 1.08rem; + } + } + @media (min-width: 420px) { + .cancel-row td, + .delay-row td { + font-size: 1.12rem; + } + } + @media (min-width: 550px) { + .cancel-row td, + .delay-row td { + font-size: 1.18rem; + } + } + @media (min-width: 620px) { + .cancel-row td, + .delay-row td { + font-size: 1.20rem; + } + } + + .toc-coach-row td { + font-family: 'URW Gothic', sans-serif; + font-size: 0.7rem; + padding: 0; + color: rgb(187, 187, 255); + } + @media(min-width: 400px) { + .toc-coach-row td { + font-size: 0.8rem; + } + } + @media(min-width: 550px) { + .toc-coach-row td { + font-size: 0.85rem; + } + } /* Column Specifics */ .id-cell { - text-align: center; + text-align: left; font-weight: 400; - font-stretch: 80%; + font-stretch: 85%; filter: brightness(0.75); } + @media (min-width: 400px) { + .id-cell { + font-stretch: 90%; + } + } .orig-cell, .dest-cell { - font-stretch: 90%; - font-weight: 400; + font-stretch: 80%; + font-weight: 400; } .orig-cell { text-align: left; @@ -211,10 +297,53 @@ text-align: right; color: var(--location-yellow); } + @media (min-width: 350px) { + .orig-cell, + .dest-cell { + font-stretch: 85%; + } + @media (min-width: 400px) { + .orig-cell, + .dest-cell { + font-stretch: 90%; + } + } + @media (min-width: 490px) { + .orig-cell, + .dest-cell { + font-stretch: 95%; + } + } + @media (min-width: 520px) { + .orig-cell, + .dest-cell { + font-stretch: 100%; + } + .orig-cell { + text-align: right; + padding-right: 7px; + } + .dest-cell { + text-align: left; + padding-left: 7px; + } + } + @media (min-width: 600px) { + .orig-cell, + .dest-cell { + letter-spacing: 0.05ch; + } + } + } .plt-cell { text-align: center; - font-weight: 405; - font-stretch: 70%; + font-weight: 410; + font-stretch: 100%; + } + @media (min-width: 525px) { + .plt-cell { + font-stretch: 110%; + } } .plt-cell.platSup { font-weight: 200; @@ -228,6 +357,7 @@ } .pass-cell { text-align: center; + font-stretch: 100%; } /* Colour orig and dest values when cancelled */ .service-row.serviceCancelled .orig-cell, @@ -237,7 +367,27 @@ .time-cell { text-align: center; - font-stretch: 70%; + font-stretch: 72%; + } + @media (min-width: 350px) { + .time-cell { + font-stretch: 77%; + } + } + @media (min-width: 400px) { + .time-cell { + font-stretch: 82%; + } + } + @media (min-width: 525px) { + .time-cell { + font-stretch: 90%; + } + } + @media (min-width: 600px) { + .time-cell { + font-stretch: 100%; + } } /* RT Logic */ diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index 7c7fcdf..20094aa 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -147,7 +147,7 @@

Narrow Gauge Detected

Just as trains need the right track width, our data needs a bit more room to stay on the rails. - Please expand your view to at least 300px to view the app. + Please expand your view to at least 320px to view the app.

@@ -319,7 +319,7 @@ display: none; } - @media (max-width: 299px) { + @media (max-width: 319px) { .viewport-guard { display: block; position: fixed;