Skip to content

Commit

Permalink
add local to train times (#744)
Browse files Browse the repository at this point in the history
  • Loading branch information
rolorogan authored Mar 18, 2024
1 parent bb50a8a commit 2e628ac
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 7 deletions.
6 changes: 3 additions & 3 deletions .env.development
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
EXTEND_ESLINT=true # Set linting to true on dev
# developemnt API and keys
REACT_APP_API_HOST='https://wmca-api-portal-staging.azure-api.net'
REACT_APP_API_KEY='222b17e018f94b5ea1c08913db98f298'
# developemnt API and keys https://wmca-api-portal-staging.azure-api.net 222b17e018f94b5ea1c08913db98f298
REACT_APP_API_HOST='https://api.wmnetwork.co.uk'
REACT_APP_API_KEY='514b8bafa009424289cb2d7a12c54f6e'
# feedback link id
REACT_APP_FEEDBACK_LINK_URL='https://forms.office.com/Pages/ResponsePage.aspx'
REACT_APP_FEEDBACK_LINK_ID='RetZCK7xCk6e-ubWa7tnL1voVKMeFXVKvUhU3Uh8aqFUNUNVNFlKOVpLMThNV0g0T1VZWDYyT1FLNCQlQCN0PWcu'
Expand Down
20 changes: 20 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"fecha": "^4.2.3",
"haversine-distance": "^1.2.1",
"moment": "^2.29.4",
"moment-timezone": "^0.5.45",
"prop-types": "^15.8.1",
"react": "^18.2.0",
"react-app-polyfill": "^3.0.0",
Expand Down
2 changes: 1 addition & 1 deletion public/index.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" class="wmnds-html">
<html lang="en-GB" class="wmnds-html">
<head>
<meta charset="utf-8" />

Expand Down
7 changes: 4 additions & 3 deletions src/components/shared/DisruptionInfo/DisruptionInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ import PropTypes from 'prop-types';
import dompurify from 'dompurify';
// Import Moment
import Moment from 'react-moment';
import 'moment-timezone';

// Import contexts
import { AutoCompleteContext, FetchDisruptionsContext, ModeContext } from 'globalState';
// Import Helper functions
Expand Down Expand Up @@ -109,13 +111,12 @@ function DisruptionInfo({ disruption }) {
<p>
<strong>When?</strong>
<br />
{/* Temporary fix for textual errors of rail disruption timings during British Summer Time: <Moment locale="en-GB" format="dddd, Do MMMM YYYY HH:mm" add={{ hours: 1 }}>*/}
<Moment locale="en-GB" format="dddd, Do MMMM YYYY HH:mm">
<Moment local format="dddd, Do MMMM YYYY HH:mm">
{disruption.disruptionTimeWindow.start}
</Moment>
{' to '}

<Moment locale="en-GB" format="dddd, Do MMMM YYYY HH:mm">
<Moment local format="dddd, Do MMMM YYYY HH:mm">
{disruption.disruptionTimeWindow.end}
</Moment>
</p>
Expand Down

0 comments on commit 2e628ac

Please sign in to comment.