Skip to content

Commit

Permalink
public-web: Adjust wordings and UX update
Browse files Browse the repository at this point in the history
merged #67
  • Loading branch information
jasonho215 authored Jan 16, 2022
2 parents 4d30c0e + 048c3a7 commit 5b71df0
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 28 deletions.
4 changes: 2 additions & 2 deletions src/public-web/src/components/MainLinks/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import { RouteType } from '../../routes';
import { useStyles } from './style';

const links: { name: string; routeType: RouteType }[] = [
{ routeType: RouteType.RequestPpe, name: 'REQUEST PPE' },
{ routeType: RouteType.RegisterSupplies, name: 'GIVE PPE' },
{ routeType: RouteType.RequestPpe, name: 'I NEED' },
{ routeType: RouteType.RegisterSupplies, name: 'I HAVE' },
{ routeType: RouteType.About, name: 'ABOUT' },
{ routeType: RouteType.Partners, name: 'PARTNERS' },
];
Expand Down
19 changes: 10 additions & 9 deletions src/public-web/src/containers/contactUs/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@ import { useStyles } from './style';

export const ContactUs: React.FC = () => {
const { classes } = useStyles();
return <div className={classes.content}>
<h1>Contact Us</h1>
return (
<div className={classes.content}>
<h1>Contact Us</h1>

<p>
Please contact us by sending email to <a href="mailto:admin@example.com">admin@example.com</a>.
</p>
<p>
Thank you!
</p>
</div>;
<p>
Please contact us by sending email to{' '}
<a href="mailto:frontline@wearebeep.com">frontline@wearebeep.com</a>.
</p>
<p>Thank you!</p>
</div>
);
};
1 change: 0 additions & 1 deletion src/public-web/src/containers/contactUs/style.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,3 @@ export const useStyles = createStyles((theme) => ({
},
},
}));

16 changes: 10 additions & 6 deletions src/public-web/src/containers/landing/components/Map/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -246,10 +246,6 @@ export const Map: React.FC = () => {
const [mapData, setMapData] = useState<Nullable<MapData>>(null);
const [loaded, setLoaded] = useState(false);

const [lng] = useState(-0.118092);
const [lat] = useState(51.509865);
const [zoom] = useState(8);

const [categoryVisibilityMap, setCategoryVisibilityMap] = useState(
defaultCategoryVisibilityMap
);
Expand All @@ -260,8 +256,16 @@ export const Map: React.FC = () => {
mapRef.current = new MapboxMap({
container: mapContainer.current,
style: 'mapbox://styles/mapbox/streets-v11',
center: [lng, lat],
zoom: zoom,
// The bound of the UK
bounds: [
[-10.809872337116673, 49.300494132364435],
[9.028203002610155, 59.13892469548853],
],
fitBoundsOptions: {
padding: 20,
},
minZoom: 1,
maxZoom: 18,
pitchWithRotate: false,
});
mapRef.current.on('load', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,13 +203,13 @@ export const MapControl: React.FC<Props> = ({
spacing="xs"
>
<Radio value="post">
Post{' '}
All requests{' '}
{countMap?.[CategoryEnum.Need].posts && (
<i>{countMap[CategoryEnum.Need].posts}</i>
)}
</Radio>
<Radio value="breakdown">
Breakdowns{' '}
Filter items{' '}
{countMap?.[CategoryEnum.Need].totalBreakdowns && (
<i>{countMap[CategoryEnum.Need].totalBreakdowns}</i>
)}
Expand All @@ -236,13 +236,13 @@ export const MapControl: React.FC<Props> = ({
spacing="xs"
>
<Radio value="post">
Post{' '}
All requests{' '}
{countMap?.[CategoryEnum.NeedMet].posts && (
<i>{countMap[CategoryEnum.NeedMet].posts}</i>
)}
</Radio>
<Radio value="breakdown">
Breakdowns{' '}
Filter items{' '}
{countMap?.[CategoryEnum.NeedMet].totalBreakdowns && (
<i>{countMap[CategoryEnum.NeedMet].totalBreakdowns}</i>
)}
Expand All @@ -269,13 +269,13 @@ export const MapControl: React.FC<Props> = ({
spacing="xs"
>
<Radio value="post">
Post{' '}
All supplies{' '}
{countMap?.[CategoryEnum.Supply].posts && (
<i>{countMap[CategoryEnum.Supply].posts}</i>
)}
</Radio>
<Radio value="breakdown">
Breakdowns{' '}
Filter items{' '}
{countMap?.[CategoryEnum.Supply].totalBreakdowns && (
<i>{countMap[CategoryEnum.Supply].totalBreakdowns}</i>
)}
Expand Down
4 changes: 2 additions & 2 deletions src/public-web/src/containers/registerSupplies/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ export const RegisterSupplies: React.FC = () => {
color: 'flGreen',
title: 'Save Successful',
message:
'Thanks you have been added to the database, we will be in contact in due course. You will be redirected to home page in 5 seconds.',
autoClose: 5000,
'Thanks you have been added to the database, we will be in contact in due course. You will be redirected to home page in 10 seconds.',
autoClose: 10000,
onClose: () => {
navigate('/');
},
Expand Down
4 changes: 2 additions & 2 deletions src/public-web/src/containers/requestPpe/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ export const RequestPpe: React.FC = () => {
color: 'flGreen',
title: 'Save Successful',
message:
'Thanks you have been added to the database, we will be in contact in due course. You will be redirected to home page in 5 seconds.',
autoClose: 5000,
'Thanks you have been added to the database, we will be in contact in due course. You will be redirected to home page in 10 seconds.',
autoClose: 10000,
onClose: () => {
navigate('/');
},
Expand Down

0 comments on commit 5b71df0

Please sign in to comment.