adjusted design

main
Inga 🏳‍🌈 1 year ago
parent 89643d7f4d
commit 1d508a8c07
  1. 3
      src/routePlanner/index.tsx
  2. 23
      src/routePlanner/markers.tsx
  3. 8
      src/routePlanner/style.css

@ -15,6 +15,9 @@ export const RoutePlanner = () => {
return (
<section class="route-planner">
<section class="header">
<h2>Route builder</h2>
</section>
<section class="markers">
<MarkersComponent
onMarkersReorder={reorderMarkers}

@ -34,18 +34,15 @@ export const MarkersComponent = ({
}, [listContainerRef, markers, onMarkersReorder]);
return (
<>
<h3>Markers</h3>
<ol ref={listContainerRef}>
{markers.map((marker, i) => (
<MarkerComponent
key={marker.key}
marker={marker}
isFirst={i === 0}
isLast={i === markers.length - 1}
/>
))}
</ol>
</>
<ol ref={listContainerRef}>
{markers.map((marker, i) => (
<MarkerComponent
key={marker.key}
marker={marker}
isFirst={i === 0}
isLast={i === markers.length - 1}
/>
))}
</ol>
);
};

@ -4,12 +4,17 @@ section.route-planner {
column-gap: 1rem;
row-gap: 1rem;
grid-template-columns: 1fr 2fr;
grid-template-rows: 1fr min-content;
grid-template-rows: min-content 1fr min-content;
grid-template-areas:
"header map"
"markers map"
"export map";
}
section.route-planner > section.header {
grid-area: header;
}
section.route-planner > section.markers {
grid-area: markers;
}
@ -83,6 +88,7 @@ section.route-planner .map-container .leaflet-tooltip-pane .text {
grid-template-columns: 1fr;
grid-template-rows: 1fr min-content 2fr;
grid-template-areas:
"header"
"markers"
"export"
"map";

Loading…
Cancel
Save