132 lines
5.5 KiB
Dart
132 lines
5.5 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:get/get.dart';
|
|
|
|
import '../../../constant/colors.dart';
|
|
import '../../../constant/style.dart';
|
|
import '../../../controller/home/map_page_controller.dart';
|
|
import 'hexegone_clipper.dart';
|
|
|
|
GetBuilder<MapController> hexagonClipper() {
|
|
return GetBuilder<MapController>(
|
|
builder: ((controller) => controller.rideConfirm
|
|
? Positioned(
|
|
top: Get.height * .2,
|
|
left: Get.width * .2,
|
|
right: Get.width * .2,
|
|
child: ClipPath(
|
|
clipper:
|
|
HexagonClipper(), // CustomClipper to create a hexagon shape
|
|
child: AnimatedContainer(
|
|
duration: const Duration(microseconds: 300),
|
|
height: 250,
|
|
width: 250,
|
|
decoration: BoxDecoration(
|
|
boxShadow: [
|
|
BoxShadow(
|
|
color: AppColor.primaryColor.withOpacity(0.25),
|
|
blurRadius: 4,
|
|
spreadRadius: 2,
|
|
offset: const Offset(0, 4),
|
|
),
|
|
BoxShadow(
|
|
color: AppColor.accentColor.withOpacity(0.5),
|
|
offset: const Offset(-5, -5),
|
|
blurRadius: 5,
|
|
spreadRadius: 2,
|
|
),
|
|
BoxShadow(
|
|
color: AppColor.secondaryColor.withOpacity(0.2),
|
|
offset: const Offset(5, 5),
|
|
blurRadius: 5,
|
|
spreadRadius: 2,
|
|
),
|
|
],
|
|
gradient: const LinearGradient(
|
|
colors: [AppColor.greenColor, AppColor.secondaryColor],
|
|
begin: Alignment.topLeft,
|
|
end: Alignment.bottomCenter,
|
|
),
|
|
border: Border.all(),
|
|
color: AppColor.secondaryColor,
|
|
borderRadius: BorderRadius.circular(15)),
|
|
child: Column(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
children: [
|
|
Text(
|
|
'Waiting for Captin ...'.tr,
|
|
style: AppStyle.title,
|
|
),
|
|
// IconButton(
|
|
// onPressed: () {
|
|
// print(controller.dataCarsLocationByPassenger);
|
|
// },
|
|
// icon: const Icon(Icons.add),
|
|
// ),
|
|
Text(
|
|
controller.dataCarsLocationByPassenger['message'][0]
|
|
['phone']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
|
children: [
|
|
Text(
|
|
controller.dataCarsLocationByPassenger['message'][0]
|
|
['first_name']
|
|
.toString() +
|
|
' ' +
|
|
controller
|
|
.dataCarsLocationByPassenger['message'][0]
|
|
['last_name']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
Text(
|
|
'Age is '.tr +
|
|
controller
|
|
.dataCarsLocationByPassenger['message'][0]
|
|
['age']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
],
|
|
),
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
|
children: [
|
|
Text(
|
|
controller.dataCarsLocationByPassenger['message'][0]
|
|
['make']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
Text(
|
|
controller.dataCarsLocationByPassenger['message'][0]
|
|
['model']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
Text(
|
|
controller.dataCarsLocationByPassenger['message'][0]
|
|
['seats']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
],
|
|
),
|
|
Text(
|
|
controller.dataCarsLocationByPassenger['message'][0]
|
|
['model']
|
|
.toString(),
|
|
style: AppStyle.title,
|
|
),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
)
|
|
: const SizedBox()));
|
|
}
|