import 'package:cpt_main/modules/demo_page.dart'; import 'package:cs_resources/theme/app_colors_theme.dart'; import 'package:flutter/material.dart'; import 'package:widgets/ext/ex_widget.dart'; import 'package:widgets/my_text_view.dart'; class VisitorItem extends StatelessWidget { final int index; final String item; const VisitorItem({ required this.index, required this.item, }); @override Widget build(BuildContext context) { return Container( margin: const EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5), padding: const EdgeInsets.symmetric(vertical: 19, horizontal: 18.5), decoration: BoxDecoration( color: context.appColors.whiteBG, borderRadius: BorderRadius.circular(6.0), // 圆角 boxShadow: [ BoxShadow( color: const Color(0xFFB8BFD9).withOpacity(0.3), // 阴影颜色 offset: const Offset(0, 3), // 阴影的偏移量 blurRadius: 8.0, // 模糊半径 spreadRadius: 3.0, // 扩散半径 ), ], ), child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ //姓名 MyTextView( "Wu Bing Bing", fontSize: 16, marginTop: 19, marginBottom: 5, textColor: context.appColors.textBlack, isFontMedium: true, ), //电话/身份证 Row( children: [ MyTextView( "+86 12345678901", fontSize: 14, textColor: context.appColors.textBlack, isFontRegular: true, ), const Spacer(), MyTextView( "M12****7B", fontSize: 14, textColor: context.appColors.textBlack, isFontRegular: true, ), ], ), //车牌号/访问日期 Row( children: [ MyTextView( "EFG8878", fontSize: 14, textColor: context.appColors.textBlack, isFontRegular: true, ), const Spacer(), MyTextView( "Monday 13 Oct 2024", fontSize: 14, textColor: context.appColors.textBlack, isFontRegular: true, ), ], ).marginOnly(top: 5), //备注 MyTextView( "Visiting a friend's house as a guest", fontSize: 14, marginTop: 6, textColor: context.appColors.textDarkGray, isFontRegular: true, fontWeight: FontWeight.w500, ), ], ), ); } }