Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed admin typo and removed fullscreen button #305

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions recommender-front/src/components/map/MapComponent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import '../../assets/style.css';

function MapComponent({
poiData, time, handleSetOrigin, userPosition, handleSetDestination, routeCoordinates,
headerHidden, toggleHeader,
headerHidden, toggleHeader, showToggleHeaderButton = true,
}) {
const position = [60.2049, 24.9649];
const minZoom = 12;
Expand All @@ -19,9 +19,11 @@ function MapComponent({

return (
<div className={`map-container${headerHidden ? ' fullscreen' : ''}`}>
<button type="button" className="toggle-header-button" onClick={toggleHeader}>
{headerHidden ? <FullscreenIcon /> : <FullscreenExitIcon />}
</button>
{showToggleHeaderButton && (
<button type="button" className="toggle-header-button" onClick={toggleHeader}>
{headerHidden ? <FullscreenIcon /> : <FullscreenExitIcon />}
</button>
)}
<MapContainer
id="map"
center={position}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,10 @@ function SimulatorFormComponent({
<Typography>Precipitation</Typography>
<CustomTextField
name="precipitation"
placeholder="Precipitation (%)"
placeholder="Precipitation mm)"
value={simulatedWeatherData.precipitation}
handleInputChange={handleInputChange}
helperText="%"
helperText="mm"
/>
<Typography>Cloud Amount</Typography>
<CustomTextField
Expand Down
1 change: 1 addition & 0 deletions recommender-front/src/pages/SimulatorPage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ function SimulatorPage() {
<MapComponent
poiData={poiData}
time="Weather"
showToggleHeaderButton={false}
/>
{isNightTime && <div className="night-overlay" data-testid="night-overlay" />}
</div>
Expand Down