diff --git a/apps/mobile/eslint.config.js b/apps/mobile/eslint.config.js
index ba04dc4..2fb472a 100644
--- a/apps/mobile/eslint.config.js
+++ b/apps/mobile/eslint.config.js
@@ -1,6 +1,10 @@
import js from "@eslint/js";
import ts from "typescript-eslint";
import reactPlugin from "eslint-plugin-react";
+import { fileURLToPath } from "url";
+import path from "path";
+
+const __dirname = path.dirname(fileURLToPath(import.meta.url));
// We have no .eslintrc, so we must define everything here.
@@ -40,6 +44,7 @@ export default ts.config(
ecmaFeatures: {
jsx: true,
},
+ tsconfigRootDir: path.resolve(__dirname),
},
},
plugins: {
diff --git a/apps/web/eslint.config.mjs b/apps/web/eslint.config.mjs
index 72a7928..f45afb3 100644
--- a/apps/web/eslint.config.mjs
+++ b/apps/web/eslint.config.mjs
@@ -1,6 +1,10 @@
import { defineConfig, globalIgnores } from "eslint/config";
import nextVitals from "eslint-config-next/core-web-vitals";
import nextTs from "eslint-config-next/typescript";
+import { fileURLToPath } from "url";
+import path from "path";
+
+const __dirname = path.dirname(fileURLToPath(import.meta.url));
const eslintConfig = defineConfig([
...nextVitals,
@@ -14,6 +18,11 @@ const eslintConfig = defineConfig([
"next-env.d.ts",
]),
{
+ languageOptions: {
+ parserOptions: {
+ tsconfigRootDir: path.resolve(__dirname),
+ },
+ },
rules: {
// Allow _-prefixed parameters and variables to signal intentionally unused.
"@typescript-eslint/no-unused-vars": [
diff --git a/apps/web/src/app/calendar/page.tsx b/apps/web/src/app/calendar/page.tsx
index b13ad7a..d1416f9 100644
--- a/apps/web/src/app/calendar/page.tsx
+++ b/apps/web/src/app/calendar/page.tsx
@@ -15,9 +15,9 @@ export default function CalendarPage() {
return (
-
Calendar sync
+
Calendar sync
Import, inspect, and time your day.
-
View and manage every appointment from a single departure-focused calendar.
+
View and manage every appointment from a single departure-focused calendar.
diff --git a/apps/web/src/app/event/BikeSection.tsx b/apps/web/src/app/event/BikeSection.tsx
index 321fe01..051c0c3 100644
--- a/apps/web/src/app/event/BikeSection.tsx
+++ b/apps/web/src/app/event/BikeSection.tsx
@@ -32,7 +32,7 @@ const BikeSection: React.FC
= ({
Bicycle Route
-
Door-to-door route to the event
+
Door-to-door route to the event
{onRefresh && (
) : bikeError ? (
- Error: {bikeError}
+ Error: {bikeError}
) : bikeRoute ? (
- Distance
+ Distance
{Math.round(bikeRoute.distance / 1000)} km ({Math.round(bikeRoute.distance)} m)
- Duration
+ Duration
{Math.floor(bikeRoute.duration / 60)} min {bikeRoute.duration % 60} s
{bikeRoute.steps && bikeRoute.steps.length > 0 && (
-
Steps
+
Steps
{bikeRoute.steps.map((step, index) => (
-
- {step.name}
- {step.instruction}
+ {step.name}
+ {step.instruction}
))}
@@ -77,7 +77,7 @@ const BikeSection: React.FC
= ({
)}
) : (
-
+
Add origin and destination coordinates to calculate a bike route.
)}
diff --git a/apps/web/src/app/event/EventCard.tsx b/apps/web/src/app/event/EventCard.tsx
index f16e2f9..605037e 100644
--- a/apps/web/src/app/event/EventCard.tsx
+++ b/apps/web/src/app/event/EventCard.tsx
@@ -86,7 +86,7 @@ export default function EventCard({ event, originStation }: EventCardProps) {
-
Next stop
+
Next stop
{event.title}
@@ -94,12 +94,12 @@ export default function EventCard({ event, originStation }: EventCardProps) {
-
Destination
-
{event.destination}
+
Destination
+
{event.destination}
-
Appointment
-
{format(event.eventTime, "EEE dd MMM yyyy HH:mm")}
+
Appointment
+
{format(event.eventTime, "EEE dd MMM yyyy HH:mm")}
@@ -109,8 +109,8 @@ export default function EventCard({ event, originStation }: EventCardProps) {
key={option.id}
className={`rounded-xl border p-3 text-left transition-all ${
activeMode === option.id
- ? "border-[#D946EF]/70 bg-[#B23CFF]/18 shadow-[0_14px_34px_rgba(178,60,255,0.2)]"
- : "border-white/10 bg-white/[0.045] hover:border-[#D946EF]/40 hover:bg-white/[0.07]"
+ ? "border-brand-fuchsia/70 bg-brand-purple/18 shadow-[0_14px_34px_rgba(178,60,255,0.2)]"
+ : "border-white/10 bg-white/[0.045] hover:border-brand-fuchsia/40 hover:bg-white/[0.07]"
} ${option.disabled ? "cursor-not-allowed opacity-45 hover:border-white/10 hover:bg-white/[0.045]" : ""}`}
onClick={() => {
if (!option.disabled) {
@@ -122,31 +122,31 @@ export default function EventCard({ event, originStation }: EventCardProps) {
{option.label}
{activeMode === option.id && (
-
+
Active
)}
- {option.meta}
+ {option.meta}
))}
-
Leave by
+
Leave by
{departureTime ? format(departureTime, "HH:mm") : "Pending"}
-
Arrive by
+
Arrive by
{arrivalTime ? format(arrivalTime, "HH:mm") : format(new Date(event.eventTime.getTime() - arrivalBufferMinutes * 60_000), "HH:mm")}
-
Buffer
+
Buffer
{arrivalBufferMinutes} min {calculatedMode ? `via ${calculatedMode}` : ""}
diff --git a/apps/web/src/app/event/JourneyList.tsx b/apps/web/src/app/event/JourneyList.tsx
index 63f0967..8d004c8 100644
--- a/apps/web/src/app/event/JourneyList.tsx
+++ b/apps/web/src/app/event/JourneyList.tsx
@@ -22,7 +22,7 @@ const JourneyList: React.FC
= ({
const targetArrivalTime = new Date(eventTime.getTime() - arrivalBufferMinutes * 60000);
if (journeys.length === 0) {
- return No journeys found
;
+ return No journeys found
;
}
return (
@@ -37,20 +37,20 @@ const JourneyList: React.FC = ({
key={journey.id}
className={`rounded-xl border p-3 ${
arrivesTooLate || journey.cancelled
- ? "border-[#FF2D8D]/18 bg-[#FF2D8D]/7 opacity-40 line-through"
+ ? "border-brand-pink/18 bg-brand-pink/7 opacity-40 line-through"
: "border-white/10 bg-white/[0.04]"
}`}
>
{formatTime(departure)}
- {journey.platform}
+ {journey.platform}
{journey.delay > 0 && (
{`+${journey.delay}'`}
)}
-
+
{journey.cancelled ? "Cancelled" : journey.trains.join(" -> ")}
@@ -58,11 +58,11 @@ const JourneyList: React.FC
= ({
-
+
{journey.changes > 0 ? `Change(s): ${journey.changes}` : "Direct"}
Arrives {formatTime(arrival)}
{arrivesTooLate && (
-
+
misses {arrivalBufferMinutes} min buffer
)}
diff --git a/apps/web/src/app/event/TrainSection.tsx b/apps/web/src/app/event/TrainSection.tsx
index 64180c2..08f261a 100644
--- a/apps/web/src/app/event/TrainSection.tsx
+++ b/apps/web/src/app/event/TrainSection.tsx
@@ -43,11 +43,11 @@ const TrainSection: React.FC = ({
Trains
-
+
To {destName} {formatDateTime(eventTime)}
{(arrivalBufferMinutes ?? 0) > 0 && (
-
+
Target arrival: {arrivalBufferMinutes} min early
)}
@@ -65,7 +65,7 @@ const TrainSection: React.FC
= ({
) : error ? (
-
{error}
+
{error}
) : (
<>
diff --git a/apps/web/src/app/event/WalkingOption.tsx b/apps/web/src/app/event/WalkingOption.tsx
index 94577fb..55db2dc 100644
--- a/apps/web/src/app/event/WalkingOption.tsx
+++ b/apps/web/src/app/event/WalkingOption.tsx
@@ -24,7 +24,7 @@ const WalkingOption: React.FC
= ({ walkRoute, walkLoading, w
Final Walk
-
From arrival station to destination
+
From arrival station to destination
{onRefresh && (
) : walkError ? (
- Error: {walkError}
+ Error: {walkError}
) : walkRoute ? (
- Distance
+ Distance
{Math.round(walkRoute.distance / 1000)} km ({Math.round(walkRoute.distance)} m)
- Duration
+ Duration
{Math.floor(walkRoute.duration / 60)} min {walkRoute.duration % 60} s
{walkRoute.steps && walkRoute.steps.length > 0 && (
-
Steps
+
Steps
{walkRoute.steps.map((step: { name: string; instruction: string }, index: number) => (
-
- {step.name}
- {step.instruction}
+ {step.name}
+ {step.instruction}
))}
diff --git a/apps/web/src/app/layout.tsx b/apps/web/src/app/layout.tsx
index 9005d3a..6f4f80c 100644
--- a/apps/web/src/app/layout.tsx
+++ b/apps/web/src/app/layout.tsx
@@ -31,7 +31,7 @@ export default function RootLayout({
}>) {
return (
-
+
diff --git a/apps/web/src/app/layout/Header.tsx b/apps/web/src/app/layout/Header.tsx
index 43caf7d..bf4cf1e 100644
--- a/apps/web/src/app/layout/Header.tsx
+++ b/apps/web/src/app/layout/Header.tsx
@@ -28,14 +28,14 @@ const Header: React.FC = ({ className = "" }) => {
-
+
{events.length}
@@ -46,8 +46,8 @@ const Header: React.FC
= ({ className = "" }) => {
Online
) : status === false ? (
-
-
+
+
Offline
) : null}
@@ -58,7 +58,7 @@ const Header: React.FC = ({ className = "" }) => {
diff --git a/apps/web/src/app/page.tsx b/apps/web/src/app/page.tsx
index 3ad2a56..ad88c81 100644
--- a/apps/web/src/app/page.tsx
+++ b/apps/web/src/app/page.tsx
@@ -17,7 +17,7 @@ export default function Home() {
-
Departure desk
+
Departure desk
Know when to leave before the clock turns hostile.
@@ -25,22 +25,22 @@ export default function Home() {
{upcoming.length}
-
upcoming
+
upcoming
{events.length}
-
total events
+
total events
{upcoming.length === 0 ? (
-
+
T
No upcoming events
-
+
Add an event or import your calendar to turn this into a live departure board.
diff --git a/apps/web/src/app/ui/LoadingSpinner.tsx b/apps/web/src/app/ui/LoadingSpinner.tsx
index 5d6c4ac..3673bc2 100644
--- a/apps/web/src/app/ui/LoadingSpinner.tsx
+++ b/apps/web/src/app/ui/LoadingSpinner.tsx
@@ -20,7 +20,7 @@ const LoadingSpinner: React.FC
= ({
return (
diff --git a/apps/web/src/app/ui/ReminderSettingsPanel.tsx b/apps/web/src/app/ui/ReminderSettingsPanel.tsx
index 4356b2e..43f7101 100644
--- a/apps/web/src/app/ui/ReminderSettingsPanel.tsx
+++ b/apps/web/src/app/ui/ReminderSettingsPanel.tsx
@@ -30,7 +30,7 @@ export default function ReminderSettingsPanel({ className = "" }: ReminderSettin
{/* Toggle */}
-
+
Leave reminders