From 2001856f55d2e0276efa95c5597f511a6492a45a Mon Sep 17 00:00:00 2001 From: Deep Date: Sat, 19 Oct 2024 08:08:48 +0530 Subject: [PATCH] Changes to make it bmtcbusroutes --- .github/workflows/main.yml | 2 +- src/index.scss | 2 +- src/landing/index.jsx | 2 +- src/landing/sidebar.jsx | 6 +++--- src/route/index.jsx | 10 +++++----- src/search/index.jsx | 2 +- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f2d0a08..ab299ef 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,4 +1,4 @@ -name: Workflow for build and deploy of the BLR public transport webapp frontend to AWS +name: Workflow for build and deploy of the BMTC bus routes webapp frontend to AWS on: push: branches: diff --git a/src/index.scss b/src/index.scss index 416605a..19e7806 100644 --- a/src/index.scss +++ b/src/index.scss @@ -225,7 +225,7 @@ body { #landing-header { display: flex; - flex-direction: row-reverse; + flex-direction: row; justify-content: space-between; align-items: center; margin-bottom: 32px; diff --git a/src/landing/index.jsx b/src/landing/index.jsx index d8388a1..4f76af8 100644 --- a/src/landing/index.jsx +++ b/src/landing/index.jsx @@ -47,7 +47,7 @@ class LandingPage extends React.PureComponent { - Where to? + Search for a bus route or bus stop { _.size(historyItems) > 0 && ( diff --git a/src/landing/sidebar.jsx b/src/landing/sidebar.jsx index 608ff7c..633381c 100644 --- a/src/landing/sidebar.jsx +++ b/src/landing/sidebar.jsx @@ -56,10 +56,10 @@ const Sidebar = () => { ) : (
- -

Plan your trip

+ */} +

BMTC bus routes

); }; diff --git a/src/route/index.jsx b/src/route/index.jsx index 684e60e..67b8477 100644 --- a/src/route/index.jsx +++ b/src/route/index.jsx @@ -203,7 +203,7 @@ class RoutePage extends React.PureComponent { const { routeDetails, isFavourited } = this.state; const [from, to] = (routeDetails?.route_long_name || "").split("→"); - // console.log(routeDetails); + const tripWithTheMostStops = _.maxBy(routeDetails?.route_trips, t => t.timings.length); return ( <>
@@ -254,12 +254,12 @@ class RoutePage extends React.PureComponent {

Stops on route

- Timing at the stop + {/* Timing at the stop */}
{ _.map( - routeDetails.route_trips[0].timings, + tripWithTheMostStops.timings, (s, index) => { const stopDetails = _.find(routeDetails.stopInformation, { stop_id: s.stop_id, @@ -275,9 +275,9 @@ class RoutePage extends React.PureComponent { {stopDetails.stop_name} - { + {/* { s.arrival_time.substring(0, 5) - } + } */}
); diff --git a/src/search/index.jsx b/src/search/index.jsx index b7fbb23..95ca304 100644 --- a/src/search/index.jsx +++ b/src/search/index.jsx @@ -59,7 +59,7 @@ const SearchPage = () => { id="search-input" value={searchText} onChange={e => setSearchText(e.target.value)} - placeholder="Search for a bus, metro, or bus stop" + placeholder="Search for a bus, or bus stop" />