From 6c4fae9b821cb667655cbe2deb1757284f61cc42 Mon Sep 17 00:00:00 2001 From: "Daniel S. Hansen" Date: Wed, 6 Aug 2025 16:25:54 -0700 Subject: [PATCH 1/2] Add boilerplate Volcano view page --- client/src/components/Canvas/views/Home.jsx | 1 + .../src/components/Canvas/views/Volcano.jsx | 71 ++++++++++++++----- 2 files changed, 54 insertions(+), 18 deletions(-) diff --git a/client/src/components/Canvas/views/Home.jsx b/client/src/components/Canvas/views/Home.jsx index bc95eb8..21f1b50 100644 --- a/client/src/components/Canvas/views/Home.jsx +++ b/client/src/components/Canvas/views/Home.jsx @@ -111,6 +111,7 @@ export default function Home({...props}) { bg="base200" px={6} pt={3} + pb={2} align="center" justify="space-between" width="100%" diff --git a/client/src/components/Canvas/views/Volcano.jsx b/client/src/components/Canvas/views/Volcano.jsx index c2a5a50..26303da 100644 --- a/client/src/components/Canvas/views/Volcano.jsx +++ b/client/src/components/Canvas/views/Volcano.jsx @@ -1,24 +1,59 @@ -import { Box, Text } from '@chakra-ui/react'; +import { Box, Text, Heading, DataList } from '@chakra-ui/react'; +import React from "react"; +import { MapContainer, TileLayer, Marker, Popup } from "react-leaflet"; export default function Volcano() { + const position = [46.2, -122.18]; // Mt. St. Helens + const stats = [ + { label: "Elevation", value: "2,539 (m) 8,330 (ft)", helpText: "Volcano Elevation" }, + { label: "Volcano Type", value: "Stratovolcano", helpText: "Volcano Type" }, + { label: "Composition", value: "Basalt to Ryodacite", helpText: "Volcano Composition" }, + { label: "Recent Eruptions", value: "1980, 2004-2008", helpText: "Last Eruption" }, + { label: "Threat Potential", value: "Very High", helpText: "Threat Potential" }, + + ] return ( - - - - Volcano Canvas coming soon! - - + + + Mt. St. Helens - United States CVO + + + + + + CVO — Home of the volcanoligists + + + + + {stats.map((item) => ( + + {item.label} + {item.value} + + ))} + + // + // + // + // Volcano Canvas coming soon! + // + // + // ); } \ No newline at end of file From c91216d214f2a9a67eda52f638c7e37e8a678047 Mon Sep 17 00:00:00 2001 From: "Daniel S. Hansen" Date: Wed, 6 Aug 2025 17:10:33 -0700 Subject: [PATCH 2/2] Add Volcano view DataList, historical summary, and map --- .../src/components/Canvas/views/Volcano.jsx | 93 +++++++++++-------- 1 file changed, 52 insertions(+), 41 deletions(-) diff --git a/client/src/components/Canvas/views/Volcano.jsx b/client/src/components/Canvas/views/Volcano.jsx index 26303da..985b7e6 100644 --- a/client/src/components/Canvas/views/Volcano.jsx +++ b/client/src/components/Canvas/views/Volcano.jsx @@ -1,4 +1,4 @@ -import { Box, Text, Heading, DataList } from '@chakra-ui/react'; +import { Box, Text, Heading, DataList, HStack } from '@chakra-ui/react'; import React from "react"; import { MapContainer, TileLayer, Marker, Popup } from "react-leaflet"; @@ -12,48 +12,59 @@ export default function Volcano() { { label: "Threat Potential", value: "Very High", helpText: "Threat Potential" }, ] + + const historyText = ` + Mount St. Helens, located in the Cascade Range of Washington State, is one of the most + active and well-known volcanoes in the United States. It famously erupted on May 18, 1980, + in one of the most significant volcanic events in U.S. history, which caused widespread + devastation and loss of life. The eruption reduced the mountain’s summit and created a large + crater. Subsequent dome-building eruptions continued through the 2000s, and the volcano + remains closely monitored today. + `; + return ( - - - Mt. St. Helens - United States CVO + + + Mount St. Helens - United States CVO - - - - - CVO — Home of the volcanoligists - - - - - {stats.map((item) => ( - - {item.label} - {item.value} - - ))} - + + + + + + + CVO — Home of the volcanoligists + + + + + + + + + {stats.map((item) => ( + + + {item.label} + + + {item.value} + + + ))} + + + + + Historical Summary + + { historyText} + + + - // - // - // - // Volcano Canvas coming soon! - // - // - // ); } \ No newline at end of file