Skip to content
Snippets Groups Projects
Commit 831d0ad9 authored by Sara Savanovic Djordjevic's avatar Sara Savanovic Djordjevic
Browse files

update: preliminary marker selection mechanism

parent c979a99f
No related branches found
No related tags found
No related merge requests found
...@@ -81,9 +81,10 @@ class _DefaultPageState extends State<DefaultPage> { ...@@ -81,9 +81,10 @@ class _DefaultPageState extends State<DefaultPage> {
children: [ children: [
MapContainerWidget(markerList: markerList), MapContainerWidget(markerList: markerList),
const SizedBox(height: 30), // Padding between widgets const SizedBox(height: 30), // Padding between widgets
const DetailedInfoContainerWidget(), DetailsContainerWidget(markerData: markerList.first),
], ],
), ),
); );
} }
} }
\ No newline at end of file
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import '../marker_data.dart';
class DetailedInfoContainerWidget extends StatelessWidget { class DetailsContainerWidget extends StatefulWidget {
const DetailedInfoContainerWidget({super.key}); const DetailsContainerWidget({Key? key, required this.markerData}) : super(key: key);
final MarkerTemplate markerData;
@override
_DetailsContainerWidgetState createState() => _DetailsContainerWidgetState();
}
class _DetailsContainerWidgetState extends State<DetailsContainerWidget> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
double screenWidth = MediaQuery.of(context).size.width; double screenWidth = MediaQuery.of(context).size.width;
...@@ -14,16 +22,30 @@ class DetailedInfoContainerWidget extends StatelessWidget { ...@@ -14,16 +22,30 @@ class DetailedInfoContainerWidget extends StatelessWidget {
width: screenWidth * boxWidth, width: screenWidth * boxWidth,
height: screenWidth * boxHeight, height: screenWidth * boxHeight,
color: Colors.blue, color: Colors.blue,
child: const Align( child: Align(
alignment: Alignment.topLeft, alignment: Alignment.topLeft,
child: Padding( child: Padding(
padding: EdgeInsets.only(top: 10, left: 10), // Edge padding, text padding: const EdgeInsets.only(top: 10, left: 10), // Edge padding, text
child: Text( child: Column(
'Placeholder text', crossAxisAlignment: CrossAxisAlignment.start,
style: TextStyle(fontSize: 20, color: Colors.black), children: [
const Text(
'Ice thickness details',
style: TextStyle(fontSize: 30, color: Colors.black),
),
Text(
'Latitude: ${widget.markerData.geoData.latitude}',
style: TextStyle(fontSize: 20, color: Colors.black),
),
Text(
'Longitude: ${widget.markerData.geoData.longitude}',
style: TextStyle(fontSize: 20, color: Colors.black),
),
// Add more information widgets here
],
), ),
), ),
), ),
); );
} }
} }
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment