diff --git a/lib/component/NullDataComponentWidget.dart b/lib/component/NullDataComponentWidget.dart index 9a78b76..b4de066 100644 --- a/lib/component/NullDataComponentWidget.dart +++ b/lib/component/NullDataComponentWidget.dart @@ -57,13 +57,12 @@ class _TestWidgetState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '暂无数据'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - useGoogleFonts: false, - fontFamily: "PingFangSC", - letterSpacing: 0.0, - fontSize: 26.rpx, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: "PingFangSC", + letterSpacing: 0.0, + fontSize: 26.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), diff --git a/lib/component/home_page/DynamicReportDetailWidget.dart b/lib/component/home_page/DynamicReportDetailWidget.dart index 658179a..bfd516a 100644 --- a/lib/component/home_page/DynamicReportDetailWidget.dart +++ b/lib/component/home_page/DynamicReportDetailWidget.dart @@ -97,12 +97,12 @@ class _DynamicReportDetailWidgetState extends State { }, child: Text( '${targetDevice['person']?['name'] == null ? '未命名'.tr : targetDevice['person']['name']}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ClickableContainer( @@ -132,12 +132,12 @@ class _DynamicReportDetailWidgetState extends State { children: [ Text( '首页.报告详情'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), Padding( padding: EdgeInsetsDirectional.fromSTEB(0, 6.rpx, 0, 0.rpx), @@ -178,11 +178,11 @@ class _DynamicReportDetailWidgetState extends State { alignment: Alignment.center, child: Text( '暂无数据'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 28.rpx, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 28.rpx, + color: themeController.currentColor.sc4, + ), ), ); } diff --git a/lib/component/home_page/SleepDataModuleWidget.dart b/lib/component/home_page/SleepDataModuleWidget.dart index 870405d..8f1c397 100644 --- a/lib/component/home_page/SleepDataModuleWidget.dart +++ b/lib/component/home_page/SleepDataModuleWidget.dart @@ -246,11 +246,13 @@ class _SleepDataModuleWidgetState extends State { 'date': widget.data['time'] != null ? int.parse(widget.data['time'].toString()) : DateTime.now().millisecondsSinceEpoch, - "mac": widget.data['mac'] != null && widget.data['mac'].isNotEmpty? widget.data['mac']:'aaaaaaeeeeeq', + "mac": widget.data['mac'] != null && widget.data['mac'].isNotEmpty + ? widget.data['mac'] + : 'aaaaaaeeeeeq', 'type': 1, 'name': 'sleep', //'sleep', 'heartRate' 或 'breathe' 'itemName': widget.data['id'], - 'person':widget.data['person'], + 'person': widget.data['person'], }); } }, @@ -267,12 +269,12 @@ class _SleepDataModuleWidgetState extends State { children: [ Text( '${widget.data['name']}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), @@ -287,7 +289,7 @@ class _SleepDataModuleWidgetState extends State { // children: [ // Text( // '${widget.data['value']}', - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Inter', // fontSize: 36.rpx, // letterSpacing: 0.0, @@ -374,12 +376,12 @@ class _SleepDataModuleWidgetState extends State { ), child: Text( '${widget.data['level']}', - style: FlutterFlowTheme.of(context).titleSmall.override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - fontSize: 15.rpx, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + fontSize: 15.rpx, + ), ), ), ), @@ -388,12 +390,12 @@ class _SleepDataModuleWidgetState extends State { Text( "正常值".tr + '${(widget.data['range'] ?? '').toString().isEmpty ? '未知数据'.tr : widget.data['range']}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: AppConstants().small_text_fontSize, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants().small_text_fontSize, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), diff --git a/lib/component/home_page/SleepDateWidget.dart b/lib/component/home_page/SleepDateWidget.dart index fa08470..95ff7b5 100644 --- a/lib/component/home_page/SleepDateWidget.dart +++ b/lib/component/home_page/SleepDateWidget.dart @@ -1,4 +1,3 @@ -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:ef/ef.dart'; import 'package:flutter/material.dart'; import 'package:flutterflow_ui/flutterflow_ui.dart'; @@ -84,24 +83,24 @@ class _SleepDateWidgetState extends State { padding: EdgeInsetsDirectional.fromSTEB(0, 0, 0, 14.rpx), child: Text( '${week}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: AppConstants().title_text_fontSize, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants().title_text_fontSize, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), Padding( padding: EdgeInsetsDirectional.fromSTEB(0, 0, 0, 33.rpx), child: Text( '${day}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 20.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 20.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), Padding( @@ -112,14 +111,14 @@ class _SleepDateWidgetState extends State { children: [ Text( (widget.score?.isEmpty ?? true) ? '--' : widget.score!, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - color: widget.textColor ?? - themeController.currentColor.sc4, - fontWeight: FontWeight.bold, // 加粗 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + color: widget.textColor ?? + themeController.currentColor.sc4, + fontWeight: FontWeight.bold, // 加粗 + ), ), if ((widget.score?.trim().isNotEmpty ?? false)) Padding( @@ -127,14 +126,12 @@ class _SleepDateWidgetState extends State { EdgeInsetsDirectional.fromSTEB(0, 16.rpx, 0, 0.rpx), child: Text( '分'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants().small_text_fontSize, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants().small_text_fontSize, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ], @@ -160,11 +157,11 @@ class _SleepDateWidgetState extends State { EdgeInsetsDirectional.fromSTEB(16.rpx, 0, 16.rpx, 0), iconPadding: EdgeInsetsDirectional.fromSTEB(0, 0, 0, 0), color: widget.textColor ?? themeController.currentColor.sc4, - textStyle: FlutterFlowTheme.of(context).titleSmall.override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + textStyle: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), elevation: 0, borderRadius: BorderRadius.circular(50.rpx), ), diff --git a/lib/component/img/img_default_widget.dart b/lib/component/img/img_default_widget.dart index 4d0e627..049cff5 100644 --- a/lib/component/img/img_default_widget.dart +++ b/lib/component/img/img_default_widget.dart @@ -3,7 +3,6 @@ import 'package:flutter/material.dart'; import '../../controller/mh_controller/apply_repair_controller.dart'; - class ImgPreviewDefaultWidget extends GetView { ApplyRepairController applyRepairController; @@ -13,7 +12,7 @@ class ImgPreviewDefaultWidget extends GetView { Widget build(BuildContext context) { return InkWell( // onTap: applyRepairController.uploadImg, - onTap: ()async{}, + onTap: () async {}, child: Container( width: MediaQuery.sizeOf(context).width * 0.25, height: MediaQuery.sizeOf(context).height * 0.15, @@ -38,7 +37,7 @@ class ImgPreviewDefaultWidget extends GetView { borderRadius: BorderRadius.circular(16), ), child: Align( - alignment: AlignmentDirectional(0, 0), + alignment: AlignmentDirectional(0, 0), child: Container( width: 35, height: 35, @@ -60,12 +59,12 @@ class ImgPreviewDefaultWidget extends GetView { padding: EdgeInsetsDirectional.fromSTEB(0, 8, 0, 13), child: Text( ' ', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 11, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 11, + letterSpacing: 0, + ), ), ), ), diff --git a/lib/component/img/img_preview_widget.dart b/lib/component/img/img_preview_widget.dart index 908ee5f..5b70c42 100644 --- a/lib/component/img/img_preview_widget.dart +++ b/lib/component/img/img_preview_widget.dart @@ -64,12 +64,12 @@ class ImgPreviewWidget extends GetView { }, child: Text( '删除', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), )), )), diff --git a/lib/controller/mh_controller/address_controller.dart b/lib/controller/mh_controller/address_controller.dart index b85206b..48d41dc 100644 --- a/lib/controller/mh_controller/address_controller.dart +++ b/lib/controller/mh_controller/address_controller.dart @@ -57,99 +57,100 @@ class AddressController extends GetControllerEx { address['phone'] = model.phone; address['isChecked'] = model.ischecked; - try { - final data = await ef.client.rpc("get_now_datetime"); - final response = await ef.client.from("app_user_address").update({ - 'province': address["province"], - 'city': address["city"], - 'county': address["county"], - 'street': address["street"], - 'detail': address["detail"], - 'name': address["name"], - 'phone': address["phone"], - 'ischecked': address['isChecked'] ? 1 : 0, - 'update_time': - DateFormat("yyyy-MM-dd HH:mm:ss").parse("$data").toString(), - }).eq("id", address['id']); - } catch (e) { - print('Error fetching repairs: $e'); - return e.toString(); - } + // try { + // final data = await ef.client.rpc("get_now_datetime"); + // final response = await ef.client.from("app_user_address").update({ + // 'province': address["province"], + // 'city': address["city"], + // 'county': address["county"], + // 'street': address["street"], + // 'detail': address["detail"], + // 'name': address["name"], + // 'phone': address["phone"], + // 'ischecked': address['isChecked'] ? 1 : 0, + // 'update_time': + // DateFormat("yyyy-MM-dd HH:mm:ss").parse("$data").toString(), + // }).eq("id", address['id']); + // } catch (e) { + // print('Error fetching repairs: $e'); + // return e.toString(); + // } return ''; } addAddress(AddressModel model) async { - try { - final UserInfoController userInfoController = - Get.find(); - UserModel user = userInfoController.model.user!; + // try { + // final UserInfoController userInfoController = + // Get.find(); + // UserModel user = userInfoController.model.user!; - // 设置省市区街道名称 - if (model.addressList != null && model.addressList!.isNotEmpty) { - if (model.addressList!.length > 0) - model.province = model.addressList![0].name; // 第一个元素为省 - if (model.addressList!.length > 1) - model.city = model.addressList![1].name; // 第二个元素为市 - if (model.addressList!.length > 2) - model.county = model.addressList![2].name; // 第三个元素为区 - if (model.addressList!.length > 3) - model.street = model.addressList![3].name; // 第四个元素为街道 - } + // // 设置省市区街道名称 + // if (model.addressList != null && model.addressList!.isNotEmpty) { + // if (model.addressList!.length > 0) + // model.province = model.addressList![0].name; // 第一个元素为省 + // if (model.addressList!.length > 1) + // model.city = model.addressList![1].name; // 第二个元素为市 + // if (model.addressList!.length > 2) + // model.county = model.addressList![2].name; // 第三个元素为区 + // if (model.addressList!.length > 3) + // model.street = model.addressList![3].name; // 第四个元素为街道 + // } - // 查询数据库是否已有该用户的地址 - final existingAddresses = await ef.client - .from('app_user_address') - .select() - .eq('user_id', user.uid!); + // // 查询数据库是否已有该用户的地址 + // final existingAddresses = await ef.client + // .from('app_user_address') + // .select() + // .eq('user_id', user.uid!); - // 如果没有地址,将新增地址默认选中 - if (existingAddresses.isEmpty) { - model.ischecked = true; - } else if (model.ischecked == true) { - // 如果新地址被选中,将其他地址的 `ischecked` 字段设为 `0` - await ef.client - .from('app_user_address') - .update({'ischecked': 0}).eq('user_id', user.uid!); - } + // // 如果没有地址,将新增地址默认选中 + // if (existingAddresses.isEmpty) { + // model.ischecked = true; + // } else if (model.ischecked == true) { + // // 如果新地址被选中,将其他地址的 `ischecked` 字段设为 `0` + // await ef.client + // .from('app_user_address') + // .update({'ischecked': 0}).eq('user_id', user.uid!); + // } - // 添加新地址 - final response = await ef.client.from('app_user_address').insert({ - 'province': model.province, - 'city': model.city, - 'county': model.county, - 'street': model.street, - 'detail': model.detail, - 'name': model.name, - 'phone': model.phone, - 'ischecked': model.ischecked! ? 1 : 0, - 'user_id': user.uid, - }); - } catch (e) { - print(e); - } + // // 添加新地址 + // final response = await ef.client.from('app_user_address').insert({ + // 'province': model.province, + // 'city': model.city, + // 'county': model.county, + // 'street': model.street, + // 'detail': model.detail, + // 'name': model.name, + // 'phone': model.phone, + // 'ischecked': model.ischecked! ? 1 : 0, + // 'user_id': user.uid, + // }); + // } catch (e) { + // print(e); + // } } Future> getData({int? level, int? pid}) async { // 构建查询 - var query = ef.from("app_area_city").select(); + return []; + // var query = ef.from("app_area_city").select(); - // 如果 pid 不为 null,添加 pid 的条件 - if (pid != null) { - query = query.eq("pid", pid); - } - if (level != null) { - query = query.eq("deep", level); - } - List arr = await query; + // // 如果 pid 不为 null,添加 pid 的条件 + // if (pid != null) { + // query = query.eq("pid", pid); + // } + // if (level != null) { + // query = query.eq("deep", level); + // } + // List arr = await query; - List addressNodes = arr.map((item) { - return AddressNode.fromJson({ - "name": item["ext_name"], // ext_name 对应 name - "code": item["id"], // id 对应 code - "letter": item["pinyin_prefix_upper"], // pinyin_prefix_upper 对应 letter - }); - }).toList(); + // List addressNodes = arr.map((item) { + // return AddressNode.fromJson({ + // "name": item["ext_name"], // ext_name 对应 name + // "code": item["id"], // id 对应 code + // "letter": item["pinyin_prefix_upper"], // pinyin_prefix_upper 对应 letter + // }); + // }).toList(); - return addressNodes; + // return addressNodes; } } diff --git a/lib/controller/user_info_controller.dart b/lib/controller/user_info_controller.dart index 3957d89..df62545 100644 --- a/lib/controller/user_info_controller.dart +++ b/lib/controller/user_info_controller.dart @@ -32,9 +32,9 @@ class UserInfoModel { String? appVersion; //app版本信息 @JsonKey(ignore: true) - Session? superbase_session; + // Session? superbase_session; @JsonKey(ignore: true) - User? superbase_user; + // User? superbase_user; String? img_bucket = 'user'; int? login = 0; //0未登录 1 登录 diff --git a/lib/main.dart b/lib/main.dart index 7872109..94dac91 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -115,9 +115,13 @@ Future main() async { } initLanguageSetting() { - Get.put(LanguageController()); - LanguageController languageController = Get.find(); - languageController.initLanuageList(); + try { + Get.put(LanguageController()); + LanguageController languageController = Get.find(); + languageController.initLanuageList(); + } catch (e) { + print(e); + } } // 初始化微信开放平台注册 diff --git a/lib/pages/common/selectDialog.dart b/lib/pages/common/selectDialog.dart index 5c50444..cd0c840 100644 --- a/lib/pages/common/selectDialog.dart +++ b/lib/pages/common/selectDialog.dart @@ -42,7 +42,7 @@ getOnePicker(BuildContext context, List arr, int checkIndex, // ), // ), child: Text("${arr[index]}$unit", - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', color: textColor, letterSpacing: 0, @@ -84,14 +84,14 @@ getOnePickers( return Center( child: Text( "${arr[index]}$unit", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: isSelected - ? const Color(0xFF011D33) // ✅ 选中项颜色 - : Color(0xFF9AA0B3), // 未选中颜色 - fontSize: 30.rpx, - fontWeight: isSelected ? FontWeight.bold : FontWeight.normal, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: isSelected + ? const Color(0xFF011D33) // ✅ 选中项颜色 + : Color(0xFF9AA0B3), // 未选中颜色 + fontSize: 30.rpx, + fontWeight: isSelected ? FontWeight.bold : FontWeight.normal, + ), ), ); }, @@ -172,13 +172,11 @@ Future showDateSelectionDialog(BuildContext context, ), Text( title, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + ), ), ClickableContainer( backgroundColor: Colors.transparent, @@ -331,13 +329,11 @@ Future showWeightPickerDialog( ), )), Text(title, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - )), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + )), ClickableContainer( backgroundColor: Colors.transparent, highlightColor: Colors.transparent, @@ -461,13 +457,11 @@ Future showHeightPickerDialog( ), )), Text(title, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - )), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + )), ClickableContainer( backgroundColor: Colors.transparent, highlightColor: Colors.transparent, @@ -728,13 +722,11 @@ Future showDayTimeSelectionDialog( ), Text( title, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + ), ), ClickableContainer( backgroundColor: Colors.transparent, @@ -871,13 +863,11 @@ Future showOneSelectionDialog( ), ), Text(title, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - )), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + )), ClickableContainer( backgroundColor: Colors.transparent, highlightColor: Colors.transparent, diff --git a/lib/pages/device/BodyDeviceWidget.dart b/lib/pages/device/BodyDeviceWidget.dart index d0400b2..f21d94a 100644 --- a/lib/pages/device/BodyDeviceWidget.dart +++ b/lib/pages/device/BodyDeviceWidget.dart @@ -368,15 +368,13 @@ class _BodyDevicePageState extends State { alignment: Alignment.center, child: Text( '体征检测设备.我的e护'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - color: bodyDeviceController + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + color: + bodyDeviceController .model .type == 2 @@ -386,7 +384,7 @@ class _BodyDevicePageState extends State { : themeController .currentColor .sc2, - ), + ), ), ), SizedBox(height: 10.rpx), @@ -422,15 +420,13 @@ class _BodyDevicePageState extends State { alignment: Alignment.center, child: Text( '体征检测设备.云关爱'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - color: bodyDeviceController + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + color: + bodyDeviceController .model .type == 1 @@ -440,7 +436,7 @@ class _BodyDevicePageState extends State { : themeController .currentColor .sc2, - ), + ), ), ), SizedBox(height: 10.rpx), @@ -511,26 +507,19 @@ class _BodyDevicePageState extends State { EdgeInsets.fromLTRB( 12.rpx, 0, 0.rpx, 0), isDense: true, - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '体征检测设备.输入关键词'.tr, - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -555,9 +544,7 @@ class _BodyDevicePageState extends State { OutlineInputBorder( borderSide: BorderSide( color: - FlutterFlowTheme.of( - context) - .error, + Colors.red, width: 1.rpx, ), borderRadius: @@ -568,9 +555,7 @@ class _BodyDevicePageState extends State { OutlineInputBorder( borderSide: BorderSide( color: - FlutterFlowTheme.of( - context) - .error, + Colors.red, width: 1.rpx, ), borderRadius: @@ -579,20 +564,15 @@ class _BodyDevicePageState extends State { ), filled: false, fillColor: - FlutterFlowTheme.of( - context) - .secondaryBackground, + Colors.white, + ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), cursorColor: themeController .currentColor.sc3, ), @@ -633,17 +613,14 @@ class _BodyDevicePageState extends State { }, child: Text( '体征检测设备.搜索'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - color: themeController - .currentColor.sc2, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + color: themeController + .currentColor.sc2, + ), ), ), ].divide(SizedBox(width: 14.rpx)), diff --git a/lib/pages/device/component/DeviceDataComponentWidget.dart b/lib/pages/device/component/DeviceDataComponentWidget.dart index 336ad8f..5f0b2bf 100644 --- a/lib/pages/device/component/DeviceDataComponentWidget.dart +++ b/lib/pages/device/component/DeviceDataComponentWidget.dart @@ -420,12 +420,12 @@ class _DeviceDataComponentWidgetState extends State { decoration: InputDecoration( isDense: true, hintText: '请输入人员名称'.tr, - hintStyle: FlutterFlowTheme.of(context).labelMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -441,13 +441,13 @@ class _DeviceDataComponentWidgetState extends State { borderRadius: BorderRadius.circular(8.rpx), ), ), - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: Colors.black, - ), - cursorColor: FlutterFlowTheme.of(context).primaryText, + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: Colors.black, + ), + cursorColor: Colors.white, ), ), ), @@ -525,12 +525,12 @@ class _DeviceDataComponentWidgetState extends State { Text( // 'TH689564522DL', '${widget.device['person']?['name'] ?? '未命名'.tr}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), // ClickableContainer( // key: _arrowKey, @@ -587,22 +587,22 @@ class _DeviceDataComponentWidgetState extends State { decoration: BoxDecoration(), child: Text( '设备ID'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), Text( '${widget.device['code'] ?? '未知数据'.tr}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ].divide(SizedBox(width: 34.rpx)), ), @@ -618,22 +618,22 @@ class _DeviceDataComponentWidgetState extends State { decoration: BoxDecoration(), child: Text( '更新时间'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), Text( '${widget.device['status']['updateTime'] != null ? MyUtils.timestampToDateString(widget.device['status']['updateTime']) : '未知时间'.tr}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ].divide(SizedBox(width: 34.rpx)), ), @@ -654,25 +654,22 @@ class _DeviceDataComponentWidgetState extends State { decoration: BoxDecoration(), child: Text( '已分享'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), Text( '${widget.device['shareNum']}' + "人".tr, - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ].divide(SizedBox(width: 34.rpx)), ), @@ -738,27 +735,24 @@ class _DeviceDataComponentWidgetState extends State { decoration: BoxDecoration(), child: Text( '设备来源'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), Text( (widget.device['source']?.toString().isEmpty ?? true) ? '未知数据'.tr : widget.device['source'].toString(), - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ].divide(SizedBox(width: 34.rpx)), ), @@ -790,12 +784,12 @@ class _DeviceDataComponentWidgetState extends State { decoration: BoxDecoration(), child: Text( '体征检测设备.设备状态'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), maxLines: 2, overflow: TextOverflow.ellipsis, ), @@ -1102,15 +1096,12 @@ class _DeviceDataComponentWidgetState extends State { children: [ Text( "体征检测设备.人员资料".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1146,15 +1137,12 @@ class _DeviceDataComponentWidgetState extends State { children: [ Text( "体征检测设备.实时体征".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1198,15 +1186,12 @@ class _DeviceDataComponentWidgetState extends State { children: [ Text( "体征检测设备.消息回看".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1248,15 +1233,12 @@ class _DeviceDataComponentWidgetState extends State { children: [ Text( "体征检测设备.健康报告".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), diff --git a/lib/pages/device/component/DeviceStatusInfoWidget.dart b/lib/pages/device/component/DeviceStatusInfoWidget.dart index c21b245..b341caa 100644 --- a/lib/pages/device/component/DeviceStatusInfoWidget.dart +++ b/lib/pages/device/component/DeviceStatusInfoWidget.dart @@ -1,4 +1,3 @@ -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:ef/ef.dart'; import 'package:flutter/material.dart'; import 'package:flutter_svg/flutter_svg.dart'; @@ -61,12 +60,12 @@ class DeviceStatusInfoWidget extends StatelessWidget { ), Text( value, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ] .divide(SizedBox(width: 18.rpx)) @@ -74,12 +73,12 @@ class DeviceStatusInfoWidget extends StatelessWidget { ), Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ].divide(SizedBox(height: 39.rpx)), ), diff --git a/lib/pages/device/component/ReviewMessageWidgetWidget.dart b/lib/pages/device/component/ReviewMessageWidgetWidget.dart index 190a511..f076b69 100644 --- a/lib/pages/device/component/ReviewMessageWidgetWidget.dart +++ b/lib/pages/device/component/ReviewMessageWidgetWidget.dart @@ -45,12 +45,12 @@ class _ReviewMessageWidgetWidgetState extends State { child: Text( // '实时监测结果通知'.tr, "${messageInfo['data']!['title']}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -102,12 +102,12 @@ class _ReviewMessageWidgetWidgetState extends State { overflow: TextOverflow.ellipsis, maxLines: 1, "${label}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ); @@ -124,12 +124,12 @@ class _ReviewMessageWidgetWidgetState extends State { overflow: TextOverflow.ellipsis, maxLines: 1, "${value}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ); diff --git a/lib/pages/device/device_detail.dart b/lib/pages/device/device_detail.dart index 33116cb..58a42a1 100644 --- a/lib/pages/device/device_detail.dart +++ b/lib/pages/device/device_detail.dart @@ -61,12 +61,12 @@ class _DeviceDetailPageState extends State { /// 居中标题 Text( '设备详情.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0.rpx, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0.rpx, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -132,14 +132,12 @@ class _DeviceDetailPageState extends State { (widget.device['code'] ?? '').toString().isNotEmpty ? widget.device['code'].toString() : '未知数据'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), Row( @@ -173,15 +171,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.设备名称'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -193,15 +188,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.MAC'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -213,15 +205,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.型号'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -233,15 +222,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.版本'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -253,15 +239,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.网络状态'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -273,15 +256,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.故障状态'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -293,15 +273,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.更新状态'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -313,15 +290,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '设备详情.更新时间'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -394,15 +368,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '${widget.device['person']?['name'] ?? '未命名'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -414,15 +385,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '${widget.device['mac'] ?? '-'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -434,15 +402,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '-', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -454,15 +419,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '-', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -474,15 +436,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '${widget.device['status']['status'] == 1 ? '在线'.tr : '离线'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -494,15 +453,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '${widget.device['status']['failure'] == 1 ? '有故障'.tr : '无故障'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -514,15 +470,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '${widget.device['status']['upgrade'] == 1 ? '有更新'.tr : '无更新'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -534,15 +487,12 @@ class _DeviceDetailPageState extends State { AlignmentDirectional(-1.rpx, 0.rpx), child: Text( '${widget.device['status']?['updateTime'] == null ? '-'.tr : MyUtils.timestampToDateString(widget.device['status']?['updateTime'])}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.rpx, + color: themeController.currentColor.sc3, + ), ), ), ), diff --git a/lib/pages/device/instant_body_page.dart b/lib/pages/device/instant_body_page.dart index 7c56085..d45480f 100644 --- a/lib/pages/device/instant_body_page.dart +++ b/lib/pages/device/instant_body_page.dart @@ -91,10 +91,10 @@ class _InstantBodyPageState extends State void didChangeAppLifecycleState(AppLifecycleState state) { if (state == AppLifecycleState.resumed) { // 应用回到前台时重新连接WebSocket - edm.EasyDartModule.logger.info("app切回页面,重连websocket"); + edm.EasyDartModule.logger.info("app切回页面,重连websocket"); _initWebSocket(); } else if (state == AppLifecycleState.paused) { - // 应用进入后台时关闭WebSocket + // 应用进入后台时关闭WebSocket _closeWebSocket(); } } @@ -170,12 +170,12 @@ class _InstantBodyPageState extends State children: [ RichText( text: TextSpan( - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + letterSpacing: 0.0, + ), children: [ TextSpan( text: '实时体征.标题'.tr, @@ -655,29 +655,23 @@ class _InstantBodyPageState extends State children: [ Text( '实时体征.姓名'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '实时体征.年龄'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide( SizedBox(height: 34.rpx)), @@ -688,29 +682,23 @@ class _InstantBodyPageState extends State children: [ Text( '${device['person']?['name'] ?? '未命名'.tr}', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), Text( '${MyUtils.getAgeByDate(MyUtils.formatBirthdayTime(device['person']?['birthday'])) ?? '未知数据'.tr}', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide( SizedBox(height: 34.rpx)), @@ -739,29 +727,23 @@ class _InstantBodyPageState extends State children: [ Text( '实时体征.设备ID'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '实时体征.体重'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide( SizedBox(height: 34.rpx)), @@ -774,32 +756,26 @@ class _InstantBodyPageState extends State Text( '${device['code'] ?? '未知数据'.tr}', // "D11250300003", - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), Text( '${device['person']?['weight'] ?? '未知数据'.tr}kg', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide( SizedBox(height: 34.rpx)), @@ -915,15 +891,12 @@ class _InstantBodyPageState extends State bodyMotion >= maxBodyMotion ? '请保持静止'.tr : "", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc9, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc9, + ), ), ), ), @@ -975,14 +948,11 @@ class _InstantBodyPageState extends State Expanded( child: Text( '实时体征.提示'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ].divide(SizedBox(width: 23.rpx)), diff --git a/lib/pages/device/message_review_page.dart b/lib/pages/device/message_review_page.dart index 30d5496..a8ace63 100644 --- a/lib/pages/device/message_review_page.dart +++ b/lib/pages/device/message_review_page.dart @@ -118,27 +118,23 @@ class _MessageReviewPageState extends State { children: [ Text( '实时体征.姓名'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '实时体征.年龄'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -148,27 +144,23 @@ class _MessageReviewPageState extends State { children: [ Text( '${widget.data['person']?['name'] ?? '未命名'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), Text( '${MyUtils.getAgeByDate(MyUtils.formatBirthdayTime(widget.data['person']?['birthday'])) ?? '未知数据'.tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -194,27 +186,23 @@ class _MessageReviewPageState extends State { children: [ Text( '实时体征.设备ID'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '实时体征.体重'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -226,31 +214,25 @@ class _MessageReviewPageState extends State { Text( '${widget.data['code'] ?? '未知数据'.tr}', // "D11250300003", - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), Text( '${widget.data['person']?['weight'] ?? '未知数据'.tr}kg', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), diff --git a/lib/pages/device_bind/MobileScannerTestPage.dart b/lib/pages/device_bind/MobileScannerTestPage.dart index f6d4dbf..522c490 100644 --- a/lib/pages/device_bind/MobileScannerTestPage.dart +++ b/lib/pages/device_bind/MobileScannerTestPage.dart @@ -117,12 +117,12 @@ class _MobileScannerTestPageState extends State children: [ Text( '扫一扫.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, diff --git a/lib/pages/device_bind/after/after_device_calibration_person.dart b/lib/pages/device_bind/after/after_device_calibration_person.dart index 4954d54..7713fca 100644 --- a/lib/pages/device_bind/after/after_device_calibration_person.dart +++ b/lib/pages/device_bind/after/after_device_calibration_person.dart @@ -859,16 +859,14 @@ class _AfterCalibrationPersonPageState 0) { return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -878,16 +876,14 @@ class _AfterCalibrationPersonPageState .statusContext.value = ""; return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -895,16 +891,14 @@ class _AfterCalibrationPersonPageState 2) { return Text( '重新校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } return Container(); diff --git a/lib/pages/device_bind/after/after_update_person_page.dart b/lib/pages/device_bind/after/after_update_person_page.dart index c7efdda..30c7e61 100644 --- a/lib/pages/device_bind/after/after_update_person_page.dart +++ b/lib/pages/device_bind/after/after_update_person_page.dart @@ -82,12 +82,12 @@ class _AfterUpdatePersonPageState extends State { /// 居中标题 Text( '人员资料.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -135,13 +135,11 @@ class _AfterUpdatePersonPageState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '下一步'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -193,24 +191,18 @@ class _AfterUpdatePersonPageState extends State { decoration: InputDecoration( fillColor: Colors.transparent, isDense: true, - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), hintText: '人员资料.名字输入提示'.tr, - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -229,8 +221,6 @@ class _AfterUpdatePersonPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -238,8 +228,6 @@ class _AfterUpdatePersonPageState extends State { ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -247,14 +235,11 @@ class _AfterUpdatePersonPageState extends State { ), filled: true, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: - themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -309,21 +294,16 @@ class _AfterUpdatePersonPageState extends State { ), Text( '男'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: isMaleGreyed - ? themeController - .currentColor - .sc4 - : themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: isMaleGreyed + ? themeController + .currentColor.sc4 + : themeController + .currentColor.sc3, + ), ), ].divide( SizedBox(height: 14.rpx)), @@ -363,21 +343,16 @@ class _AfterUpdatePersonPageState extends State { ), Text( '女'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: isFemaleGreyed - ? themeController - .currentColor - .sc4 - : themeController - .currentColor - .sc3, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: isFemaleGreyed + ? themeController + .currentColor.sc4 + : themeController + .currentColor.sc3, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide( SizedBox(height: 14.rpx)), @@ -431,20 +406,15 @@ class _AfterUpdatePersonPageState extends State { personController.dateTime!) : '人员资料.生日输入提示'.tr, textAlign: TextAlign.right, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: personController.dateTime != - null - ? themeController - .currentColor.sc3 - : themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: personController.dateTime != null + ? themeController.currentColor.sc3 + : themeController.currentColor.sc4, + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0, + ), ), ), ), @@ -483,14 +453,11 @@ class _AfterUpdatePersonPageState extends State { }, autofocus: false, obscureText: false, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Colors.transparent, // 隐藏输入文字 - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.transparent, // 隐藏输入文字 + letterSpacing: 0.0, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -498,17 +465,14 @@ class _AfterUpdatePersonPageState extends State { fillColor: Colors.transparent, isDense: true, hintText: '身高输入提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -527,9 +491,6 @@ class _AfterUpdatePersonPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -538,9 +499,6 @@ class _AfterUpdatePersonPageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -558,16 +516,13 @@ class _AfterUpdatePersonPageState extends State { : Text( '${height}cm', textAlign: TextAlign.center, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + ), ); }), ], @@ -609,14 +564,11 @@ class _AfterUpdatePersonPageState extends State { }, autofocus: false, obscureText: false, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Colors.transparent, // 隐藏输入文字 - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.transparent, // 隐藏输入文字 + letterSpacing: 0.0, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -624,17 +576,14 @@ class _AfterUpdatePersonPageState extends State { fillColor: Colors.transparent, isDense: true, hintText: '人员资料.体重输入提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -653,9 +602,6 @@ class _AfterUpdatePersonPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -664,9 +610,6 @@ class _AfterUpdatePersonPageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -684,16 +627,13 @@ class _AfterUpdatePersonPageState extends State { : Text( '${weight}kg', textAlign: TextAlign.center, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + ), ); }), ], @@ -711,14 +651,12 @@ class _AfterUpdatePersonPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '人员资料.疾病标题'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Color(0xFFF3F4F5), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF3F4F5), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -780,31 +718,29 @@ class _AfterUpdatePersonPageState extends State { crossAxisAlignment: CrossAxisAlignment.start, children: [ Padding( - padding: EdgeInsetsDirectional.fromSTEB( - 0, 8.rpx, 0, 0), - child: Container( - width: 23.rpx, - height: 23.rpx, - // width: double.infinity, - decoration: BoxDecoration(), - child: SvgPicture.asset( - 'assets/img/icon/tips.svg', - fit: BoxFit.cover, - color: themeController.currentColor.sc4, - ), - ), + padding: EdgeInsetsDirectional.fromSTEB( + 0, 8.rpx, 0, 0), + child: Container( + width: 23.rpx, + height: 23.rpx, + // width: double.infinity, + decoration: BoxDecoration(), + child: SvgPicture.asset( + 'assets/img/icon/tips.svg', + fit: BoxFit.cover, + color: themeController.currentColor.sc4, ), + ), + ), Expanded( child: Text( '人员资料.提示'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController.currentColor.sc4, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc4, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ].divide(SizedBox(width: 23.rpx)), @@ -850,12 +786,12 @@ class _AfterUpdatePersonPageState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFC2CED7), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFC2CED7), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/device_bind/after/after_wifi_page_person.dart b/lib/pages/device_bind/after/after_wifi_page_person.dart index dad2d5e..a127709 100644 --- a/lib/pages/device_bind/after/after_wifi_page_person.dart +++ b/lib/pages/device_bind/after/after_wifi_page_person.dart @@ -99,13 +99,12 @@ class _AfterWifiPagePersonState extends State { children: [ Text( 'wifi页.标题'.tr, - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), SizedBox( width: 14.rpx, @@ -182,13 +181,11 @@ class _AfterWifiPagePersonState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '下一步'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -322,15 +319,13 @@ class _AfterWifiPagePersonState extends State { children: [ Text( '可用WLAN'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: + themeController.currentColor.sc3, + ), ), ], ), @@ -396,21 +391,19 @@ class _AfterWifiPagePersonState extends State { InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Inter', - fontSize: - 26.rpx, - letterSpacing: - 0.0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Inter', + fontSize: + 26.rpx, + letterSpacing: + 0.0, + ), hintText: '蓝牙绑定.输入wifi密码' .tr, - hintStyle: FlutterFlowTheme.of(context).labelMedium.override( + hintStyle: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -450,8 +443,6 @@ class _AfterWifiPagePersonState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -463,8 +454,6 @@ class _AfterWifiPagePersonState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -474,9 +463,9 @@ class _AfterWifiPagePersonState extends State { ), filled: false, - fillColor: FlutterFlowTheme.of( - context) - .secondaryBackground, + // fillColor: FlutterFlowTheme.of( + // context) + // .secondaryBackground, suffixIcon: InkWell( onTap: @@ -500,7 +489,7 @@ class _AfterWifiPagePersonState extends State { ), ), ), - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -631,18 +620,13 @@ class _AfterWifiPagePersonState extends State { children: [ Text( wifiItem['ssid'] ?? '', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: - themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), if (blueteethBindController .selectWifi.value == @@ -768,15 +752,13 @@ class _AfterWifiPagePersonState extends State { ), Text( '刷新'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(width: 26.rpx)), ), diff --git a/lib/pages/device_bind/bind_device_success.dart b/lib/pages/device_bind/bind_device_success.dart index f9d26d7..74b48f4 100644 --- a/lib/pages/device_bind/bind_device_success.dart +++ b/lib/pages/device_bind/bind_device_success.dart @@ -64,12 +64,12 @@ class _EPageState extends State { /// 居中标题 Text( '绑定成功.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -164,14 +164,12 @@ class _EPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '绑定成功.绑定成功'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -185,14 +183,12 @@ class _EPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '绑定成功.分享标题'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -206,14 +202,12 @@ class _EPageState extends State { alignment: AlignmentDirectional(-1, 0), child: Text( '绑定成功.分享内容'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -276,15 +270,13 @@ class _EPageState extends State { ), Text( '绑定成功.立即分享'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -347,15 +339,13 @@ class _EPageState extends State { children: [ Text( '绑定成功.返回'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), diff --git a/lib/pages/device_bind/blueteeth_device_page.dart b/lib/pages/device_bind/blueteeth_device_page.dart index 762fe63..12a04df 100644 --- a/lib/pages/device_bind/blueteeth_device_page.dart +++ b/lib/pages/device_bind/blueteeth_device_page.dart @@ -294,12 +294,12 @@ class _BlueteethDevicePageState extends State { children: [ Text( '蓝牙绑定.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -333,14 +333,12 @@ class _BlueteethDevicePageState extends State { 0, 30.rpx, 0, 30.rpx), child: Text( '蓝牙绑定.扫描'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Color(0xFFE8EEF3), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFE8EEF3), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -360,21 +358,18 @@ class _BlueteethDevicePageState extends State { children: [ Text( '最小信号强度'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Color(0xFFEEF2F5), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: stringToColor("#003058"), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Expanded( child: Obx(() { return Slider( activeColor: Color(0xFF1FCC9B), - inactiveColor: - FlutterFlowTheme.of(context).alternate, + inactiveColor: Colors.white, min: -100, max: 50, value: blueteethBindController.model.singal!, @@ -392,14 +387,12 @@ class _BlueteethDevicePageState extends State { Obx(() { return Text( '${blueteethBindController.model.singal!.toInt()}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Color(0xFFE4E8EB), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFE4E8EB), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ); }), ].divide(SizedBox(width: 30.rpx)), @@ -443,8 +436,7 @@ class _BlueteethDevicePageState extends State { width: 100.rpx, height: 80.rpx, decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, + color: Colors.white, ), child: Align( alignment: AlignmentDirectional(-1, 0), @@ -459,23 +451,17 @@ class _BlueteethDevicePageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '蓝牙绑定.搜索提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -494,9 +480,7 @@ class _BlueteethDevicePageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, + color: Colors.white, width: 1.rpx, ), borderRadius: @@ -505,9 +489,7 @@ class _BlueteethDevicePageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, + color: Colors.white, width: 1.rpx, ), borderRadius: @@ -517,13 +499,11 @@ class _BlueteethDevicePageState extends State { fillColor: themeController .currentColor.sc22, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), cursorColor: themeController.currentColor.sc3, ), @@ -590,15 +570,12 @@ class _BlueteethDevicePageState extends State { child: Text( '搜索'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: - stringToColor("#333333"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: stringToColor("#333333"), //固定 + ), ), ), ].divide(SizedBox(width: 26.rpx)), @@ -623,14 +600,12 @@ class _BlueteethDevicePageState extends State { // "(${blueteethBindController.model.betDevicelist!.length})", '匹配出的外围设备'.tr + "(${blueteethBindController.model.betDevicelist!.length})", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ); }), ), diff --git a/lib/pages/device_bind/componnet/DeviceShareInfoWidget.dart b/lib/pages/device_bind/componnet/DeviceShareInfoWidget.dart index 6a4b37e..da70bba 100644 --- a/lib/pages/device_bind/componnet/DeviceShareInfoWidget.dart +++ b/lib/pages/device_bind/componnet/DeviceShareInfoWidget.dart @@ -125,10 +125,10 @@ class _DeviceShareInfoWidgetState extends State { }, side: BorderSide( width: 1.5, - color: FlutterFlowTheme.of(context).secondaryText, + color: Colors.white, ), activeColor: stringToColor("#16C89F"), - checkColor: FlutterFlowTheme.of(context).info, + checkColor: Colors.white, ), ); }), @@ -161,14 +161,12 @@ class _DeviceShareInfoWidgetState extends State { alignment: AlignmentDirectional(-1, 0), child: Text( "${item['k']}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), @@ -176,14 +174,12 @@ class _DeviceShareInfoWidgetState extends State { ), Text( "${item['v']}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), diff --git a/lib/pages/device_bind/componnet/DoubleBlueteethDeviceCompoentWidget.dart b/lib/pages/device_bind/componnet/DoubleBlueteethDeviceCompoentWidget.dart index 6a3125d..ce431f0 100644 --- a/lib/pages/device_bind/componnet/DoubleBlueteethDeviceCompoentWidget.dart +++ b/lib/pages/device_bind/componnet/DoubleBlueteethDeviceCompoentWidget.dart @@ -1,4 +1,3 @@ -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:flutter/material.dart'; import 'package:flutterflow_ui/flutterflow_ui.dart'; import 'package:vbvs_app/common/util/FitTool.dart'; @@ -20,7 +19,6 @@ class DoubleBlueteethDeviceCompoentWidget extends StatefulWidget { _DoubleBlueteethDeviceCompoentWidgetState(); } - class _DoubleBlueteethDeviceCompoentWidgetState extends State { @override @@ -57,12 +55,12 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( 'AITH-V3', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), Container( @@ -73,21 +71,21 @@ class _DoubleBlueteethDeviceCompoentWidgetState children: [ Text( '信号强度:-36dBm', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( 'SN:12', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF5F9FD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF5F9FD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 40.rpx)), ), @@ -97,12 +95,12 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( '蓝牙地址:48:CA:43:B1:B3:B2', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), Container( @@ -110,12 +108,12 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( 'mac:48CA43B1B3B0', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), Container( @@ -126,33 +124,33 @@ class _DoubleBlueteethDeviceCompoentWidgetState children: [ Text( '网络:在线', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Row( mainAxisSize: MainAxisSize.max, children: [ Text( '传感器:', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( '可绑定', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFF1AD2B5), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFF1AD2B5), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), @@ -164,29 +162,29 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( '版本:02409.0301', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), Divider( thickness: 2.rpx, - color: FlutterFlowTheme.of(context).alternate, + color: Colors.white, ), Container( width: double.infinity, decoration: BoxDecoration(), child: Text( 'AITH-V3', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), Container( @@ -197,21 +195,21 @@ class _DoubleBlueteethDeviceCompoentWidgetState children: [ Text( '信号强度:-36dBm', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( 'SN:12', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF5F9FD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF5F9FD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 40.rpx)), ), @@ -221,12 +219,12 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( '蓝牙地址:48:CA:43:B1:B3:B2', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), Container( @@ -234,12 +232,12 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( 'mac:48CA43B1B3B0', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), Container( @@ -250,33 +248,33 @@ class _DoubleBlueteethDeviceCompoentWidgetState children: [ Text( '网络:在线', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Row( mainAxisSize: MainAxisSize.max, children: [ Text( '传感器:', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( '可绑定', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFF1AD2B5), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFF1AD2B5), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), @@ -288,18 +286,17 @@ class _DoubleBlueteethDeviceCompoentWidgetState decoration: BoxDecoration(), child: Text( '版本:02409.0301', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ].divide(SizedBox(height: 37.rpx)), ), ), ); - } } diff --git a/lib/pages/device_bind/componnet/MessageSetting.dart b/lib/pages/device_bind/componnet/MessageSetting.dart new file mode 100644 index 0000000..882505a --- /dev/null +++ b/lib/pages/device_bind/componnet/MessageSetting.dart @@ -0,0 +1,575 @@ +import 'dart:async'; + +import 'package:ef/ef.dart'; +import 'package:flutter/material.dart'; +import 'package:flutterflow_ui/flutterflow_ui.dart'; +import 'package:vbvs_app/common/color/ServiceConstant.dart'; +import 'package:vbvs_app/common/color/appConstants.dart'; +import 'package:vbvs_app/common/util/FitTool.dart'; +import 'package:vbvs_app/common/util/MyUtils.dart'; +import 'package:vbvs_app/common/util/requestWithLog.dart'; +import 'package:vbvs_app/component/base/GradientSwitch.dart'; +import 'package:vbvs_app/component/tool/TopSlideNotification.dart'; +import 'package:vbvs_app/controller/message/common_message_setting_controller.dart'; +import 'package:vbvs_app/controller/message/message_setting_controller.dart'; +import 'package:vbvs_app/controller/theme_controller/ThemeController.dart'; + +class MessageSettingPage extends StatefulWidget { + var data; + MessageSettingPage({super.key, required this.data}); + + @override + State createState() => _MessageSettingPageState(); +} + +class _MessageSettingPageState extends State { + final ThemeController themeController = Get.find(); + MessageSettingController messageSettingController = Get.find(); + CommonMessageSettingController commonMessageSettingController = Get.find(); + + @override + void initState() { + super.initState(); + _fetchCommonMessageSetting(); + _fetchDeviceMessageSetting(); + } + + Future _fetchCommonMessageSetting() async { + String serviceAddress = ServiceConstant.service_address; + String serviceName = ServiceConstant.server_service; + String serviceApi = ServiceConstant.user_setting; + String type = "user_message_setting"; + String queryUrl = "${serviceAddress}${serviceName}${serviceApi}?type=$type"; + requestWithLog( + logTitle: "查询用户消息配置", + method: MyHttpMethod.get, + queryUrl: queryUrl, + onSuccess: (res) { + if (res.data == null || res.data.isEmpty) { + var data = { + "type": type, + "setting": 1, + "appSetting": 1, + "serviceSetting": 1, + "tipSetting": 1, + "deviceUpgradeSetting": 1, + "deviceIssueSetting": 1, + }; + requestWithLog( + logTitle: "更新用户消息配置", + method: MyHttpMethod.put, + queryUrl: queryUrl, + data: data, + onSuccess: (res) { + requestWithLog( + logTitle: "查询用户消息配置", + method: MyHttpMethod.get, + queryUrl: queryUrl, + onSuccess: (res) { + if (res.data != null && res.data.isNotEmpty) { + var datalist = res.data; + commonMessageSettingController.model.setting = + datalist['setting']; + commonMessageSettingController.model.appSetting = + datalist['appSetting']; + commonMessageSettingController.model.serviceSetting = + datalist['serviceSetting']; + commonMessageSettingController.model.tipSetting = + datalist['tipSetting']; + commonMessageSettingController.model.deviceUpgradeSetting = + datalist['deviceUpgradeSetting']; + commonMessageSettingController.model.deviceIssueSetting = + datalist['deviceIssueSetting']; + commonMessageSettingController.updateAll(); + } + }, + ); + + // + }, + ); + } else { + var datalist = res.data; + commonMessageSettingController.model.setting = datalist['setting']; + commonMessageSettingController.model.appSetting = + datalist['appSetting']; + commonMessageSettingController.model.serviceSetting = + datalist['serviceSetting']; + commonMessageSettingController.model.tipSetting = + datalist['tipSetting']; + commonMessageSettingController.model.deviceUpgradeSetting = + datalist['deviceUpgradeSetting']; + commonMessageSettingController.model.deviceIssueSetting = + datalist['deviceIssueSetting']; + commonMessageSettingController.updateAll(); + } + }, + onFailure: (res) { + print(res); + }, + ); + } + + Future _fetchDeviceMessageSetting() async { + String serviceAddress = ServiceConstant.service_address; + String serviceName = ServiceConstant.server_service; + String serviceApi = ServiceConstant.user_setting; + String mac = widget.data['mac']; + String type = "user_device_message_setting_$mac"; + String queryUrl = "${serviceAddress}${serviceName}${serviceApi}?type=$type"; + requestWithLog( + logTitle: "查询用户消息配置", + method: MyHttpMethod.get, + queryUrl: queryUrl, + onSuccess: (res) { + if (res.data == null || res.data.isEmpty) { + var data = { + "type": type, + "setting": 1, + "appSetting": 1, + "serviceSetting": 1, + }; + requestWithLog( + logTitle: "更新用户消息配置", + method: MyHttpMethod.put, + queryUrl: queryUrl, + data: data, + onSuccess: (res) { + requestWithLog( + logTitle: "查询用户消息配置", + method: MyHttpMethod.get, + queryUrl: queryUrl, + onSuccess: (res) { + if (res.data != null && res.data.isNotEmpty) { + var datalist = res.data; + messageSettingController.model.setting = + datalist['setting']; + messageSettingController.model.appSetting = + datalist['appSetting']; + messageSettingController.model.serviceSetting = + datalist['serviceSetting']; + messageSettingController.updateAll(); + } + }, + ); + + // + }, + ); + } else { + var datalist = res.data; + messageSettingController.model.setting = datalist['setting']; + messageSettingController.model.appSetting = datalist['appSetting']; + messageSettingController.model.serviceSetting = + datalist['serviceSetting']; + messageSettingController.updateAll(); + } + }, + onFailure: (res) { + print(res); + }, + ); + + } + + @override + void dispose() { + super.dispose(); + } + + @override + Widget build(BuildContext context) { + return LayoutBuilder( + builder: (context, bodysize) => GestureDetector( + onTap: () => FocusScope.of(context).unfocus(), + child: Container( + decoration: BoxDecoration( + image: DecorationImage( + image: AssetImage('assets/img/bgNoImg.png'), + fit: BoxFit.fill, + ), + ), + child: Scaffold( + backgroundColor: Colors.transparent, + appBar: AppBar( + backgroundColor: themeController.currentColor.sc17, + automaticallyImplyLeading: false, + iconTheme: IconThemeData( + color: themeController.currentColor.sc3, + ), + titleSpacing: 0, + title: Container( + width: double.infinity, + height: 180.rpx, + child: Stack( + alignment: Alignment.center, + children: [ + /// 居中标题 + Text( + '消息设置'.tr, + style: TextStyle( + fontFamily: 'ReadexPro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), + ), + Positioned( + left: 0, + child: returnIconButtomAddCallback(() {}), + ), + ], + ), + ), + actions: [], + centerTitle: false, + ), + body: GestureDetector( + child: SafeArea( + top: true, + child: Padding( + padding: EdgeInsetsDirectional.fromSTEB(0.rpx, 0, 0.rpx, 0), + child: Column( + mainAxisSize: MainAxisSize.min, + children: [ + Padding( + padding: + EdgeInsetsDirectional.fromSTEB(0, 30.rpx, 0, 0), + child: Container( + width: double.infinity, + constraints: BoxConstraints( + minHeight: 90.rpx, + ), + decoration: BoxDecoration( + color: themeController.currentColor.sc5), + child: Padding( + padding: EdgeInsetsDirectional.fromSTEB( + 30.rpx, 15.rpx, 30.rpx, 15.rpx), + child: Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: Text( + "消息提醒设置".tr, + style: TextStyle( + color: themeController.currentColor.sc3, + fontSize: + AppConstants().title_text_fontSize), + ), + ), + Obx(() { + return GradientSwitch( + value: commonMessageSettingController + .model.setting == + 1 + ? (messageSettingController + .model.setting == + 1 + ? true + : false) + : false, + onChanged: (val) { + if (commonMessageSettingController + .model.setting == + 0) { + TopSlideNotification.show(context, + text: "请先在设置里的消息通知打开全部消息配置".tr, + textColor: themeController + .currentColor.sc9); + return; + } + String serviceAddress = + ServiceConstant.service_address; + String serviceName = + ServiceConstant.server_service; + String serviceApi = + ServiceConstant.user_setting; + String mac = widget.data['mac']; + String type = + "user_device_message_setting_$mac"; + String queryUrl = + "${serviceAddress}${serviceName}${serviceApi}"; + var data = { + "type": type, + "setting": val == true ? 1 : 0, + "appSetting": messageSettingController + .model.appSetting, + "serviceSetting": + messageSettingController + .model.serviceSetting, + }; + requestWithLog( + logTitle: "更新消息推送状态", + method: MyHttpMethod.put, + queryUrl: queryUrl, + data: data, + onSuccess: (res) { + _fetchDeviceMessageSetting(); + messageSettingController + .updateAll(); + }); + }, + activeGradient: LinearGradient( + colors: [ + themeController.currentColor.sc1, + themeController.currentColor.sc2 + ], + ), + activeThumbColor: Colors.white, + inactiveThumbColor: + stringToColor("#A2A4A9"), + inactiveColor: stringToColor("#161B28"), + ); + }), + ], + ), + ), + ), + ), + Padding( + padding: EdgeInsetsDirectional.fromSTEB( + 30.rpx, 21.rpx, 30.rpx, 0), + child: Container( + decoration: BoxDecoration( + color: themeController.currentColor.sc5, + borderRadius: BorderRadius.circular( + AppConstants().normal_container_radius), + ), + child: Padding( + padding: EdgeInsetsDirectional.fromSTEB( + 30.rpx, 40.rpx, 30.rpx, 54.rpx), + child: Container( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: Text( + "APP消息".tr, + style: TextStyle( + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize), + ), + ), + Obx(() { + return GradientSwitch( + value: commonMessageSettingController + .model.setting == + 1 + ? (messageSettingController + .model.setting == + 1 + ? (messageSettingController + .model + .appSetting == + 1 + ? true + : false) + : false) + : false, + onChanged: (val) { + if (commonMessageSettingController + .model.setting == + 0) { + TopSlideNotification.show(context, + text: + "请先在设置里的消息通知打开全部消息配置".tr, + textColor: themeController + .currentColor.sc9); + return; + } + if (messageSettingController + .model.setting == + 0) { + TopSlideNotification.show(context, + text: "请先打开消息提醒设置".tr, + textColor: themeController + .currentColor.sc9); + return; + } + String serviceAddress = + ServiceConstant.service_address; + String serviceName = + ServiceConstant.server_service; + String serviceApi = + ServiceConstant.user_setting; + String mac = widget.data['mac']; + String type = + "user_device_message_setting_$mac"; + String queryUrl = + "${serviceAddress}${serviceName}${serviceApi}"; + var data = { + "type": type, + "setting": + messageSettingController + .model.setting, + "appSetting": val == true ? 1 : 0, + "serviceSetting": + messageSettingController + .model.serviceSetting, + }; + requestWithLog( + logTitle: "更新消息推送状态", + method: MyHttpMethod.put, + queryUrl: queryUrl, + data: data, + onSuccess: (res) { + _fetchDeviceMessageSetting(); + messageSettingController + .updateAll(); + }); + }, + activeGradient: LinearGradient( + colors: [ + themeController.currentColor.sc1, + themeController.currentColor.sc2 + ], + ), + activeThumbColor: Colors.white, + inactiveThumbColor: + stringToColor("#A2A4A9"), + inactiveColor: + stringToColor("#161B28"), + ); + }), + ], + ), + Text( + "APP消息介绍".tr, + style: TextStyle( + color: themeController.currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize), + ), + Row( + mainAxisSize: MainAxisSize.max, + mainAxisAlignment: + MainAxisAlignment.spaceBetween, + children: [ + Expanded( + child: Text( + "服务号消息".tr, + style: TextStyle( + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize), + ), + ), + Obx(() { + return GradientSwitch( + value: commonMessageSettingController + .model.setting == + 1 + ? (messageSettingController + .model.setting == + 1 + ? (messageSettingController + .model + .serviceSetting == + 1 + ? true + : false) + : false) + : false, + onChanged: (val) { + if (commonMessageSettingController + .model.setting == + 0) { + TopSlideNotification.show(context, + text: + "请先在设置里的消息通知打开全部消息配置".tr, + textColor: themeController + .currentColor.sc9); + return; + } + if (messageSettingController + .model.setting == + 0) { + TopSlideNotification.show(context, + text: "请先打开消息提醒设置".tr, + textColor: themeController + .currentColor.sc9); + return; + } + String serviceAddress = + ServiceConstant.service_address; + String serviceName = + ServiceConstant.server_service; + String serviceApi = + ServiceConstant.user_setting; + String mac = widget.data['mac']; + String type = + "user_device_message_setting_$mac"; + String queryUrl = + "${serviceAddress}${serviceName}${serviceApi}"; + var data = { + "type": type, + "setting": + messageSettingController + .model.setting, + "appSetting": + messageSettingController + .model.appSetting, + "serviceSetting": + val == true ? 1 : 0, + }; + requestWithLog( + logTitle: "更新消息推送状态", + method: MyHttpMethod.put, + queryUrl: queryUrl, + data: data, + onSuccess: (res) { + _fetchDeviceMessageSetting(); + messageSettingController + .updateAll(); + }); + }, + activeGradient: LinearGradient( + colors: [ + themeController.currentColor.sc1, + themeController.currentColor.sc2 + ], + ), + activeThumbColor: Colors.white, + inactiveThumbColor: + stringToColor("#A2A4A9"), + inactiveColor: + stringToColor("#161B28"), + ); + }), + ], + ), + Text( + "服务号消息介绍".tr, + style: TextStyle( + color: themeController.currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize), + ), + ].divide(SizedBox( + height: 49.rpx, + )), + ), + ), + ), + ), + ), + ], + ), + ), + ), + ), + ), + ), + ), + ); + } +} diff --git a/lib/pages/device_bind/componnet/SingleBlueteethDeviceCompoentWidget.dart b/lib/pages/device_bind/componnet/SingleBlueteethDeviceCompoentWidget.dart index 52592fb..f476ec0 100644 --- a/lib/pages/device_bind/componnet/SingleBlueteethDeviceCompoentWidget.dart +++ b/lib/pages/device_bind/componnet/SingleBlueteethDeviceCompoentWidget.dart @@ -110,7 +110,6 @@ class _SingleBlueteethDeviceCompoentWidgetState } }, onCancel: () { - print('用户点击了取消'); blueteethBindController.currentDeviceMac.value = ""; blueteethBindController.updateAll(); @@ -140,12 +139,12 @@ class _SingleBlueteethDeviceCompoentWidgetState children: [ Text( device.name ?? '蓝牙绑定.默认设备名称'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), Obx(() { if (blueteethBindController.currentDeviceMac.value == @@ -169,77 +168,77 @@ class _SingleBlueteethDeviceCompoentWidgetState children: [ Text( "蓝牙绑定.信号强度".tr + ':${device.rssi ?? '-'}dBm', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SizedBox(width: 40.rpx), Text( "蓝牙绑定.SN".tr + ':${device.sn ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF5F9FD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF5F9FD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), Text( "蓝牙绑定.蓝牙地址".tr + ':${device.deviceId ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( "蓝牙绑定.mac".tr + ':${device.mac ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Row( children: [ Text( "蓝牙绑定.网络".tr + ':${device.isOnline == true ? '蓝牙绑定.在线'.tr : '蓝牙绑定.离线'.tr}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SizedBox(width: 145.rpx), Row( children: [ Text( "蓝牙绑定.传感器".tr + ":", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( device.bind == false ? '蓝牙绑定.可绑定'.tr : '蓝牙绑定.已被绑定'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: device.bind == false - ? const Color(0xFF1AD2B5) - : themeController.currentColor.sc9, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: device.bind == false + ? const Color(0xFF1AD2B5) + : themeController.currentColor.sc9, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), @@ -247,12 +246,12 @@ class _SingleBlueteethDeviceCompoentWidgetState ), Text( "版本".tr + '${device.version ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(height: 37.rpx)), ), @@ -292,7 +291,7 @@ class _SingleBlueteethDeviceCompoentWidgetState return; } else {} } - TopSlideNotification.show(context,text: "双人版绑定修复中"); + TopSlideNotification.show(context, text: "双人版绑定修复中"); print('选中了设备索引:$selectedIndex'); //配置wifi }, @@ -354,12 +353,12 @@ class _SingleBlueteethDeviceCompoentWidgetState children: [ Text( device.name ?? '蓝牙绑定.默认设备名称'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), Obx(() { if (blueteethBindController.currentDeviceMac.value == @@ -382,77 +381,77 @@ class _SingleBlueteethDeviceCompoentWidgetState children: [ Text( "蓝牙绑定.信号强度".tr + ':${device.rssi ?? '-'}dBm', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SizedBox(width: 40.rpx), Text( "蓝牙绑定.SN".tr + ':${device.sn ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF5F9FD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF5F9FD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), Text( "蓝牙绑定.蓝牙地址".tr + ':${device.deviceId ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( "蓝牙绑定.mac".tr + ':${device.mac ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Row( children: [ Text( "蓝牙绑定.网络".tr + ':${device.isOnline == true ? '蓝牙绑定.在线'.tr : '蓝牙绑定.离线'.tr}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SizedBox(width: 145.rpx), Row( children: [ Text( "蓝牙绑定.传感器".tr + ":", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( device.bind == false ? '蓝牙绑定.可绑定'.tr : '蓝牙绑定.已被绑定'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: device.bind == false - ? const Color(0xFF1AD2B5) - : themeController.currentColor.sc9, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: device.bind == false + ? const Color(0xFF1AD2B5) + : themeController.currentColor.sc9, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), @@ -460,12 +459,12 @@ class _SingleBlueteethDeviceCompoentWidgetState ), Text( "版本".tr + '${device.version ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( height: 37.rpx, diff --git a/lib/pages/device_bind/componnet/bind_dialog.dart b/lib/pages/device_bind/componnet/bind_dialog.dart index 75721dc..eb7856e 100644 --- a/lib/pages/device_bind/componnet/bind_dialog.dart +++ b/lib/pages/device_bind/componnet/bind_dialog.dart @@ -53,15 +53,16 @@ void showBindDoubleDialog( Align( alignment: AlignmentDirectional(0, 0), child: Padding( - padding: EdgeInsetsDirectional.fromSTEB(0.rpx, 93.rpx, 0, 0), + padding: + EdgeInsetsDirectional.fromSTEB(0.rpx, 93.rpx, 0, 0), child: Text( '蓝牙绑定.双人版绑定标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -114,16 +115,20 @@ void showBindDoubleDialog( // 确定按钮 Padding( - padding: EdgeInsetsDirectional.fromSTEB(60.rpx, 100.rpx, 60.rpx, 0), + padding: EdgeInsetsDirectional.fromSTEB( + 60.rpx, 100.rpx, 60.rpx, 0), child: _buildActionButton( context, text: '蓝牙绑定.确定'.tr, onTap: () { Get.back(); - int selectedIndex = blueteethBindController.model.deviceIndex0! - ? 0 - : (blueteethBindController.model.deviceIndex1! ? 1 : 2); + int selectedIndex = + blueteethBindController.model.deviceIndex0! + ? 0 + : (blueteethBindController.model.deviceIndex1! + ? 1 + : 2); onConfirm(selectedIndex); }, @@ -131,7 +136,8 @@ void showBindDoubleDialog( ), // 取消按钮 Padding( - padding: EdgeInsetsDirectional.fromSTEB(60.rpx, 19.rpx, 60.rpx, 60.rpx), + padding: EdgeInsetsDirectional.fromSTEB( + 60.rpx, 19.rpx, 60.rpx, 60.rpx), child: _buildActionButton( context, text: '蓝牙绑定.取消'.tr, @@ -150,7 +156,6 @@ void showBindDoubleDialog( ); } - Future showHaveBindDialog(BuildContext context) async { ThemeController themeController = Get.find(); @@ -182,12 +187,12 @@ Future showHaveBindDialog(BuildContext context) async { 0.rpx, 93.rpx, 0.rpx, 0.rpx), child: Text( '蓝牙绑定.无法绑定'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -244,14 +249,12 @@ Future showHaveBindDialog(BuildContext context) async { children: [ Text( '蓝牙绑定.知道了'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -299,7 +302,7 @@ void showLoadingDialog(BuildContext context, {String? title}) { // 0.rpx, 93.rpx, 0.rpx, 0.rpx), // child: Text( // '蓝牙绑定.无法绑定'.tr, - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Inter', // fontSize: 30.rpx, // letterSpacing: 0.0, @@ -382,12 +385,12 @@ Widget _buildCheckboxRow( children: [ TextSpan( text: mainText, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: AppConstants().normal_text_fontSize, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: AppConstants().normal_text_fontSize, + color: themeController.currentColor.sc3, + ), ), if (isBindable) TextSpan( @@ -453,12 +456,12 @@ Widget _buildActionButton( children: [ Text( text, - style: FlutterFlowTheme.of(context).bodyMedium.override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -534,12 +537,12 @@ void showConfirmDialog( 33.rpx, 60.rpx, 33.rpx, 33.rpx), child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -577,15 +580,13 @@ void showConfirmDialog( children: [ Text( "蓝牙绑定.否".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -615,15 +616,13 @@ void showConfirmDialog( children: [ Text( "蓝牙绑定.是".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -713,12 +712,12 @@ void showSingleConfirmDialog( 33.rpx, 60.rpx, 33.rpx, 33.rpx), child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -757,15 +756,12 @@ void showSingleConfirmDialog( children: [ Text( confirmText, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -848,12 +844,12 @@ void showWifiDialog( EdgeInsetsDirectional.fromSTEB(0.rpx, 40.rpx, 0, 0), child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -895,15 +891,12 @@ void showWifiDialog( children: [ Text( "蓝牙绑定.连接".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -984,14 +977,12 @@ Future showTipDialog( children: [ Text( '蓝牙绑定.知道了'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1073,14 +1064,12 @@ Future showUnBindTipDialog( children: [ Text( '继续'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1119,14 +1108,12 @@ Future showUnBindTipDialog( children: [ Text( '下次再说'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), diff --git a/lib/pages/device_bind/device_calibration.dart b/lib/pages/device_bind/device_calibration.dart index 3621391..39c5b34 100644 --- a/lib/pages/device_bind/device_calibration.dart +++ b/lib/pages/device_bind/device_calibration.dart @@ -768,16 +768,14 @@ class _CalibrationPageState extends State { 0) { return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -787,16 +785,14 @@ class _CalibrationPageState extends State { .statusContext.value = ""; return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -804,16 +800,14 @@ class _CalibrationPageState extends State { 2) { return Text( '重新校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } return Container(); diff --git a/lib/pages/device_bind/device_calibration_copy.dart b/lib/pages/device_bind/device_calibration_copy.dart index 5dcd812..342f41a 100644 --- a/lib/pages/device_bind/device_calibration_copy.dart +++ b/lib/pages/device_bind/device_calibration_copy.dart @@ -875,17 +875,14 @@ class _CalibrationPageState extends State { children: [ Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - //todo 颜色 - color: - themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + //todo 颜色 + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, diff --git a/lib/pages/device_bind/device_calibration_person.dart b/lib/pages/device_bind/device_calibration_person.dart index 3520e6b..4f73dea 100644 --- a/lib/pages/device_bind/device_calibration_person.dart +++ b/lib/pages/device_bind/device_calibration_person.dart @@ -770,16 +770,14 @@ class _CalibrationPersonPageState extends State { 0) { return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -789,16 +787,14 @@ class _CalibrationPersonPageState extends State { .statusContext.value = ""; return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -806,16 +802,14 @@ class _CalibrationPersonPageState extends State { 2) { return Text( '重新校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } return Container(); @@ -1058,7 +1052,6 @@ class _CalibrationPersonPageState extends State { ); }, onFailure: (res) {}, - ); } } diff --git a/lib/pages/device_bind/device_share_list_page.dart b/lib/pages/device_bind/device_share_list_page.dart index bea6a2d..be6a2b3 100644 --- a/lib/pages/device_bind/device_share_list_page.dart +++ b/lib/pages/device_bind/device_share_list_page.dart @@ -69,12 +69,12 @@ class _DeviceShareListPageState extends State { children: [ Text( '已分享'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -133,8 +133,7 @@ class _DeviceShareListPageState extends State { width: 100.rpx, height: 80.rpx, decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, + color: Colors.white, ), child: Align( alignment: AlignmentDirectional(-1, 0), @@ -147,23 +146,17 @@ class _DeviceShareListPageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '输入关键字'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -183,8 +176,7 @@ class _DeviceShareListPageState extends State { errorBorder: OutlineInputBorder( borderSide: BorderSide( color: - FlutterFlowTheme.of(context) - .error, + Colors.white, width: 1.rpx, ), borderRadius: @@ -194,8 +186,7 @@ class _DeviceShareListPageState extends State { OutlineInputBorder( borderSide: BorderSide( color: - FlutterFlowTheme.of(context) - .error, + Colors.white, width: 1.rpx, ), borderRadius: @@ -205,13 +196,11 @@ class _DeviceShareListPageState extends State { fillColor: themeController .currentColor.sc22, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), cursorColor: themeController.currentColor.sc3, ), @@ -271,15 +260,12 @@ class _DeviceShareListPageState extends State { .withOpacity(0.08), // 可选点击反馈色 child: Text( '搜索'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: - stringToColor("#333333"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: stringToColor("#333333"), //固定 + ), ), ), ].divide(SizedBox(width: 26.rpx)), @@ -369,12 +355,11 @@ class _DeviceShareListPageState extends State { }, side: BorderSide( width: 1.5, - color: FlutterFlowTheme.of(context) - .secondaryText, + color: Colors.white, ), activeColor: stringToColor("#16C89F"), - checkColor: - FlutterFlowTheme.of(context).info, + // checkColor: + // FlutterFlowTheme.of(context).info, ), )), Text( diff --git a/lib/pages/device_bind/device_share_page.dart b/lib/pages/device_bind/device_share_page.dart index b025764..d99125f 100644 --- a/lib/pages/device_bind/device_share_page.dart +++ b/lib/pages/device_bind/device_share_page.dart @@ -62,12 +62,12 @@ class _DeviceSharePageState extends State { children: [ Text( '设备分享'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -94,14 +94,12 @@ class _DeviceSharePageState extends State { width: double.infinity, child: Text( '要分享的设备'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -132,15 +130,12 @@ class _DeviceSharePageState extends State { Text( '主设备'.tr + "${device['person']?['name'] == null ? '未命名'.tr : device['person']['name']}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: - themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ].divide(SizedBox(width: 20.rpx)), ), @@ -202,21 +197,17 @@ class _DeviceSharePageState extends State { decoration: InputDecoration( fillColor: Colors.transparent, isDense: true, - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), hintText: '请输入对方手机号或邮箱'.tr, - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -233,27 +224,23 @@ class _DeviceSharePageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), filled: true, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, // validator: _model.textController1Validator @@ -281,33 +268,29 @@ class _DeviceSharePageState extends State { TextSpan( text: '${deviceShareController.code.value == 1 ? "邀请成功".tr : "邀请失败".tr}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: deviceShareController - .code.value == - 1 - ? themeController - .currentColor.sc2 - : themeController - .currentColor.sc9, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: deviceShareController + .code.value == + 1 + ? themeController + .currentColor.sc2 + : themeController + .currentColor.sc9, + ), ), TextSpan( text: '${deviceShareController.msg}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc9, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc9, + ), ), ], ), @@ -354,15 +337,13 @@ class _DeviceSharePageState extends State { children: [ Text( '发送邀请'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), diff --git a/lib/pages/device_bind/device_type.dart b/lib/pages/device_bind/device_type.dart index 8abfaa8..4a48436 100644 --- a/lib/pages/device_bind/device_type.dart +++ b/lib/pages/device_bind/device_type.dart @@ -111,33 +111,26 @@ class _EPageState extends State { children: [ Text( '绑定引导.说明标题'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - fontWeight: - FontWeight.w500, - color: stringToColor( - "#916d46"), - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + fontWeight: FontWeight.w500, + color: + stringToColor("#916d46"), + ), ), Text( '绑定引导.说明正文'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - color: stringToColor( - "#916d46"), - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + color: + stringToColor("#916d46"), + ), ), ].divide(SizedBox( height: AppConstants() @@ -226,27 +219,23 @@ class _EPageState extends State { side: BorderSide( width: 1.5, color: - FlutterFlowTheme.of(context) - .secondaryText, + Colors.white, ), activeColor: stringToColor("#16C89F"), - checkColor: - FlutterFlowTheme.of(context) - .info, + // checkColor: + // FlutterFlowTheme.of(context) + // .info, ), )), Text( '绑定引导.不再提示'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -275,13 +264,11 @@ class _EPageState extends State { alignment: Alignment.center, // 居中对齐 child: Text( '确认'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ) @@ -334,12 +321,12 @@ class _EPageState extends State { /// 居中标题 Text( '设备列表'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -429,12 +416,12 @@ class _EPageState extends State { Expanded( child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + letterSpacing: 0.0, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), diff --git a/lib/pages/device_bind/device_type_list.dart b/lib/pages/device_bind/device_type_list.dart index bfa97df..0de7656 100644 --- a/lib/pages/device_bind/device_type_list.dart +++ b/lib/pages/device_bind/device_type_list.dart @@ -71,12 +71,12 @@ class _DeviceTypeListPageState extends State { /// 居中标题 Text( '设备列表'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -163,17 +163,19 @@ class _DeviceTypeListPageState extends State { mainAxisSize: MainAxisSize.max, mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ - Expanded(child: Text( - title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - letterSpacing: 0.0, - ), - maxLines: 1, - overflow: TextOverflow.ellipsis, - ),), + Expanded( + child: Text( + title, + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + letterSpacing: 0.0, + ), + maxLines: 1, + overflow: TextOverflow.ellipsis, + ), + ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), // child: Image.asset( diff --git a/lib/pages/device_bind/wifi_page.dart b/lib/pages/device_bind/wifi_page.dart index 15ff777..0030f52 100644 --- a/lib/pages/device_bind/wifi_page.dart +++ b/lib/pages/device_bind/wifi_page.dart @@ -158,13 +158,12 @@ class _WifiPageState extends State { children: [ Text( 'wifi页.标题'.tr, - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), SizedBox( width: 14.rpx, @@ -235,13 +234,11 @@ class _WifiPageState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '下一步'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -375,15 +372,13 @@ class _WifiPageState extends State { children: [ Text( '可用WLAN'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: + themeController.currentColor.sc3, + ), ), ], ), @@ -449,21 +444,19 @@ class _WifiPageState extends State { InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Inter', - fontSize: - 26.rpx, - letterSpacing: - 0.0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Inter', + fontSize: + 26.rpx, + letterSpacing: + 0.0, + ), hintText: '蓝牙绑定.输入wifi密码' .tr, - hintStyle: FlutterFlowTheme.of(context).labelMedium.override( + hintStyle: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -503,8 +496,6 @@ class _WifiPageState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -516,8 +507,6 @@ class _WifiPageState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -527,9 +516,7 @@ class _WifiPageState extends State { ), filled: false, - fillColor: FlutterFlowTheme.of( - context) - .secondaryBackground, + fillColor: Colors.white, suffixIcon: InkWell( onTap: @@ -553,7 +540,7 @@ class _WifiPageState extends State { ), ), ), - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -684,18 +671,13 @@ class _WifiPageState extends State { children: [ Text( wifiItem['ssid'] ?? '', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: - themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), if (blueteethBindController .selectWifi.value == @@ -815,15 +797,13 @@ class _WifiPageState extends State { ), Text( '刷新'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(width: 26.rpx)), ), @@ -1102,7 +1082,8 @@ class _WifiPageState extends State { // text: "4g设备配置wifi提示".tr, // textColor: themeController.currentColor.sc9, // ); - updateDeviceBindStatus(blueteethBindController.currentDeviceMac!.value); + updateDeviceBindStatus( + blueteethBindController.currentDeviceMac!.value); WidgetsBinding.instance.addPostFrameCallback((_) { TopSlideNotification.show( context, @@ -1162,7 +1143,7 @@ class _WifiPageState extends State { } } - void updateDeviceBindStatus(String mac) { + void updateDeviceBindStatus(String mac) { String serviceAddress = ServiceConstant.service_address; String serviceName = ServiceConstant.server_service; String serviceApi = ServiceConstant.user_setting; @@ -1179,8 +1160,8 @@ class _WifiPageState extends State { "type": type, "mac": mac, "wifi": true, - "celibration":res.data['celibration'], - "person_info":res.data['person_info'], + "celibration": res.data['celibration'], + "person_info": res.data['person_info'], "time": DateTime.now().millisecondsSinceEpoch, }; requestWithLog( diff --git a/lib/pages/device_bind/wifi_page_person.dart b/lib/pages/device_bind/wifi_page_person.dart index 83eebc2..d2720e3 100644 --- a/lib/pages/device_bind/wifi_page_person.dart +++ b/lib/pages/device_bind/wifi_page_person.dart @@ -99,13 +99,12 @@ class _WifiPagePersonState extends State { children: [ Text( 'wifi页.标题'.tr, - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), SizedBox( width: 14.rpx, @@ -178,13 +177,11 @@ class _WifiPagePersonState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '完成'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -318,15 +315,13 @@ class _WifiPagePersonState extends State { children: [ Text( '可用WLAN'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: + themeController.currentColor.sc3, + ), ), ], ), @@ -392,21 +387,19 @@ class _WifiPagePersonState extends State { InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Inter', - fontSize: - 26.rpx, - letterSpacing: - 0.0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Inter', + fontSize: + 26.rpx, + letterSpacing: + 0.0, + ), hintText: '蓝牙绑定.输入wifi密码' .tr, - hintStyle: FlutterFlowTheme.of(context).labelMedium.override( + hintStyle: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -446,8 +439,6 @@ class _WifiPagePersonState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -459,8 +450,6 @@ class _WifiPagePersonState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -470,9 +459,7 @@ class _WifiPagePersonState extends State { ), filled: false, - fillColor: FlutterFlowTheme.of( - context) - .secondaryBackground, + fillColor: Colors.white, suffixIcon: InkWell( onTap: @@ -496,7 +483,7 @@ class _WifiPagePersonState extends State { ), ), ), - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -627,18 +614,13 @@ class _WifiPagePersonState extends State { children: [ Text( wifiItem['ssid'] ?? '', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: - themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), if (blueteethBindController .selectWifi.value == @@ -764,15 +746,13 @@ class _WifiPagePersonState extends State { ), Text( '刷新'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(width: 26.rpx)), ), @@ -1125,8 +1105,8 @@ class _WifiPagePersonState extends State { "type": type, "mac": mac, "wifi": true, - "celibration":res.data['celibration'], - "person_info":res.data['person_info'], + "celibration": res.data['celibration'], + "person_info": res.data['person_info'], "time": DateTime.now().millisecondsSinceEpoch, }; requestWithLog( diff --git a/lib/pages/login/login.dart b/lib/pages/login/login.dart index 3224bbc..5e52960 100644 --- a/lib/pages/login/login.dart +++ b/lib/pages/login/login.dart @@ -151,16 +151,14 @@ class _EPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '登录页.欢迎使用太和e护'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - //todo 颜色 - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + //todo 颜色 + color: + themeController.currentColor.sc3, + ), ), ), ), @@ -178,16 +176,14 @@ class _EPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '登录页.科技睡眠 洞悉万千'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - //todo 颜色 - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + //todo 颜色 + color: + themeController.currentColor.sc3, + ), ), ), ), @@ -205,16 +201,14 @@ class _EPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '139****0733', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - //todo 颜色 - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + //todo 颜色 + color: + themeController.currentColor.sc3, + ), ), ), ), @@ -260,17 +254,15 @@ class _EPageState extends State { child: Text( textAlign: TextAlign.center, '登录页.本机号码一键登录/注册'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - //todo 颜色 - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + //todo 颜色 + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), @@ -350,15 +342,12 @@ class _EPageState extends State { }, side: BorderSide( width: 1.5, - color: - FlutterFlowTheme.of(context) - .secondaryText, + color: Colors.white, ), activeColor: stringToColor("#FF9F66"), checkColor: - FlutterFlowTheme.of(context) - .info, + Colors.white, ), )), Expanded( @@ -377,81 +366,63 @@ class _EPageState extends State { children: [ TextSpan( text: '登录页.协议1'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 26.rpx, - color: Colors - .white, // 可以调整为你想要的颜色 - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 26.rpx, + color: Colors + .white, // 可以调整为你想要的颜色 + ), ), TextSpan( text: '登录页.协议2'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 26.rpx, - color: stringToColor( - "#FF9F66"), - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 26.rpx, + color: stringToColor( + "#FF9F66"), + ), ), TextSpan( text: '登录页.协议3'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 26.rpx, - color: Colors - .white, // 可以调整为你想要的颜色 - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 26.rpx, + color: Colors + .white, // 可以调整为你想要的颜色 + ), ), TextSpan( text: '登录页.协议4'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 26.rpx, - color: stringToColor( - "#FF9F66"), - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 26.rpx, + color: stringToColor( + "#FF9F66"), + ), ), TextSpan( text: '登录页.协议5'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 26.rpx, - color: Colors - .white, // 可以调整为你想要的颜色 - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 26.rpx, + color: Colors + .white, // 可以调整为你想要的颜色 + ), ), TextSpan( text: '登录页.协议6'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 26.rpx, - color: stringToColor( - "#FF9F66"), - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 26.rpx, + color: stringToColor( + "#FF9F66"), + ), ), ], ), @@ -482,14 +453,12 @@ class _EPageState extends State { 0, 0, 0, 36.rpx), child: Text( '登录页.其他登录方式'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), Row( diff --git a/lib/pages/login/other_login.dart b/lib/pages/login/other_login.dart index 917e171..9667279 100644 --- a/lib/pages/login/other_login.dart +++ b/lib/pages/login/other_login.dart @@ -153,15 +153,13 @@ class _OtherLoginPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '登录页.欢迎使用太和e护'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + color: + themeController.currentColor.sc3, + ), ), ), ), @@ -179,15 +177,13 @@ class _OtherLoginPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '登录页.科技睡眠 洞悉万千'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: + themeController.currentColor.sc3, + ), ), ), ), @@ -237,25 +233,19 @@ class _OtherLoginPageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '其他手机登录页.输入内容'.tr, - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -281,10 +271,7 @@ class _OtherLoginPageState extends State { errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of( - context) - .error, + color: Colors.red, width: 1.rpx, ), borderRadius: @@ -295,9 +282,7 @@ class _OtherLoginPageState extends State { OutlineInputBorder( borderSide: BorderSide( color: - FlutterFlowTheme.of( - context) - .error, + Colors.red, width: 1.rpx, ), borderRadius: @@ -305,20 +290,15 @@ class _OtherLoginPageState extends State { 8.rpx), ), filled: false, - fillColor: FlutterFlowTheme - .of(context) - .secondaryBackground, + fillColor: Colors.white, + ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), cursorColor: themeController .currentColor.sc3, // validator: _model @@ -378,26 +358,20 @@ class _OtherLoginPageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '其他手机登录页.输入验证码'.tr, - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -423,10 +397,7 @@ class _OtherLoginPageState extends State { errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of( - context) - .error, + color: Colors.red, width: 1.rpx, ), borderRadius: @@ -437,9 +408,7 @@ class _OtherLoginPageState extends State { OutlineInputBorder( borderSide: BorderSide( color: - FlutterFlowTheme.of( - context) - .error, + Colors.red, width: 1.rpx, ), borderRadius: @@ -450,16 +419,13 @@ class _OtherLoginPageState extends State { fillColor: Colors.transparent, ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), cursorColor: themeController .currentColor.sc3, // validator: _model @@ -667,16 +633,14 @@ class _OtherLoginPageState extends State { children: [ Text( '其他手机登录页.登录'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -729,15 +693,12 @@ class _OtherLoginPageState extends State { }, side: BorderSide( width: 1.5, - color: - FlutterFlowTheme.of(context) - .secondaryText, + color: Colors.white, ), activeColor: stringToColor("#FF9F66"), //固定 checkColor: - FlutterFlowTheme.of(context) - .info, + Colors.white, ), )), Expanded( @@ -756,81 +717,63 @@ class _OtherLoginPageState extends State { children: [ TextSpan( text: '登录页.协议1'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 20.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 20.rpx, + color: themeController + .currentColor.sc3, + ), ), TextSpan( text: '登录页.协议2'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 20.rpx, - color: stringToColor( - "#FF9F66"), - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 20.rpx, + color: stringToColor( + "#FF9F66"), + ), ), TextSpan( text: '登录页.协议3'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 20.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 20.rpx, + color: themeController + .currentColor.sc3, + ), ), TextSpan( text: '登录页.协议4'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 20.rpx, - color: stringToColor( - "#FF9F66"), - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 20.rpx, + color: stringToColor( + "#FF9F66"), + ), ), TextSpan( text: '登录页.协议5'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 20.rpx, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 20.rpx, + color: themeController + .currentColor.sc3, + ), ), TextSpan( text: '登录页.协议6'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: 20.rpx, - color: stringToColor( - "#FF9F66"), - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: 20.rpx, + color: stringToColor( + "#FF9F66"), + ), ), ], ), @@ -861,14 +804,12 @@ class _OtherLoginPageState extends State { 0, 0, 0, 36.rpx), child: Text( '登录页.其他登录方式'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), Row( diff --git a/lib/pages/main_bottom/component/MessageWidgetWidget.dart b/lib/pages/main_bottom/component/MessageWidgetWidget.dart index 5acc645..eb3d9bf 100644 --- a/lib/pages/main_bottom/component/MessageWidgetWidget.dart +++ b/lib/pages/main_bottom/component/MessageWidgetWidget.dart @@ -54,12 +54,12 @@ class _MessageWidgetWidgetState extends State { child: Text( // '实时监测结果通知'.tr, "${messageInfo['data']['title']}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -144,12 +144,12 @@ class _MessageWidgetWidgetState extends State { child: Center( child: Text( getMessageStatus(messageInfo['status']), - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: Colors.white, + ), ), ), ), @@ -170,12 +170,12 @@ class _MessageWidgetWidgetState extends State { overflow: TextOverflow.ellipsis, maxLines: 1, label.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ); @@ -192,12 +192,12 @@ class _MessageWidgetWidgetState extends State { overflow: TextOverflow.ellipsis, maxLines: 1, "${value}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ); diff --git a/lib/pages/main_bottom/component/main_page_b_bottom_change.dart b/lib/pages/main_bottom/component/main_page_b_bottom_change.dart index 63b8299..b91780e 100644 --- a/lib/pages/main_bottom/component/main_page_b_bottom_change.dart +++ b/lib/pages/main_bottom/component/main_page_b_bottom_change.dart @@ -32,7 +32,8 @@ class _HomePageState extends State // Text('报告'), // RegisterPage(), // ShareDeviceWidget(), - DeviceListPage(), + // DeviceListPage(), + MhtSleepReportPage(), // FindPasswordPage(), // Smys(), MattressControlPage(), diff --git a/lib/pages/main_bottom/e_page.dart b/lib/pages/main_bottom/e_page.dart index 042faba..802be75 100644 --- a/lib/pages/main_bottom/e_page.dart +++ b/lib/pages/main_bottom/e_page.dart @@ -40,12 +40,12 @@ class _EPageState extends State { /// 居中标题 Text( '小e'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 diff --git a/lib/pages/main_bottom/follow_page.dart b/lib/pages/main_bottom/follow_page.dart index de142e3..95862fa 100644 --- a/lib/pages/main_bottom/follow_page.dart +++ b/lib/pages/main_bottom/follow_page.dart @@ -55,12 +55,12 @@ class _FollowPageState extends State { /// 居中标题 Text( '关注我们'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -74,7 +74,7 @@ class _FollowPageState extends State { actions: [], centerTitle: false, ), - + body: SafeArea( top: true, child: Padding( diff --git a/lib/pages/main_bottom/help_page.dart b/lib/pages/main_bottom/help_page.dart index 8c27bbb..f8e6f4b 100644 --- a/lib/pages/main_bottom/help_page.dart +++ b/lib/pages/main_bottom/help_page.dart @@ -57,12 +57,12 @@ class _HelpPageState extends State { /// 居中标题 Text( '操作说明'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 diff --git a/lib/pages/main_bottom/home_page.dart b/lib/pages/main_bottom/home_page.dart index 34cc078..cae727c 100644 --- a/lib/pages/main_bottom/home_page.dart +++ b/lib/pages/main_bottom/home_page.dart @@ -292,17 +292,12 @@ class _HomePageState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '首页.登录'.tr, - style: - FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: - 'Inter Tight', - color: themeController - .currentColor - .sc19, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController + .currentColor.sc19, + letterSpacing: 0.0, + ), ), ), ), @@ -470,17 +465,15 @@ class _HomePageState extends State { children: [ Text( '首页.已关联体征监测设备'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - //todo 颜色 - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + //todo 颜色 + color: themeController + .currentColor.sc3, + ), ), Obx(() { return Padding( @@ -489,17 +482,14 @@ class _HomePageState extends State { 0, 4.rpx, 0.rpx, 0.rpx), child: Text( "${deviceController.bindDeviceNum.value}", - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - color: themeController - .currentColor.sc8, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + color: themeController + .currentColor.sc8, + ), ), ); }), @@ -607,18 +597,14 @@ class _HomePageState extends State { ), Text( '首页.扫一扫绑定'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor - .sc19, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc19, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -705,19 +691,15 @@ class _HomePageState extends State { ), Text( '首页.蓝牙绑定'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - //todo 颜色 - color: themeController - .currentColor - .sc19, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + //todo 颜色 + color: themeController + .currentColor.sc19, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -777,63 +759,50 @@ class _HomePageState extends State { children: [ Text( '首页.提示标题'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - fontWeight: - FontWeight.w600, - color: stringToColor( - "#916D46"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + fontWeight: FontWeight.w600, + color: stringToColor( + "#916D46"), //固定 + ), ), Text( '首页.提示内容1'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - //todo 配置颜色 - color: stringToColor( - "#916D46"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + //todo 配置颜色 + color: stringToColor( + "#916D46"), //固定 + ), ), Text( '首页.提示内容2'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - color: stringToColor( - "#916D46"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + color: stringToColor( + "#916D46"), //固定 + ), ), Text( '首页.提示内容3'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - //todo 配置颜色 - color: stringToColor( - "#916D46"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + //todo 配置颜色 + color: stringToColor( + "#916D46"), //固定 + ), ), ].divide(SizedBox( height: AppConstants() diff --git a/lib/pages/main_bottom/message_page.dart b/lib/pages/main_bottom/message_page.dart index 69edcab..0240cba 100644 --- a/lib/pages/main_bottom/message_page.dart +++ b/lib/pages/main_bottom/message_page.dart @@ -126,23 +126,19 @@ class _MessagePageState extends State { children: [ Text( '体征消息'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - color: messageController - .model.type == - 2 - ? themeController - .currentColor - .sc3 - : themeController - .currentColor - .sc2, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + color: + messageController + .model.type == + 2 + ? themeController + .currentColor.sc3 + : themeController + .currentColor.sc2, + ), ), Obx(() { return messageController.model @@ -189,23 +185,19 @@ class _MessagePageState extends State { children: [ Text( '系统消息'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - color: messageController - .model.type == - 1 - ? themeController - .currentColor - .sc3 - : themeController - .currentColor - .sc2, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + color: + messageController + .model.type == + 1 + ? themeController + .currentColor.sc3 + : themeController + .currentColor.sc2, + ), ), Obx(() { return messageController.model @@ -261,6 +253,7 @@ class _MessagePageState extends State { ], ), ), + SizedBox(height: 17.rpx), ], ), diff --git a/lib/pages/main_bottom/mine_page.dart b/lib/pages/main_bottom/mine_page.dart index 949169e..903bd7a 100644 --- a/lib/pages/main_bottom/mine_page.dart +++ b/lib/pages/main_bottom/mine_page.dart @@ -207,17 +207,14 @@ class _MinePageState extends State { .user!.nick_name ?? '未命名'.tr) : "未命名".tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), Text( login == 1 @@ -241,19 +238,15 @@ class _MinePageState extends State { } })() : "未知数据".tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ), - ].divide(SizedBox(height: 20.rpx)), ), ].divide(SizedBox(width: 35.rpx)), @@ -277,16 +270,14 @@ class _MinePageState extends State { children: [ Text( login == 1 ? '编辑'.tr : '我的.去登录'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ), Padding( padding: @@ -370,17 +361,14 @@ class _MinePageState extends State { ), Text( '我的.我的设备'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -446,17 +434,14 @@ class _MinePageState extends State { ), Text( '我的.设备报修'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -522,17 +507,14 @@ class _MinePageState extends State { ), Text( '我的.操作说明'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -598,17 +580,14 @@ class _MinePageState extends State { ), Text( '我的.关注我们'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -680,17 +659,14 @@ class _MinePageState extends State { ), Text( '我的.当前版本'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -699,16 +675,12 @@ class _MinePageState extends State { children: [ Text( 'V1.0.2506.06', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Color(0xFFD9E3EB), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFD9E3EB), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SvgPicture.asset( 'assets/img/icon/arrow_right.svg', diff --git a/lib/pages/mh_page/HomeDeviceType.dart b/lib/pages/mh_page/HomeDeviceType.dart index 91a66aa..0164214 100644 --- a/lib/pages/mh_page/HomeDeviceType.dart +++ b/lib/pages/mh_page/HomeDeviceType.dart @@ -88,14 +88,12 @@ class _HomeDeviceTypeState extends State { 48.rpx, 24.rpx, 0, 0), child: Text( '选择类型', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0, + ), ), ), _buildControlCard(context), @@ -150,7 +148,7 @@ Widget _buildDeviceItem(BuildContext context, Map dtype) { child: Container( height: 221.rpx, decoration: BoxDecoration( - color: FlutterFlowTheme.of(context).secondaryBackground, + // color: FlutterFlowTheme.of(context).secondaryBackground, borderRadius: BorderRadius.circular(6), ), constraints: BoxConstraints(minHeight: 221.rpx), @@ -178,11 +176,11 @@ Widget _buildDeviceItem(BuildContext context, Map dtype) { padding: EdgeInsets.fromLTRB(0, 59.rpx, 0, 0), child: Text( dtype["name"], - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - fontWeight: FontWeight.bold, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + fontWeight: FontWeight.bold, + ), ), ), SizedBox(height: 35.rpx), diff --git a/lib/pages/mh_page/LanguagePage.dart b/lib/pages/mh_page/LanguagePage.dart index fd31640..e71616e 100644 --- a/lib/pages/mh_page/LanguagePage.dart +++ b/lib/pages/mh_page/LanguagePage.dart @@ -1,4 +1,3 @@ -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:ef/ef.dart'; import 'package:flutter/material.dart'; import 'package:vbvs_app/common/util/FitTool.dart'; @@ -130,7 +129,6 @@ class LanguagePage extends GetView { borderRadius: BorderRadius.circular(4), ), ), - unselectedWidgetColor: FlutterFlowTheme.of(context).alternate, ), child: Obx(() { return Checkbox( @@ -149,10 +147,10 @@ class LanguagePage extends GetView { shape: CircleBorder(), side: BorderSide( width: 2, - color: FlutterFlowTheme.of(context).alternate, + // color: FlutterFlowTheme.of(context).alternate, ), activeColor: Color(0XFF6BFDAC), - checkColor: FlutterFlowTheme.of(context).info, + // checkColor: FlutterFlowTheme.of(context).info, ); })), ], diff --git a/lib/pages/mh_page/MhMessageList.dart b/lib/pages/mh_page/MhMessageList.dart index 5eda7e2..d78605d 100644 --- a/lib/pages/mh_page/MhMessageList.dart +++ b/lib/pages/mh_page/MhMessageList.dart @@ -54,12 +54,12 @@ class _MhMessageListWidgetState extends State { child: Text( // '实时监测结果通知'.tr, "${messageInfo['data']['title']}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -144,12 +144,12 @@ class _MhMessageListWidgetState extends State { child: Center( child: Text( getMessageStatus(messageInfo['status']), - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: Colors.white, + ), ), ), ), @@ -170,12 +170,12 @@ class _MhMessageListWidgetState extends State { overflow: TextOverflow.ellipsis, maxLines: 1, label.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ); @@ -192,12 +192,12 @@ class _MhMessageListWidgetState extends State { overflow: TextOverflow.ellipsis, maxLines: 1, "${value}", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ); diff --git a/lib/pages/mh_page/ShareUserWidget.dart b/lib/pages/mh_page/ShareUserWidget.dart index a19ea34..9b3130f 100644 --- a/lib/pages/mh_page/ShareUserWidget.dart +++ b/lib/pages/mh_page/ShareUserWidget.dart @@ -67,14 +67,12 @@ class ShareUserWidget extends GetView { alignment: const AlignmentDirectional(-1, 0), child: Text( '${info['userName']}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -87,14 +85,12 @@ class ShareUserWidget extends GetView { : info['opType'] == 2 ? '仅允许对方查看该设备' : '', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFFC8CBD2), - fontSize: 20.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFFC8CBD2), + fontSize: 20.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -109,7 +105,7 @@ class ShareUserWidget extends GetView { // maxWidth: 130, // ), // decoration: BoxDecoration( - // color: FlutterFlowTheme.of(context).secondaryBackground, + // // ), // child: Row( // mainAxisSize: MainAxisSize.max, @@ -119,7 +115,7 @@ class ShareUserWidget extends GetView { // alignment: const AlignmentDirectional(0, 0), // child: Text( // ' ', - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Readex Pro', // color: const Color(0xFF333333), // fontSize: 13, diff --git a/lib/pages/mh_page/address_list_page.dart b/lib/pages/mh_page/address_list_page.dart index 6cbb597..299303f 100644 --- a/lib/pages/mh_page/address_list_page.dart +++ b/lib/pages/mh_page/address_list_page.dart @@ -93,14 +93,12 @@ class AddressListPage extends GetView { 31, 27, 0, 26), child: Text( '我的地址', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: AppFontsize.title_size, - letterSpacing: 0, - fontWeight: FontWeight.w600, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize.title_size, + letterSpacing: 0, + fontWeight: FontWeight.w600, + ), ), ), ), @@ -186,14 +184,12 @@ class AddressListPage extends GetView { SizedBox(width: 10), // 加号和文字间距 Text( '添加新地址', - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF85F5FF), - fontSize: AppFontsize.normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF85F5FF), + fontSize: AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ], ), diff --git a/lib/pages/mh_page/address_module_widget.dart b/lib/pages/mh_page/address_module_widget.dart index 155e7e2..07a6ffb 100644 --- a/lib/pages/mh_page/address_module_widget.dart +++ b/lib/pages/mh_page/address_module_widget.dart @@ -108,15 +108,13 @@ class AddressModuleWidget extends GetView { element != null && element.isNotEmpty) .join(' '), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF333333), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF333333), + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -133,15 +131,13 @@ class AddressModuleWidget extends GetView { ? '无详细地址' : addressListController.model .addressList[index]['detail'], - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF333333), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF333333), + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -151,15 +147,13 @@ class AddressModuleWidget extends GetView { child: Text( '${addressListController.model.addressList[index]['name']} ' + '${addressListController.model.addressList[index]['phone']} ', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF333333), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF333333), + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -208,12 +202,11 @@ class AddressModuleWidget extends GetView { }, side: BorderSide( width: 1.5, - color: FlutterFlowTheme.of(context) - .secondaryText, + color: Colors.white, ), activeColor: const Color(0xFFd3b684), - checkColor: - FlutterFlowTheme.of(context).info, + // checkColor: + // FlutterFlowTheme.of(context).info, ); }), ), @@ -238,14 +231,12 @@ class AddressModuleWidget extends GetView { alignment: AlignmentDirectional(1, 0), child: Text( '编辑', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ), ), diff --git a/lib/pages/mh_page/applyRepair/apply_repair_success.dart b/lib/pages/mh_page/applyRepair/apply_repair_success.dart index 8dc8d5e..01afb14 100644 --- a/lib/pages/mh_page/applyRepair/apply_repair_success.dart +++ b/lib/pages/mh_page/applyRepair/apply_repair_success.dart @@ -60,7 +60,7 @@ class _ApplyRepairSuccessState extends State { /// 居中标题 Text( '报修成功标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', color: themeController.currentColor.sc3, letterSpacing: 0, @@ -131,9 +131,7 @@ class _ApplyRepairSuccessState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '报修成功'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Inter', fontSize: 30.rpx, letterSpacing: 0.0, @@ -230,9 +228,7 @@ class _ApplyRepairSuccessState extends State { ), Text( '查看报修历史'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( + style: TextStyle( color: Color(0xFF011D33), fontFamily: 'Inter', fontSize: AppConstants() @@ -276,9 +272,7 @@ class _ApplyRepairSuccessState extends State { children: [ Text( '绑定成功.返回'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( + style:TextStyle( color: Color(0xFF011D33), fontFamily: 'Inter', fontSize: AppConstants() @@ -327,7 +321,7 @@ class _ApplyRepairSuccessState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Inter', color: const Color(0xFFC2CED7), fontSize: 30.rpx, diff --git a/lib/pages/mh_page/apply_repair_page.dart b/lib/pages/mh_page/apply_repair_page.dart index 4eb0ec1..15a1180 100644 --- a/lib/pages/mh_page/apply_repair_page.dart +++ b/lib/pages/mh_page/apply_repair_page.dart @@ -149,19 +149,15 @@ class ApplyRepairPage extends GetView { 0, -1), child: Text( '选择需要报修的设备', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - letterSpacing: 0, - fontSize: - AppFontsize - .title_size, - color: Colors - .white // 加粗文字 - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: 0, + fontSize: AppFontsize + .title_size, + color: Colors + .white // 加粗文字 + ), ), ), ), @@ -203,7 +199,7 @@ class ApplyRepairPage extends GetView { -1, 0), child: Text( '已绑设备', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: 26 @@ -271,18 +267,21 @@ class ApplyRepairPage extends GetView { 300, height: 56, - searchHintTextStyle: FlutterFlowTheme.of(context).labelMedium.override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), - searchTextStyle: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), - textStyle: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), + searchHintTextStyle: + TextStyle( + fontFamily: 'Readex Pro', + letterSpacing: 0, + ), + searchTextStyle: + TextStyle( + fontFamily: 'Readex Pro', + letterSpacing: 0, + ), + textStyle: + TextStyle( + fontFamily: 'Readex Pro', + letterSpacing: 0, + ), hintText: '请选择绑定设备', searchHintText: @@ -290,7 +289,7 @@ class ApplyRepairPage extends GetView { icon: Icon( Icons.keyboard_arrow_down_rounded, - color: FlutterFlowTheme.of(context).secondaryText, + color: Colors.white, size: 24, ), // fillColor: @@ -298,7 +297,7 @@ class ApplyRepairPage extends GetView { elevation: 2, borderColor: - FlutterFlowTheme.of(context).alternate, + Colors.white, borderWidth: 0, borderRadius: @@ -355,7 +354,7 @@ class ApplyRepairPage extends GetView { -1, 0), child: Text( '设备系列', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: 26 @@ -409,18 +408,20 @@ class ApplyRepairPage extends GetView { false, decoration: InputDecoration( - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), + hintStyle: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), enabledBorder: UnderlineInputBorder( borderSide: @@ -476,15 +477,13 @@ class ApplyRepairPage extends GetView { 10, 18), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), ); })), ), @@ -525,7 +524,7 @@ class ApplyRepairPage extends GetView { -1, 0), child: Text( '产品型号', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: 26 @@ -579,18 +578,20 @@ class ApplyRepairPage extends GetView { false, decoration: InputDecoration( - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), + hintStyle: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), enabledBorder: UnderlineInputBorder( borderSide: @@ -646,15 +647,13 @@ class ApplyRepairPage extends GetView { 10, 18), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), ); })), ), @@ -695,7 +694,7 @@ class ApplyRepairPage extends GetView { -1, 0), child: Text( '序列号', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: 26 @@ -749,18 +748,20 @@ class ApplyRepairPage extends GetView { false, decoration: InputDecoration( - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), + hintStyle: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), enabledBorder: UnderlineInputBorder( borderSide: @@ -816,15 +817,13 @@ class ApplyRepairPage extends GetView { 10, 18), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + ), ); })), ), @@ -987,20 +986,17 @@ class ApplyRepairPage extends GetView { 0, 0), child: Text( '上传设备故障照片', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF9EA4B7), - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: const Color( + 0xFF9EA4B7), + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), ), ), @@ -1027,9 +1023,7 @@ class ApplyRepairPage extends GetView { minHeight: 250, ), decoration: BoxDecoration( - color: FlutterFlowTheme.of( - context) - .secondaryBackground, + color: Colors.white, ), child: Column( mainAxisSize: @@ -1053,9 +1047,7 @@ class ApplyRepairPage extends GetView { height: 21, decoration: BoxDecoration( - color: FlutterFlowTheme - .of(context) - .secondaryBackground, + color: Colors.white, ), child: Container( width: MediaQuery @@ -1066,9 +1058,7 @@ class ApplyRepairPage extends GetView { height: 21, decoration: BoxDecoration( - color: FlutterFlowTheme.of( - context) - .secondaryBackground, + color: Colors.white, ), child: Row( mainAxisSize: @@ -1085,45 +1075,42 @@ class ApplyRepairPage extends GetView { .issue_img! .length .toString(), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), Text( '/', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), Text( '3', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), ], ), @@ -1153,18 +1140,14 @@ class ApplyRepairPage extends GetView { ), decoration: BoxDecoration( - color: FlutterFlowTheme - .of(context) - .secondaryBackground, + color: Colors.white, ), child: Container( width: 100, height: 100, decoration: BoxDecoration( - color: FlutterFlowTheme.of( - context) - .secondaryBackground, + color: Colors.white, ), child: Obx(() => ListView( shrinkWrap: true, @@ -1225,18 +1208,13 @@ class ApplyRepairPage extends GetView { .fromSTEB(0, 15, 0, 16), child: Text( '请描述一下您的问题', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0, - fontWeight: - FontWeight.w600, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0, + fontWeight: FontWeight.w600, + ), ), ), ), @@ -1274,10 +1252,7 @@ class ApplyRepairPage extends GetView { decoration: InputDecoration( hintText: '问题描述(100个字以内)', - labelStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', fontSize: AppFontsize @@ -1285,10 +1260,7 @@ class ApplyRepairPage extends GetView { letterSpacing: 0, color: Color( 0XFF929699)), - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', fontSize: AppFontsize @@ -1355,16 +1327,12 @@ class ApplyRepairPage extends GetView { maxLines: 4, maxLength: 100, // ✅ 限制最多输入 100 字符 - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -1399,10 +1367,7 @@ class ApplyRepairPage extends GetView { 0, 48.rpx, 0, 48.rpx), child: Text( '联系方式', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', color: Colors.white, fontSize: 30.rpx, @@ -1467,7 +1432,7 @@ class ApplyRepairPage extends GetView { children: [ Text( '联系人', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: 26 @@ -1524,19 +1489,13 @@ class ApplyRepairPage extends GetView { 10, 10, 14), - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -1591,10 +1550,7 @@ class ApplyRepairPage extends GetView { .circular(8), ), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -1643,7 +1599,7 @@ class ApplyRepairPage extends GetView { children: [ Text( '手机号码', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: 26 @@ -1697,19 +1653,13 @@ class ApplyRepairPage extends GetView { 10, 10, 14), - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -1764,10 +1714,7 @@ class ApplyRepairPage extends GetView { .circular(8), ), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -1875,14 +1822,12 @@ class ApplyRepairPage extends GetView { ), child: Text( "提交申请", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: stringToColor("#011D33"), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#011D33"), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ), )), diff --git a/lib/pages/mh_page/book_date_widget.dart b/lib/pages/mh_page/book_date_widget.dart index abc8781..c56eabd 100644 --- a/lib/pages/mh_page/book_date_widget.dart +++ b/lib/pages/mh_page/book_date_widget.dart @@ -41,7 +41,7 @@ class BookDateWidget extends GetView { Flexible( child: Text( "${bookInfoController.model.datetimes![index]?['dayName']}", - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, color: controller.model.datetimes_index == index @@ -53,7 +53,7 @@ class BookDateWidget extends GetView { Flexible( child: Text( "${bookInfoController.model.datetimes![index]?['day']}", - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, color: controller.model.datetimes_index == index diff --git a/lib/pages/mh_page/book_info_page.dart b/lib/pages/mh_page/book_info_page.dart index fc8cafa..2883737 100644 --- a/lib/pages/mh_page/book_info_page.dart +++ b/lib/pages/mh_page/book_info_page.dart @@ -113,25 +113,21 @@ class BookInfoPage extends GetView { children: [ Text( '${data["name"]}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - lineHeight: 1, - color: Colors.white), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + height: 1, + color: Colors.white), ), Text( '地址:${data["addressDetail"]}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - lineHeight: 1, - color: Color(0xFF929699)), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + height: 1, + color: Color(0xFF929699)), ), ].divide(SizedBox( height: 18.rpx, @@ -145,13 +141,11 @@ class BookInfoPage extends GetView { alignment: Alignment.centerLeft, child: Text( '体验日期', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: Colors.white), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: Colors.white), ), ), // Align( @@ -184,15 +178,13 @@ class BookInfoPage extends GetView { children: [ Text( '体验时段', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: Colors.white, - // 设置加粗 - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: Colors.white, + // 设置加粗 + ), ), Flexible(child: Obx(() { return InkWell( @@ -234,31 +226,25 @@ class BookInfoPage extends GetView { null ? "${controller.model.time_period?[controller.model.select_time_index!]?["timeStr"]}" : '请选择时间', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - color: (controller - .model - .select_time_index == - null) - ? stringToColor( - '#D0D0D0') - : Colors - .white), + style: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + color: (controller + .model + .select_time_index == + null) + ? stringToColor( + '#D0D0D0') + : Colors.white), ), ), Icon( Icons .keyboard_arrow_down_sharp, - color: FlutterFlowTheme.of( - context) - .secondaryText, + color: Colors.white, size: 16, ), ], @@ -285,15 +271,13 @@ class BookInfoPage extends GetView { children: [ Text( '体验人员', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: Colors.white, - // 设置加粗 - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: Colors.white, + // 设置加粗 + ), ), Flexible( child: Align( @@ -328,29 +312,19 @@ class BookInfoPage extends GetView { false, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), hintText: '输入姓名', - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - color: Color( - 0xFF929699)), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + color: Color(0xFF929699)), enabledBorder: UnderlineInputBorder( borderSide: @@ -399,16 +373,11 @@ class BookInfoPage extends GetView { EdgeInsets.symmetric( vertical: 0), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - color: - Colors.white), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + color: Colors.white), textAlign: TextAlign.end, ), ), @@ -436,15 +405,13 @@ class BookInfoPage extends GetView { children: [ Text( '手机号', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: Colors.white, - // 设置加粗 - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: Colors.white, + // 设置加粗 + ), ), Flexible( child: Align( @@ -480,29 +447,19 @@ class BookInfoPage extends GetView { keyboardType: TextInputType.phone, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), hintText: '输入手机号', - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - color: Color( - 0xFF929699)), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + color: Color(0xFF929699)), enabledBorder: UnderlineInputBorder( borderSide: @@ -551,16 +508,11 @@ class BookInfoPage extends GetView { EdgeInsets.symmetric( vertical: 0), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - color: - Colors.white), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + color: Colors.white), textAlign: TextAlign.end, ), ), @@ -700,13 +652,12 @@ class BookInfoPage extends GetView { ), child: Text( "提交预约", - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: stringToColor("#011D33"), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#011D33"), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ), )), diff --git a/lib/pages/mh_page/book_success_page.dart b/lib/pages/mh_page/book_success_page.dart index afc6400..be7d55b 100644 --- a/lib/pages/mh_page/book_success_page.dart +++ b/lib/pages/mh_page/book_success_page.dart @@ -102,15 +102,13 @@ class BookSuccessPage extends GetView { alignment: const AlignmentDirectional(0, 0), child: Text( '预约成功!', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 30.rpx, - color: Colors.white, - letterSpacing: 0, - fontWeight: FontWeight.w600, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + color: Colors.white, + letterSpacing: 0, + fontWeight: FontWeight.w600, + ), ), ), ].divide(SizedBox(height: 30.rpx)), diff --git a/lib/pages/mh_page/component/mht_bind_dialog.dart b/lib/pages/mh_page/component/mht_bind_dialog.dart index 5a4a5ba..c03f008 100644 --- a/lib/pages/mh_page/component/mht_bind_dialog.dart +++ b/lib/pages/mh_page/component/mht_bind_dialog.dart @@ -58,12 +58,12 @@ void showBindDoubleDialog( EdgeInsetsDirectional.fromSTEB(0.rpx, 93.rpx, 0, 0), child: Text( '蓝牙绑定.双人版绑定标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -250,14 +250,12 @@ Future showHaveBindDialog(BuildContext context) async { children: [ Text( '知道了'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -305,7 +303,7 @@ void showLoadingDialog(BuildContext context, {String? title}) { // 0.rpx, 93.rpx, 0.rpx, 0.rpx), // child: Text( // '蓝牙绑定.无法绑定'.tr, - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Inter', // fontSize: 30.rpx, // letterSpacing: 0.0, @@ -388,12 +386,12 @@ Widget _buildCheckboxRow( children: [ TextSpan( text: mainText, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - letterSpacing: 0.0, - fontSize: AppConstants().normal_text_fontSize, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + fontSize: AppConstants().normal_text_fontSize, + color: themeController.currentColor.sc3, + ), ), if (isBindable) TextSpan( @@ -459,12 +457,12 @@ Widget _buildActionButton( children: [ Text( text, - style: FlutterFlowTheme.of(context).bodyMedium.override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -539,13 +537,13 @@ void showConfirmDialog( 33.rpx, 60.rpx, 33.rpx, 33.rpx), child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: stringToColor("#333333"), - fontWeight: FontWeight.w600, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: stringToColor("#333333"), + fontWeight: FontWeight.w600, + ), ), ), ), @@ -583,15 +581,13 @@ void showConfirmDialog( children: [ Text( "否".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -621,15 +617,13 @@ void showConfirmDialog( children: [ Text( "是".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -719,12 +713,12 @@ void showSingleConfirmDialog( 33.rpx, 60.rpx, 33.rpx, 33.rpx), child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -763,15 +757,12 @@ void showSingleConfirmDialog( children: [ Text( confirmText, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -854,12 +845,12 @@ void showWifiDialog( EdgeInsetsDirectional.fromSTEB(0.rpx, 20.rpx, 0, 0), child: Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: stringToColor("#333333"), - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: stringToColor("#333333"), + ), ), ), ), @@ -899,15 +890,12 @@ void showWifiDialog( children: [ Text( "连接".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: Colors.white, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: Colors.white, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -989,14 +977,12 @@ Future showTipDialog( children: [ Text( '知道了'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: stringToColor("#333333"), - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#333333"), + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1078,14 +1064,12 @@ Future showUnBindTipDialog( children: [ Text( '继续'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -1124,14 +1108,12 @@ Future showUnBindTipDialog( children: [ Text( '下次再说'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), diff --git a/lib/pages/mh_page/delete_account.dart b/lib/pages/mh_page/delete_account.dart index 84b7e29..b5b9746 100644 --- a/lib/pages/mh_page/delete_account.dart +++ b/lib/pages/mh_page/delete_account.dart @@ -295,14 +295,12 @@ class DeletedAccountPage extends GetView { iconPadding: const EdgeInsetsDirectional.fromSTEB( 0, 0, 0, 0), color: const Color(0xFFFF7159), - textStyle: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: AppFontsize.normal_text_size, - letterSpacing: 0, - ), + textStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize.normal_text_size, + letterSpacing: 0, + ), elevation: 0, borderSide: const BorderSide( color: Colors.transparent, diff --git a/lib/pages/mh_page/device/component/DeviceComponentWidget.dart b/lib/pages/mh_page/device/component/DeviceComponentWidget.dart index 4ec3b05..2e46de8 100644 --- a/lib/pages/mh_page/device/component/DeviceComponentWidget.dart +++ b/lib/pages/mh_page/device/component/DeviceComponentWidget.dart @@ -226,7 +226,8 @@ class _DeviceComponentWidgetState extends State { text: response.msg!); if (response.code == HttpStatusCodes.ok) { //更新设备绑定流程 - Get.toNamed("/mHTwifiPage",arguments: widget.bleDevice); + Get.toNamed("/mHTwifiPage", + arguments: widget.bleDevice); THapp bledevice = THapp( device: widget.bleDevice.scanResult.device); blueteethBindController.currentDevice = bledevice; @@ -322,12 +323,12 @@ class _DeviceComponentWidgetState extends State { children: [ Text( device.name ?? '蓝牙绑定.默认设备名称'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), Obx(() { if (blueteethBindController.currentDeviceMac.value == @@ -350,77 +351,77 @@ class _DeviceComponentWidgetState extends State { children: [ Text( "蓝牙绑定.信号强度".tr + ':${device.rssi ?? '-'}dBm', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SizedBox(width: 40.rpx), Text( "蓝牙绑定.SN".tr + ':${device.sn ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF5F9FD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF5F9FD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), Text( "蓝牙绑定.蓝牙地址".tr + ':${device.deviceId ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( "蓝牙绑定.mac".tr + ':${device.mac ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Row( children: [ Text( "蓝牙绑定.网络".tr + ':${device.isOnline == true ? '蓝牙绑定.在线'.tr : '蓝牙绑定.离线'.tr}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SizedBox(width: 145.rpx), Row( children: [ Text( "蓝牙绑定.传感器".tr + ":", - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFEBF2F8), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFEBF2F8), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Text( device.bind == false ? '蓝牙绑定.可绑定'.tr : '蓝牙绑定.已被绑定'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: device.bind == false - ? const Color(0xFF1AD2B5) - : themeController.currentColor.sc9, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: device.bind == false + ? const Color(0xFF1AD2B5) + : themeController.currentColor.sc9, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ], ), @@ -428,12 +429,12 @@ class _DeviceComponentWidgetState extends State { ), Text( "版本".tr + '${device.version ?? '-'}', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFF6FAFD), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFF6FAFD), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( height: 37.rpx, diff --git a/lib/pages/mh_page/device/device.dart b/lib/pages/mh_page/device/device.dart index 1acc0d8..2a798e0 100644 --- a/lib/pages/mh_page/device/device.dart +++ b/lib/pages/mh_page/device/device.dart @@ -55,12 +55,12 @@ class DeviceInfoWidget extends GetView { Text( deviceListController.model.deviceList[index]['name'] ?? 'SWES系列 01号智能一键入眠床', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0, + ), maxLines: 1, // 限制显示一行 overflow: TextOverflow.ellipsis, // 超出部分显示省略号 ), @@ -108,40 +108,31 @@ class DeviceInfoWidget extends GetView { .deviceList[ index]['_id'] ?? ''), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: - Color(0xFFC8CBD2), - fontSize: 26.rpx, - letterSpacing: 0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFFC8CBD2), + fontSize: 26.rpx, + letterSpacing: 0, + height: 1), ), TextSpan( text: ' (${deviceListController.model.deviceList[index]['status'] ?? ''})', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: deviceListController - .model - .deviceList[index] - [ - 'status'] == - '在线' - ? Color( - 0xFF07C160) // 在线的颜色 - : Color( - 0xFFEA7CA7), // 离线的颜色 - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: deviceListController + .model + .deviceList[ + index] + ['status'] == + '在线' + ? Color( + 0xFF07C160) // 在线的颜色 + : Color( + 0xFFEA7CA7), // 离线的颜色 + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ], ), @@ -160,14 +151,12 @@ class DeviceInfoWidget extends GetView { .model.deviceList[index] ['roomName'] ?? ''), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFFC8CBD2), - fontSize: 26.rpx, - letterSpacing: 0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFFC8CBD2), + fontSize: 26.rpx, + letterSpacing: 0, + height: 1), ), ), Align( @@ -180,14 +169,12 @@ class DeviceInfoWidget extends GetView { ?["status"] ?.toString() ?? ''), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFFC8CBD2), - fontSize: 26.rpx, - letterSpacing: 0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFFC8CBD2), + fontSize: 26.rpx, + letterSpacing: 0, + height: 1), ), ) ].divide(SizedBox(height: 36.rpx)), @@ -207,14 +194,12 @@ class DeviceInfoWidget extends GetView { text: '控制', options: FFButtonOptions( color: Color(0XFF85F5FF), - textStyle: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 28.rpx, - letterSpacing: 0, - ), + textStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 28.rpx, + letterSpacing: 0, + ), elevation: 0, borderSide: BorderSide( color: Colors.transparent, @@ -282,15 +267,13 @@ class DeviceInfoWidget extends GetView { if (device['bind_type'] == 1) Text( '已分享:', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + color: Colors.white, + ), ), if (device['bind_type'] == 1) Padding( @@ -303,42 +286,36 @@ class DeviceInfoWidget extends GetView { ['shareNum'] ?? 0) .toString(), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF85F5FF), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF85F5FF), + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ), if (device['bind_type'] == 1) Text( '人', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + color: Colors.white, + ), ), if (device['bind_type'] == 2) Text( '来自', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + color: Colors.white, + ), ), if (device['bind_type'] == 2) Padding( @@ -347,28 +324,24 @@ class DeviceInfoWidget extends GetView { 5, 0, 5, 0), child: Text( '${device['suname']?.length > 5 ? device['suname'].substring(0, 5) + '...' : device['suname']}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF85F5FF), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF85F5FF), + fontSize: + AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ), if (device['bind_type'] == 2) Text( '的分享', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 21.rpx, - letterSpacing: 0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 21.rpx, + letterSpacing: 0, + color: Colors.white, + ), ), ], ), @@ -407,14 +380,12 @@ class DeviceInfoWidget extends GetView { SizedBox(width: 5), Text( '睡眠报告', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 21.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 21.rpx, + letterSpacing: 0, + ), ), ], ), diff --git a/lib/pages/mh_page/device/mht_bind_device_success.dart b/lib/pages/mh_page/device/mht_bind_device_success.dart index 623e36c..2445fb6 100644 --- a/lib/pages/mh_page/device/mht_bind_device_success.dart +++ b/lib/pages/mh_page/device/mht_bind_device_success.dart @@ -67,12 +67,12 @@ class _MHTBindDeviceSuccessState extends State { /// 居中标题 Text( '绑定成功.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -185,14 +185,12 @@ class _MHTBindDeviceSuccessState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '绑定成功.绑定成功'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -206,14 +204,12 @@ class _MHTBindDeviceSuccessState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '绑定成功.分享标题'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -227,14 +223,12 @@ class _MHTBindDeviceSuccessState extends State { alignment: AlignmentDirectional(-1, 0), child: Text( '绑定成功.分享内容'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -299,15 +293,13 @@ class _MHTBindDeviceSuccessState extends State { ), Text( '绑定成功.立即分享'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: stringToColor("#003058"), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#003058"), + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -384,15 +376,13 @@ class _MHTBindDeviceSuccessState extends State { children: [ Text( '绑定成功.返回'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: stringToColor("#003058"), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#003058"), + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), diff --git a/lib/pages/mh_page/device/mht_bind_device_type.dart b/lib/pages/mh_page/device/mht_bind_device_type.dart index 7ceb25d..41f1b57 100644 --- a/lib/pages/mh_page/device/mht_bind_device_type.dart +++ b/lib/pages/mh_page/device/mht_bind_device_type.dart @@ -76,12 +76,12 @@ class _MHTBindDeviceTypePageState extends State { /// 居中标题 Text( '添加设备'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 diff --git a/lib/pages/mh_page/device/mht_blueteeth_device_page.dart b/lib/pages/mh_page/device/mht_blueteeth_device_page.dart index c518bc0..dcb9acd 100644 --- a/lib/pages/mh_page/device/mht_blueteeth_device_page.dart +++ b/lib/pages/mh_page/device/mht_blueteeth_device_page.dart @@ -111,13 +111,14 @@ class _MHTBlueteethDevicePageState extends State { } void _startScanning() async { - if (!mounted || isScanning || !mhtBlueToothController.shouldScan.value) return; + if (!mounted || isScanning || !mhtBlueToothController.shouldScan.value) + return; _scanSubscription?.cancel(); var bluetoothState = await FlutterBluePlus.isOn; mhtBlueToothController.model.bluetooth = bluetoothState; mhtBlueToothController.updateAll(); - + if (!bluetoothState && !_isDialogShowing) { _isDialogShowing = true; mhtBlueToothController.model.blueRawData = []; @@ -139,7 +140,8 @@ class _MHTBlueteethDevicePageState extends State { if (!mounted) return; final signalThreshold = mhtBlueToothController.model.singal!; - final searchKey = mhtBlueToothController.search.value.trim().toLowerCase(); + final searchKey = + mhtBlueToothController.search.value.trim().toLowerCase(); final filteredResults = results.where((r) { final localName = r.advertisementData.localName; @@ -280,12 +282,12 @@ class _MHTBlueteethDevicePageState extends State { children: [ Text( '添加设备'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -337,14 +339,12 @@ class _MHTBlueteethDevicePageState extends State { false) ? "等待扫描".tr : '扫描中'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: stringToColor("#003058"), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: stringToColor("#003058"), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ); }), ), @@ -372,22 +372,18 @@ class _MHTBlueteethDevicePageState extends State { children: [ Text( '最小信号强度'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: stringToColor("#003058"), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: stringToColor("#003058"), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Expanded( child: Obx(() { return Slider( activeColor: Color(0xFF1FCC9B), - inactiveColor: - FlutterFlowTheme.of(context) - .alternate, + inactiveColor: Colors.white, min: -100, max: 50, value: @@ -406,14 +402,12 @@ class _MHTBlueteethDevicePageState extends State { Obx(() { return Text( '${mhtBlueToothController.model.singal!.toInt()}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: stringToColor("#003058"), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: stringToColor("#003058"), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ); }), ].divide(SizedBox(width: 30.rpx)), @@ -456,8 +450,7 @@ class _MHTBlueteethDevicePageState extends State { width: 100.rpx, height: 90.rpx, decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, + color: Colors.white, ), child: Align( alignment: @@ -474,23 +467,17 @@ class _MHTBlueteethDevicePageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '检索设备'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( @@ -513,9 +500,7 @@ class _MHTBlueteethDevicePageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of( - context) - .error, + color: Colors.red, width: 1.rpx, ), borderRadius: @@ -525,9 +510,7 @@ class _MHTBlueteethDevicePageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of( - context) - .error, + color: Colors.red, width: 1.rpx, ), borderRadius: @@ -538,14 +521,11 @@ class _MHTBlueteethDevicePageState extends State { fillColor: themeController .currentColor.sc22, ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), cursorColor: stringToColor("#003058"), ), @@ -579,14 +559,12 @@ class _MHTBlueteethDevicePageState extends State { }, child: Text( '搜索'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: stringToColor("#333333"), - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: stringToColor("#333333"), + ), ), ), ].divide(SizedBox(width: 26.rpx)), @@ -609,14 +587,12 @@ class _MHTBlueteethDevicePageState extends State { return Text( '匹配出的外围设备'.tr + "(${mhtBlueToothController.model.deviceDataStatus!.length})", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ); }), ), @@ -690,14 +666,12 @@ class _MHTBlueteethDevicePageState extends State { Expanded( child: Text( '蓝牙绑定提示'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController.currentColor.sc4, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc4, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ].divide(SizedBox(width: 23.rpx)), @@ -714,4 +688,4 @@ class _MHTBlueteethDevicePageState extends State { ), ); } -} \ No newline at end of file +} diff --git a/lib/pages/mh_page/device/mht_device_calibration copy.dart b/lib/pages/mh_page/device/mht_device_calibration copy.dart index 41df839..ff62d60 100644 --- a/lib/pages/mh_page/device/mht_device_calibration copy.dart +++ b/lib/pages/mh_page/device/mht_device_calibration copy.dart @@ -593,8 +593,8 @@ class _MHTCalibrationPageCopyState extends State { padding: EdgeInsetsDirectional.fromSTEB( 100.rpx, 0.rpx, 100.rpx, 60.rpx), child: CustomCard( - borderRadius: AppConstants() - .normal_container_radius, + borderRadius: + AppConstants().normal_container_radius, onTap: () async { if (deviceCalibrationController.flag.value == 2) { @@ -763,16 +763,13 @@ class _MHTCalibrationPageCopyState extends State { 0) { return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: - stringToColor("#003058"), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#003058"), + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -782,16 +779,14 @@ class _MHTCalibrationPageCopyState extends State { .statusContext.value = ""; return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -799,16 +794,14 @@ class _MHTCalibrationPageCopyState extends State { 2) { return Text( '重新校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } return Container(); diff --git a/lib/pages/mh_page/device/mht_device_calibration.dart b/lib/pages/mh_page/device/mht_device_calibration.dart index b89c5c7..0028a83 100644 --- a/lib/pages/mh_page/device/mht_device_calibration.dart +++ b/lib/pages/mh_page/device/mht_device_calibration.dart @@ -645,29 +645,24 @@ class _MHTCalibrationPageState extends State { currentCalibrationStep.value == 2) { return Text( '开始另外一侧校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: - stringToColor("#003058"), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#003058"), + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } return Text( '开始校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: stringToColor("#003058"), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#003058"), + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -677,16 +672,14 @@ class _MHTCalibrationPageState extends State { .statusContext.value = ""; return Text( '校准中...'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController + .currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } if (deviceCalibrationController @@ -694,15 +687,13 @@ class _MHTCalibrationPageState extends State { 2) { return Text( '重新校准'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: stringToColor("#003058"), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: stringToColor("#003058"), + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), ); } return Container(); diff --git a/lib/pages/mh_page/device/mht_wifi_page.dart b/lib/pages/mh_page/device/mht_wifi_page.dart index e2a5d95..315d1ba 100644 --- a/lib/pages/mh_page/device/mht_wifi_page.dart +++ b/lib/pages/mh_page/device/mht_wifi_page.dart @@ -144,13 +144,12 @@ class _MHTWifiPageState extends State { children: [ Text( 'wifi配置'.tr, - style: - FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), SizedBox( width: 14.rpx, @@ -217,13 +216,11 @@ class _MHTWifiPageState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '下一步'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: stringToColor("#003058"), - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: stringToColor("#003058"), + letterSpacing: 0.0, + ), ), ), ), @@ -355,15 +352,13 @@ class _MHTWifiPageState extends State { children: [ Text( '可用WLAN'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: + themeController.currentColor.sc3, + ), ), ], ), @@ -429,21 +424,19 @@ class _MHTWifiPageState extends State { InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Inter', - fontSize: - 26.rpx, - letterSpacing: - 0.0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Inter', + fontSize: + 26.rpx, + letterSpacing: + 0.0, + ), hintText: '输入wifi密码' .tr, - hintStyle: FlutterFlowTheme.of(context).labelMedium.override( + hintStyle: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -483,8 +476,6 @@ class _MHTWifiPageState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -496,8 +487,6 @@ class _MHTWifiPageState extends State { OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1 .rpx, ), @@ -533,7 +522,7 @@ class _MHTWifiPageState extends State { ), ), ), - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Inter', fontSize: 26 @@ -630,18 +619,13 @@ class _MHTWifiPageState extends State { children: [ Text( wifiItem['ssid'] ?? '', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: - themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), if (blueteethBindController .selectWifi.value == @@ -767,15 +751,13 @@ class _MHTWifiPageState extends State { ), Text( '刷新'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(width: 26.rpx)), ), diff --git a/lib/pages/mh_page/device_people_info.dart b/lib/pages/mh_page/device_people_info.dart index 94e8bf5..6b1ce1e 100644 --- a/lib/pages/mh_page/device_people_info.dart +++ b/lib/pages/mh_page/device_people_info.dart @@ -23,12 +23,12 @@ class DevicePeopleInfo extends GetView { alignment: Alignment.centerLeft, child: Text( '$str', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ); } @@ -125,13 +125,11 @@ class DevicePeopleInfo extends GetView { alignment: Alignment.centerLeft, child: Text( '设备信息', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + ), ), ), getInfoRow( @@ -173,14 +171,12 @@ class DevicePeopleInfo extends GetView { alignment: Alignment.centerLeft, child: Text( '人员资料${index == 0 ? "A" : "B"}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 32.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 32.rpx, + letterSpacing: 0, + ), ), ), if (location_.isNotEmpty) diff --git a/lib/pages/mh_page/device_share_page.dart b/lib/pages/mh_page/device_share_page.dart index f9210af..1315d8e 100644 --- a/lib/pages/mh_page/device_share_page.dart +++ b/lib/pages/mh_page/device_share_page.dart @@ -113,26 +113,22 @@ class ShareDeviceWidget extends GetView { children: [ Text( '将以下设备分享给您的家人或朋友 ', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0.0, - lineHeight: 1, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0.0, + height: 1, + ), ), Text( '设备ID:${deviceController.model.deviceMain['mac']}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF6BFDAC), - fontSize: 26.rpx, - letterSpacing: 0.0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF6BFDAC), + fontSize: 26.rpx, + letterSpacing: 0.0, + height: 1), ), ].divide(SizedBox(height: 65.rpx)), ), @@ -157,16 +153,12 @@ class ShareDeviceWidget extends GetView { controller: _phoneController, decoration: InputDecoration( hintText: '请输入对方手机号', - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 36.rpx, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: + const Color(0xFF929699), + fontSize: 36.rpx, + ), enabledBorder: const UnderlineInputBorder( borderSide: BorderSide( @@ -195,15 +187,11 @@ class ShareDeviceWidget extends GetView { const EdgeInsets.only( left: 10, bottom: 5), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 36.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 36.rpx, + ), validator: (value) { if (value == null || value.isEmpty) { @@ -439,16 +427,12 @@ class ShareDeviceWidget extends GetView { children: [ Text( '允许对方控制该设备', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Radio( value: 1, @@ -494,16 +478,12 @@ class ShareDeviceWidget extends GetView { children: [ Text( '仅允许对方查看该设备', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), Radio( value: 2, @@ -556,15 +536,12 @@ class ShareDeviceWidget extends GetView { EdgeInsetsDirectional.fromSTEB( 30.rpx, 0, 30.rpx, 0), color: const Color(0xFF84F5FF), - textStyle: - FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF011D33), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + textStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF011D33), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), elevation: 0, borderRadius: BorderRadius.circular(50), @@ -596,14 +573,12 @@ class ShareDeviceWidget extends GetView { .fromSTEB(14, 0, 0, 16), child: Text( '已分享用户', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0.0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0.0, + height: 1), ), ), ), diff --git a/lib/pages/mh_page/edit_address_page.dart b/lib/pages/mh_page/edit_address_page.dart index 461cd77..c639c08 100644 --- a/lib/pages/mh_page/edit_address_page.dart +++ b/lib/pages/mh_page/edit_address_page.dart @@ -181,10 +181,7 @@ class EditAddressPage extends GetView -1, 0), child: Text( '地址信息', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', color: Colors @@ -273,7 +270,7 @@ class EditAddressPage extends GetView }, side: BorderSide( width: 1.5, - color: FlutterFlowTheme.of(context).secondaryText, + color:Colors.white, ), activeColor: const Color(0xFF84F5FF), checkColor: Color(0xFF011D33), @@ -285,10 +282,7 @@ class EditAddressPage extends GetView ), Text( '默认', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: @@ -349,10 +343,7 @@ class EditAddressPage extends GetView children: [ Text( '收件人', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: @@ -400,19 +391,13 @@ class EditAddressPage extends GetView 0, 10, 18), - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -471,10 +456,7 @@ class EditAddressPage extends GetView 8), ), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( + style:TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -529,10 +511,7 @@ class EditAddressPage extends GetView children: [ Text( '手机号', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: @@ -582,19 +561,13 @@ class EditAddressPage extends GetView 0, 10, 18), - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -653,10 +626,7 @@ class EditAddressPage extends GetView 8), ), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -719,10 +689,7 @@ class EditAddressPage extends GetView // }, child: Text( '所在地区', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', fontSize: @@ -777,11 +744,11 @@ class EditAddressPage extends GetView false, decoration: InputDecoration( contentPadding: const EdgeInsetsDirectional.fromSTEB(10, 0, 10, 18), - labelStyle: FlutterFlowTheme.of(context).labelMedium.override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), - hintStyle: FlutterFlowTheme.of(context).labelMedium.override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), @@ -847,15 +814,12 @@ class EditAddressPage extends GetView Icon( Icons.arrow_forward_ios, color: - FlutterFlowTheme.of(context).secondaryText, + Colors.white, size: 12, ), )), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -918,7 +882,7 @@ class EditAddressPage extends GetView children: [ Text( '详细地址', - style: FlutterFlowTheme.of(context).bodyMedium.override( + style:TextStyle( fontFamily: 'Readex Pro', fontSize: @@ -988,19 +952,13 @@ class EditAddressPage extends GetView 10, 10, 10), - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + labelStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: 0, ), - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( + hintStyle: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -1055,10 +1013,7 @@ class EditAddressPage extends GetView .circular(8), ), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', letterSpacing: @@ -1147,9 +1102,7 @@ class EditAddressPage extends GetView ), child: Text( "保存", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Readex Pro', color: stringToColor("#011D33"), letterSpacing: 0, diff --git a/lib/pages/mh_page/edit_bed.dart b/lib/pages/mh_page/edit_bed.dart index 7e9f7d3..b056d80 100644 --- a/lib/pages/mh_page/edit_bed.dart +++ b/lib/pages/mh_page/edit_bed.dart @@ -1,4 +1,3 @@ -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:ef/ef.dart'; import 'package:flutter/material.dart'; import 'package:vbvs_app/common/color/ServiceConstant.dart'; @@ -123,22 +122,18 @@ class _EditBedPageState extends State { contentPadding: const EdgeInsetsDirectional .fromSTEB(10, 0, 10, 0), - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - fontSize: 36.rpx, // 设置输入文字大小 - color: Colors.white, // 设置输入文字颜色 - ), - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - color: Color(0xFF929699), - fontSize: 36.rpx, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + letterSpacing: 0, + fontSize: 36.rpx, // 设置输入文字大小 + color: Colors.white, // 设置输入文字颜色 + ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + letterSpacing: 0, + color: Color(0xFF929699), + fontSize: 36.rpx, + ), enabledBorder: UnderlineInputBorder( borderSide: const BorderSide( color: Color(0x00000000), @@ -173,12 +168,10 @@ class _EditBedPageState extends State { BorderRadius.circular(8), ), ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + letterSpacing: 0, + ), ), )) ], diff --git a/lib/pages/mh_page/experience_store_widget.dart b/lib/pages/mh_page/experience_store_widget.dart index 2c1756b..44d8438 100644 --- a/lib/pages/mh_page/experience_store_widget.dart +++ b/lib/pages/mh_page/experience_store_widget.dart @@ -55,12 +55,12 @@ class ExperienceStoreWidget extends GetView { child: Text( // experienceStoreModel.name ?? '未命名', data["name"] ?? '', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0, + ), ), ), ), @@ -97,14 +97,12 @@ class ExperienceStoreWidget extends GetView { alignment: const AlignmentDirectional(-1, 0), child: Text( '地址:${data["addressDetail"]}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF929699), - fontSize: 20.rpx, - letterSpacing: 0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF929699), + fontSize: 20.rpx, + letterSpacing: 0, + height: 1), ), ), ), @@ -113,14 +111,12 @@ class ExperienceStoreWidget extends GetView { alignment: const AlignmentDirectional(-1, 0), child: Text( '电话:${data["hotline"]}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF929699), - fontSize: 20.rpx, - letterSpacing: 0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF929699), + fontSize: 20.rpx, + letterSpacing: 0, + height: 1), ), ), ), @@ -171,14 +167,12 @@ class ExperienceStoreWidget extends GetView { ), Text( '咨询', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ].divide(const SizedBox(width: 13)), ), @@ -230,14 +224,12 @@ class ExperienceStoreWidget extends GetView { ), Text( '导航', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ].divide(const SizedBox(width: 13)), ), @@ -268,14 +260,12 @@ class ExperienceStoreWidget extends GetView { padding: const EdgeInsetsDirectional.fromSTEB( 0, 0, 0, 0), color: Color(0xFF84F5FF), - textStyle: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF011D33), - fontSize: 26.rpx, - letterSpacing: 0, - ), + textStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF011D33), + fontSize: 26.rpx, + letterSpacing: 0, + ), elevation: 0, borderSide: const BorderSide( color: Colors.transparent, diff --git a/lib/pages/mh_page/homepage/component/HomeDeviceStausWidget.dart b/lib/pages/mh_page/homepage/component/HomeDeviceStausWidget.dart index c4def6a..602d80a 100644 --- a/lib/pages/mh_page/homepage/component/HomeDeviceStausWidget.dart +++ b/lib/pages/mh_page/homepage/component/HomeDeviceStausWidget.dart @@ -4,6 +4,7 @@ import 'package:flutterflow_ui/flutterflow_ui.dart'; import 'package:vbvs_app/common/color/appConstants.dart'; import 'package:vbvs_app/common/util/FitTool.dart'; import 'package:vbvs_app/component/tool/CustomCard.dart'; +import 'package:vbvs_app/component/tool/TopSlideNotification.dart'; class HomeDeviceStausWidget extends StatefulWidget { final deviceStatus; @@ -73,6 +74,7 @@ class _HomeDeviceStausWidgetState extends State { borderRadius: 10.rpx, onTap: () { // 点击回调逻辑放这里 + TopSlideNotification.show(context,text: "功能开发中...".tr); }, colors: AppConstants().mhtButtongradientColors, // 你原本没有渐变,单色即可 diff --git a/lib/pages/mh_page/homepage/mht_sleep_report_page.dart b/lib/pages/mh_page/homepage/mht_sleep_report_page.dart index a620fd8..e1dd579 100644 --- a/lib/pages/mh_page/homepage/mht_sleep_report_page.dart +++ b/lib/pages/mh_page/homepage/mht_sleep_report_page.dart @@ -16,6 +16,7 @@ import 'package:vbvs_app/pages/mh_page/FloatingSvgIcon.dart'; import 'package:vbvs_app/pages/mh_page/homepage/component/HomeDeviceWidget.dart'; import 'package:vbvs_app/pages/mh_page/homepage/controller/mht_home_controller.dart'; import 'package:vbvs_app/pages/sleep_report/mht_new_sleep_report_page.dart'; +import 'package:vbvs_app/pages/sleep_report/new_sleep_report_page.dart'; class MhtSleepReportPage extends StatefulWidget { const MhtSleepReportPage({super.key}); @@ -32,74 +33,13 @@ class _MhtSleepReportPageState extends State { var formFieldController = FormFieldController(null); var personInfo = {}.obs; - GlobalController gloablController = Get.find(); - WeatherModelController weatherModelController = Get.find(); - // var selectedDayIndex = (6).obs; - @override void initState() { super.initState(); if (userInfoController.model.login == 1) { //查询人员信息列表 deviceController.getPersonList(); - //请求绑定设备列表 - // homeController.getSleepReport(); - deviceController.getDeviceNum().then((apiResponse) { - if (apiResponse.code != HttpStatusCodes.ok) { - TopSlideNotification.show( - Get.context!, - text: apiResponse.msg!, - textColor: themeController.currentColor.sc9, - ); - } - }); - deviceController.getDeviceList(group: 'room').then((apiResponse) { - if (apiResponse.code != HttpStatusCodes.ok) { - TopSlideNotification.show( - Get.context!, - text: apiResponse.msg!, - textColor: themeController.currentColor.sc9, - ); - } else { - //请求睡眠报告 - // deviceController.getSleepReport(); - } - }); } - WidgetsBinding.instance.addPostFrameCallback((_) { - if (homeController.sleepDays.value.isNotEmpty) { - homeController.selectedDayIndex.value = - homeController.sleepDays.value.length - 1; - } - }); - } - - getWeekName(int i) { - String v = ""; - switch (i) { - case 1: - v = "周一"; - break; - case 2: - v = "周二"; - break; - case 3: - v = "周三"; - break; - case 4: - v = "周四"; - break; - case 5: - v = "周五"; - break; - case 6: - v = "周六"; - break; - case 7: - v = "周日"; - break; - } - return v; } @override @@ -174,9 +114,6 @@ class _MhtSleepReportPageState extends State { 0.rpx, 40.rpx, 30.rpx, 10.rpx), child: Container( width: MediaQuery.sizeOf(context).width, - // height: - // MediaQuery.sizeOf(context).height * - // 0.033, constraints: BoxConstraints( minHeight: 60.rpx, ), @@ -329,38 +266,39 @@ class _MhtSleepReportPageState extends State { } return Container(); }), + Obx(() { - if (userInfoController.model.login! != null && - userInfoController.model.login! == 1) { - final list = deviceController.personnelList.value; - if (list.isNotEmpty && - formFieldController.value == null) { - WidgetsBinding.instance.addPostFrameCallback((_) { - formFieldController.value = list[0]["mac"]; - personInfo.value = list[0]; - homeController.selectPerson.value = list[0]; - homeController.selectDevcie.value = list[0]["mac"]; - deviceController - .getSleeps(formFieldController.value); - homeController.updateAll(); - }); - } - if (homeController.selectDevcie.value != null && - homeController.selectDevcie.value!.isNotEmpty) - return Expanded( - child: MHTNewSleepReportPage( - data: { - 'date': DateTime.now().millisecondsSinceEpoch, - 'mac': homeController.selectDevcie.value, - 'person': homeController.selectPerson.value, - 'backgroundImg': - 'assets/images/new_background.png', - }, - ), - ); - } + if (homeController.selectDevcie.value != null && + homeController.selectDevcie.value!.isNotEmpty) + return Expanded( + child: NewSleepReportPage( + data: { + "tag": "123", + 'date': DateTime.now().millisecondsSinceEpoch, + 'mac': homeController.selectDevcie.value, + 'person': homeController.selectPerson.value, + 'backgroundImg': + 'assets/images/new_background.png', + 'arrow': false, + }, + ), + ); + // } return Container(); }), + + // Expanded( + // child: NewSleepReportPage( + // data: { + // "tag": "123", + // 'date': DateTime.now().millisecondsSinceEpoch, + // 'mac': homeController.selectDevcie.value, + // 'person': homeController.selectPerson.value, + // 'backgroundImg': 'assets/images/new_background.png', + // }, + // ), + // ), + // } ], ), ), diff --git a/lib/pages/mh_page/homepage/new_Home_page.dart b/lib/pages/mh_page/homepage/new_Home_page.dart index 8ea666a..099eaa9 100644 --- a/lib/pages/mh_page/homepage/new_Home_page.dart +++ b/lib/pages/mh_page/homepage/new_Home_page.dart @@ -9,6 +9,7 @@ import 'package:vbvs_app/common/util/MyUtils.dart'; import 'package:vbvs_app/component/NullDataComponentWidget.dart'; import 'package:vbvs_app/component/tool/ClickableContainer.dart'; import 'package:vbvs_app/component/tool/TopSlideNotification.dart'; +import 'package:vbvs_app/controller/home/home_controller.dart'; import 'package:vbvs_app/controller/main_bottom/global_controller.dart'; import 'package:vbvs_app/controller/user_info_controller.dart'; import 'package:vbvs_app/controller/weather/weather_controller.dart'; @@ -628,19 +629,17 @@ class _NewHomePageState extends State { children: [ Text( day['week'], - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - 30.rpx, - letterSpacing: - 0, - color: - stringToColor("#FFFFFF"), - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + 30.rpx, + letterSpacing: + 0, + color: stringToColor( + "#FFFFFF"), + ), ), SizedBox( height: 12 @@ -648,19 +647,17 @@ class _NewHomePageState extends State { Text( day['date'], // "哈哈", - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - letterSpacing: - 0, - fontSize: - 22.rpx, - color: - stringToColor("#929699"), - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: + 0, + fontSize: + 22.rpx, + color: stringToColor( + "#929699"), + ), ), SizedBox( height: 39 @@ -797,17 +794,12 @@ class _NewHomePageState extends State { SizedBox(width: 20.rpx), Text( '添加新设备'.tr, - style: - FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( - "#85F5FF"), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#85F5FF"), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ], ), diff --git a/lib/pages/mh_page/issue_list_page.dart b/lib/pages/mh_page/issue_list_page.dart index fe9c891..fd5278c 100644 --- a/lib/pages/mh_page/issue_list_page.dart +++ b/lib/pages/mh_page/issue_list_page.dart @@ -96,14 +96,12 @@ class IssueListPage extends GetView { alignment: AlignmentDirectional(-1, 0), child: Text( '暂无内容!', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: AppFontsize.title_size, - fontWeight: FontWeight.w600, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: AppFontsize.title_size, + fontWeight: FontWeight.w600, + ), ), ), ), diff --git a/lib/pages/mh_page/issue_preview_widget.dart b/lib/pages/mh_page/issue_preview_widget.dart index 5fa9613..e0e9241 100644 --- a/lib/pages/mh_page/issue_preview_widget.dart +++ b/lib/pages/mh_page/issue_preview_widget.dart @@ -67,12 +67,13 @@ class IssuePreviewWidget extends GetView { child: Text( issueListController.model.issueList![index]['title'] ?? '', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Color(0xFFFFFFFF), - fontSize: AppFontsize.title_size, - letterSpacing: 0, - lineHeight: 1), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFFFFFFFF), + fontSize: AppFontsize.title_size, + letterSpacing: 0, + // height: 1, + ), ), ), ), diff --git a/lib/pages/mh_page/message_page.dart b/lib/pages/mh_page/message_page.dart index 6fea360..bffeda1 100644 --- a/lib/pages/mh_page/message_page.dart +++ b/lib/pages/mh_page/message_page.dart @@ -286,12 +286,12 @@ class _MessagePageState extends State { SizedBox(width: 14.rpx), // 加号和文字间距 Text( '全部已读', - style: FlutterFlowTheme.of(context).titleSmall.override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ], ), diff --git a/lib/pages/mh_page/my_experience_widget.dart b/lib/pages/mh_page/my_experience_widget.dart index de35e9c..2e80f6f 100644 --- a/lib/pages/mh_page/my_experience_widget.dart +++ b/lib/pages/mh_page/my_experience_widget.dart @@ -39,7 +39,6 @@ class MyExperienceWidget extends GetView { minHeight: 170, ), decoration: BoxDecoration( - color: FlutterFlowTheme.of(context).secondaryBackground, borderRadius: BorderRadius.circular(16), ), child: Padding( @@ -47,15 +46,11 @@ class MyExperienceWidget extends GetView { child: Container( width: MediaQuery.sizeOf(context).width, height: MediaQuery.sizeOf(context).height * 0.187, - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context).secondaryBackground, - ), + decoration: BoxDecoration(), child: Container( width: MediaQuery.sizeOf(context).width, height: MediaQuery.sizeOf(context).height * 0.187, - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context).secondaryBackground, - ), + decoration: BoxDecoration(), child: Column( mainAxisSize: MainAxisSize.max, children: [ @@ -68,30 +63,22 @@ class MyExperienceWidget extends GetView { constraints: const BoxConstraints( minHeight: 20, ), - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Container( width: MediaQuery.sizeOf(context).width, height: MediaQuery.sizeOf(context).height * 0.018, - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Align( alignment: const AlignmentDirectional(0, 0), child: Text( // widget!.name, "体验时间:${DateFormat("yyyy-MM-dd HH:mm").format(DateTime.fromMillisecondsSinceEpoch(int.parse("${bookExperienceListController.model.bookInfoList[index]["bookTimeStart"]}")))}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF182B7C), - fontSize: AppFontsize.title_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF182B7C), + fontSize: AppFontsize.title_size, + letterSpacing: 0, + ), ), ), ), @@ -113,20 +100,14 @@ class MyExperienceWidget extends GetView { constraints: const BoxConstraints( minHeight: 55, ), - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Container( width: MediaQuery.sizeOf(context).width, height: MediaQuery.sizeOf(context).height * 0.034, constraints: const BoxConstraints( minHeight: 55, ), - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Column( mainAxisSize: MainAxisSize.max, children: [ @@ -136,15 +117,12 @@ class MyExperienceWidget extends GetView { const AlignmentDirectional(-1, 0), child: Text( '门店:${data["name"] ?? ""}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF9EA4B7), - fontSize: - AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF9EA4B7), + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ), ), @@ -154,15 +132,12 @@ class MyExperienceWidget extends GetView { const AlignmentDirectional(-1, 0), child: Text( '地址:${data['addressDetail'] ?? ""}', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF9EA4B7), - fontSize: - AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF9EA4B7), + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ), ), @@ -172,15 +147,12 @@ class MyExperienceWidget extends GetView { const AlignmentDirectional(-1, 0), child: Text( '电话:${data["hotline"]} ', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: const Color(0xFF9EA4B7), - fontSize: - AppFontsize.small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color(0xFF9EA4B7), + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ), ), @@ -198,17 +170,11 @@ class MyExperienceWidget extends GetView { ), width: MediaQuery.sizeOf(context).width, height: MediaQuery.sizeOf(context).height * 0.038, - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Container( width: MediaQuery.sizeOf(context).width, height: MediaQuery.sizeOf(context).height * 0.038, - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: // Generated code for this Row Widget... Row( mainAxisSize: MainAxisSize.max, @@ -230,10 +196,7 @@ class MyExperienceWidget extends GetView { constraints: const BoxConstraints( maxWidth: 50, ), - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Row( mainAxisSize: MainAxisSize.max, children: [ @@ -246,17 +209,14 @@ class MyExperienceWidget extends GetView { ), Text( '咨询', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - // color: Color(0xFF9EA4B7), - color: - const Color(0xFF333333), - fontSize: AppFontsize - .small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + // color: Color(0xFF9EA4B7), + color: const Color(0xFF333333), + fontSize: + AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ].divide(const SizedBox(width: 13)), ), @@ -296,10 +256,7 @@ class MyExperienceWidget extends GetView { constraints: const BoxConstraints( maxWidth: 50, ), - decoration: BoxDecoration( - color: FlutterFlowTheme.of(context) - .secondaryBackground, - ), + decoration: BoxDecoration(), child: Row( mainAxisSize: MainAxisSize.max, children: [ @@ -312,17 +269,14 @@ class MyExperienceWidget extends GetView { ), Text( '导航', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - // color: Color(0xFF9EA4B7), - color: - const Color(0xFF333333), - fontSize: AppFontsize - .small_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + // color: Color(0xFF9EA4B7), + color: const Color(0xFF333333), + fontSize: + AppFontsize.small_text_size, + letterSpacing: 0, + ), ), ].divide(const SizedBox(width: 13)), ), @@ -393,15 +347,12 @@ class MyExperienceWidget extends GetView { 2 ? const Color(0xFFD3B684) : stringToColor("#D3D3D3"), - textStyle: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: - AppFontsize.small_text_size, - letterSpacing: 0, - ), + textStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize.small_text_size, + letterSpacing: 0, + ), elevation: 0, borderSide: const BorderSide( color: Colors.transparent, diff --git a/lib/pages/mh_page/new_mine_page.dart b/lib/pages/mh_page/new_mine_page.dart index 27c6ad6..91ccc68 100644 --- a/lib/pages/mh_page/new_mine_page.dart +++ b/lib/pages/mh_page/new_mine_page.dart @@ -439,12 +439,12 @@ class _MinePageState extends State { login == 1 ? (userInfoController.model.user!.nick_name ?? '未命名'.tr) : "未命名".tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: themeController.currentColor.sc3, - fontSize: AppConstants().title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc3, + fontSize: AppConstants().title_text_fontSize, + letterSpacing: 0.0, + ), ), Text( login == 1 @@ -459,12 +459,12 @@ class _MinePageState extends State { } })() : "未知数据".tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: themeController.currentColor.sc4, - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc4, + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(height: 20.rpx)), ); diff --git a/lib/pages/mh_page/new_settingPage.dart b/lib/pages/mh_page/new_settingPage.dart index 06c9816..39c879f 100644 --- a/lib/pages/mh_page/new_settingPage.dart +++ b/lib/pages/mh_page/new_settingPage.dart @@ -181,17 +181,14 @@ class _SettingPageState extends State { children: [ Text( '当前版本', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Colors.white, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - lineHeight: 1.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.white, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + // height: 1.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -239,16 +236,14 @@ class _SettingPageState extends State { children: [ Text( '切换语言', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Colors.white, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - lineHeight: 1.0), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.white, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + // height: 1.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -262,17 +257,13 @@ class _SettingPageState extends State { .value ?.language_name ?? '简体中文', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Color(0xFFD9E3EB), - fontSize: 26.rpx, - letterSpacing: 0.0, - lineHeight: 1.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFD9E3EB), + fontSize: 26.rpx, + letterSpacing: 0.0, + // height: 1.0, + ), ); }), SvgPicture.asset( @@ -312,17 +303,14 @@ class _SettingPageState extends State { children: [ Text( '设置页.关于我们'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Colors.white, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - lineHeight: 1.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.white, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + // height: 1.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -364,17 +352,14 @@ class _SettingPageState extends State { children: [ Text( '设置页.用户协议'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Colors.white, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - lineHeight: 1.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.white, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + // height: 1.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -416,17 +401,14 @@ class _SettingPageState extends State { children: [ Text( '设置页.隐私协议'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Colors.white, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - lineHeight: 1.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.white, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + // height: 1.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -490,15 +472,13 @@ class _SettingPageState extends State { children: [ Text( '设置页.退出登录'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: Color(0xFF003058), - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: Color(0xFF003058), + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -537,16 +517,13 @@ class _SettingPageState extends State { children: [ Text( '设置页.注销账号'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: - themeController.currentColor.sc9, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc9, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -582,30 +559,24 @@ class _SettingPageState extends State { children: [ Text( 'ICP备案号:浙ICP备2023000785号-1'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc4, - fontFamily: 'Inter', - fontSize: AppConstants() - .smaller_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc4, + fontFamily: 'Inter', + fontSize: AppConstants() + .smaller_text_fontSize, + letterSpacing: 0.0, + ), ), Text( 'Copyright © 202-2025 嘉兴太和信息技术有限责任公司 版权所有' .tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController - .currentColor.sc4, - fontFamily: 'Inter', - fontSize: AppConstants() - .smaller_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc4, + fontFamily: 'Inter', + fontSize: AppConstants() + .smaller_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( height: 17.rpx, diff --git a/lib/pages/mh_page/people_info.dart b/lib/pages/mh_page/people_info.dart index fd1f061..72b0233 100644 --- a/lib/pages/mh_page/people_info.dart +++ b/lib/pages/mh_page/people_info.dart @@ -1,6 +1,5 @@ import 'dart:async'; -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:ef/ef.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; @@ -159,14 +158,12 @@ class PeopleInfoPage extends GetView { // ), child: Text( "保存", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0XFF011D33), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0XFF011D33), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ), )) @@ -234,15 +231,12 @@ class PeopleInfoPage extends GetView { children: [ Text( '姓名', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 30.rpx, + letterSpacing: 0, + ), ), Container( width: 300.rpx, @@ -305,15 +299,12 @@ class PeopleInfoPage extends GetView { children: [ Text( '性别', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 30.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () { @@ -357,16 +348,13 @@ class PeopleInfoPage extends GetView { '${controller.model.peopleList[index]['gender'] == 1 ? '男' : '女'}', textAlign: TextAlign.right, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0, + ), ), ), SizedBox( @@ -398,14 +386,12 @@ class PeopleInfoPage extends GetView { children: [ Text( '身高(cm)', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 30.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () { @@ -442,15 +428,11 @@ class PeopleInfoPage extends GetView { null ? "${controller.model.peopleList[index]['height']} cm" : '', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + ), ), SizedBox(width: 16.rpx), Icon(Icons.expand_more, @@ -476,14 +458,12 @@ class PeopleInfoPage extends GetView { children: [ Text( '体重(kg)', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 30.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () { @@ -520,15 +500,11 @@ class PeopleInfoPage extends GetView { null ? "${controller.model.peopleList[index]['weight']} kg" : '', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + ), ), SizedBox(width: 16.rpx), Icon(Icons.expand_more, @@ -555,15 +531,12 @@ class PeopleInfoPage extends GetView { children: [ Text( '生日', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 30.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () { @@ -621,16 +594,13 @@ class PeopleInfoPage extends GetView { : '', textAlign: TextAlign.right, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0, + ), ), ), SizedBox( @@ -662,14 +632,12 @@ class PeopleInfoPage extends GetView { children: [ Text( '联系人', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 30.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 30.rpx, + letterSpacing: 0, + ), ), Container( width: 300.rpx, diff --git a/lib/pages/mh_page/repair_history_page.dart b/lib/pages/mh_page/repair_history_page.dart index 33a2cec..f741981 100644 --- a/lib/pages/mh_page/repair_history_page.dart +++ b/lib/pages/mh_page/repair_history_page.dart @@ -159,16 +159,12 @@ class RepairHistoryListPage extends GetView { .applyRepairModel! .device_name ?? '未命名', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: Colors.white, + ), ), ), Align( @@ -182,17 +178,13 @@ class RepairHistoryListPage extends GetView { .applyRepairModel! .device_category ?? '未命名'), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color( + 0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), Align( @@ -206,17 +198,13 @@ class RepairHistoryListPage extends GetView { .applyRepairModel! .device_type ?? '未命名'), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color( + 0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), Align( @@ -230,17 +218,13 @@ class RepairHistoryListPage extends GetView { .applyRepairModel! .device_id ?? '未命名'), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color( + 0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), Align( @@ -255,17 +239,13 @@ class RepairHistoryListPage extends GetView { .id .toString() ?? '未命名'), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color( + 0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), Align( @@ -279,17 +259,13 @@ class RepairHistoryListPage extends GetView { .model .applyRepairModel! .create_time!)), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color( + 0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), Align( @@ -303,17 +279,13 @@ class RepairHistoryListPage extends GetView { .applyRepairModel! .desc ?? '未命名'), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: const Color( + 0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), Padding( @@ -377,14 +349,12 @@ class RepairHistoryListPage extends GetView { .centerStart, // 文字左对齐 child: Text( '报修状态', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -483,19 +453,15 @@ class RepairHistoryListPage extends GetView { // color: FlutterFlowTheme.of(context) // .secondaryBackground, color: Colors.white, - textStyle: - FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: - 'Readex Pro', - // color: Color(0xFF333333), - // color: stringToColor("#D3B684"), - color: stringToColor( - "#117EFD"), - fontSize: 11, - letterSpacing: 0, - ), + textStyle: TextStyle( + fontFamily: 'Readex Pro', + // color: Color(0xFF333333), + // color: stringToColor("#D3B684"), + color: + stringToColor("#117EFD"), + fontSize: 11, + letterSpacing: 0, + ), elevation: 0, borderSide: BorderSide( // color: Color(0xFFC8CBD2), @@ -558,18 +524,14 @@ class RepairHistoryListPage extends GetView { -1, 0), child: Text( '评价状态', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: const Color( - 0xFF333333), - fontSize: 15, - letterSpacing: - 0.0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: const Color( + 0xFF333333), + fontSize: 15, + letterSpacing: 0.0, + ), ), ), ), @@ -617,17 +579,16 @@ class RepairHistoryListPage extends GetView { .model .applyRepairModel! .score_time!), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0.0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0.0, + ), ), ), ), @@ -652,17 +613,15 @@ class RepairHistoryListPage extends GetView { 0), child: Text( '已评价', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0.0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize.normal_text_size, + letterSpacing: + 0.0, + ), ), ), ), diff --git a/lib/pages/mh_page/repair_history_widget.dart b/lib/pages/mh_page/repair_history_widget.dart index 798fede..09194a3 100644 --- a/lib/pages/mh_page/repair_history_widget.dart +++ b/lib/pages/mh_page/repair_history_widget.dart @@ -64,7 +64,7 @@ class RepairHistoryWidget extends GetView { // repairListController // .model.repairList[index].device_category ?? // '', - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Readex Pro', // color: Color(0xFF333333), // fontSize: 30.rpx, @@ -76,7 +76,7 @@ class RepairHistoryWidget extends GetView { // alignment: AlignmentDirectional(-1, 0), // child: Text( // "报修单号:${repairListController.model.repairList[index].id}", - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Readex Pro', // color: Color(0xFFC8CBD2), // fontSize: AppFontsize.small_text_size, @@ -91,7 +91,7 @@ class RepairHistoryWidget extends GetView { // (MyUtils.formatDateTime(repairListController // .model.repairList[index].create_time!) ?? // ''), - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Readex Pro', // color: Color(0xFFC8CBD2), // fontSize: AppFontsize.small_text_size, @@ -117,7 +117,7 @@ class RepairHistoryWidget extends GetView { // child: Text( // repairListController.model.repairList[index].status ?? // '', - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Readex Pro', // color: Color(0xFF333333), // fontSize: AppFontsize.normal_text_size, diff --git a/lib/pages/mh_page/repair_list.dart b/lib/pages/mh_page/repair_list.dart index e86730e..46d182e 100644 --- a/lib/pages/mh_page/repair_list.dart +++ b/lib/pages/mh_page/repair_list.dart @@ -247,14 +247,12 @@ class DeviceRepairPage extends GetView { ), child: Text( "我要报修", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: stringToColor("#011D33"), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#011D33"), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ), )), diff --git a/lib/pages/mh_page/repair_process_widget.dart b/lib/pages/mh_page/repair_process_widget.dart index 4404933..c4ab871 100644 --- a/lib/pages/mh_page/repair_process_widget.dart +++ b/lib/pages/mh_page/repair_process_widget.dart @@ -42,17 +42,17 @@ class RepairStatusWidget extends GetView { MyUtils.formatDateTime(repairInfoController .model.repairProcessList[index].create_time!) ?? '未知时间', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - color: index == - repairInfoController - .model.repairProcessList.length - - 1 - ? Colors.white - : Colors.white, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + color: index == + repairInfoController + .model.repairProcessList.length - + 1 + ? Colors.white + : Colors.white, + ), ), ), ), @@ -65,33 +65,27 @@ class RepairStatusWidget extends GetView { repairInfoController .model.repairProcessList[index].status ?? '未知状态', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - color: repairInfoController - .model.repairProcessList[index].status == - RepairStatus.pending - ? AppColors().check_Color - : repairInfoController - .model - .repairProcessList[index] - .status == - RepairStatus.approved || - repairInfoController - .model - .repairProcessList[index] - .status == - '维修中' - ? AppColors().repair_Color - : repairInfoController - .model - .repairProcessList[index] - .status == - RepairStatus.completed - ? AppColors().finish_Color - : AppColors().unOp_Color, // 根据状态设置文字颜色 - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + color: repairInfoController + .model.repairProcessList[index].status == + RepairStatus.pending + ? AppColors().check_Color + : repairInfoController.model.repairProcessList[index] + .status == + RepairStatus.approved || + repairInfoController.model + .repairProcessList[index].status == + '维修中' + ? AppColors().repair_Color + : repairInfoController.model + .repairProcessList[index].status == + RepairStatus.completed + ? AppColors().finish_Color + : AppColors().unOp_Color, // 根据状态设置文字颜色 + ), ), ), ), @@ -105,12 +99,12 @@ class RepairStatusWidget extends GetView { ? '未备注' : repairInfoController .model.repairProcessList[index].desc!, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 20.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 20.rpx, + letterSpacing: 0, + ), ), ), ], diff --git a/lib/pages/mh_page/room_picker.dart b/lib/pages/mh_page/room_picker.dart index 19a8da3..936e17f 100644 --- a/lib/pages/mh_page/room_picker.dart +++ b/lib/pages/mh_page/room_picker.dart @@ -1,4 +1,3 @@ -import 'package:ef/base/widget/flutterflow/FlutterFlowTheme.dart'; import 'package:ef/ef.dart'; import 'package:flutter/material.dart'; import 'package:vbvs_app/common/color/ServiceConstant.dart'; diff --git a/lib/pages/mh_page/score_page.dart b/lib/pages/mh_page/score_page.dart index b62bdf8..8a4faa1 100644 --- a/lib/pages/mh_page/score_page.dart +++ b/lib/pages/mh_page/score_page.dart @@ -108,15 +108,11 @@ class ScorePage extends GetView { AlignmentDirectional(0, 0), child: Text( '我要评价', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: Colors.white), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: Colors.white), ), ), Row( @@ -295,18 +291,13 @@ class ScorePage extends GetView { } return Text( scoreText, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 30.rpx, - letterSpacing: 0, - color: scoreColor, - fontWeight: - FontWeight - .bold), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 30.rpx, + letterSpacing: 0, + color: scoreColor, + fontWeight: + FontWeight.bold), ); }), ), @@ -318,16 +309,11 @@ class ScorePage extends GetView { .fromSTEB(0, 17, 0, 0), child: Text( '再多的溢美之词,都比不上您真心的评价。我们愿付出200%的努力,只为您100%的满意~感谢您的支持与厚爱!', - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - color: - Color(0xFF9AA0B3)), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + color: Color(0xFF9AA0B3)), ), ), ), @@ -443,14 +429,12 @@ class ScorePage extends GetView { ), child: Text( "提交", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: stringToColor("#011D33"), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#011D33"), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ), )), diff --git a/lib/pages/mh_page/searchWidget.dart b/lib/pages/mh_page/searchWidget.dart index aebd218..ddaeae9 100644 --- a/lib/pages/mh_page/searchWidget.dart +++ b/lib/pages/mh_page/searchWidget.dart @@ -55,8 +55,7 @@ class SearchWidget extends GetView { width: 100.rpx, height: 60.rpx, decoration: BoxDecoration( - color: - FlutterFlowTheme.of(context).secondaryBackground, + color: Colors.white, ), child: Align( alignment: AlignmentDirectional(-1, 0), @@ -65,21 +64,17 @@ class SearchWidget extends GetView { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: hint, - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: Color(0XFFC8CBD2)), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: Color(0XFFC8CBD2)), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -96,14 +91,12 @@ class SearchWidget extends GetView { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), @@ -113,16 +106,14 @@ class SearchWidget extends GetView { contentPadding: EdgeInsets.symmetric( vertical: 12.rpx, horizontal: 12.rpx), // 关键设置 ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - color: Colors.black, - letterSpacing: 0.0, - ), - cursorColor: - FlutterFlowTheme.of(context).primaryText, + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + color: Colors.black, + letterSpacing: 0.0, + ), + // cursorColor: + // FlutterFlowTheme.of(context).primaryText, // validator: _model // .textControllerValidator // .asValidator(context), @@ -147,12 +138,12 @@ class SearchWidget extends GetView { ), Text( '搜索'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 30.rpx, - letterSpacing: 0.0, - color: stringToColor("#333333"), //固定 - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 30.rpx, + letterSpacing: 0.0, + color: stringToColor("#333333"), //固定 + ), ), ].divide(SizedBox(width: 26.rpx)), ), diff --git a/lib/pages/mh_page/smys.dart b/lib/pages/mh_page/smys.dart index 2819f75..b07413a 100644 --- a/lib/pages/mh_page/smys.dart +++ b/lib/pages/mh_page/smys.dart @@ -126,14 +126,12 @@ class Smys extends GetView { children: [ Text( '睡眠隐私功能', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), Container( @@ -181,14 +179,12 @@ class Smys extends GetView { children: [ Text( '开始时间', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () async { @@ -210,14 +206,12 @@ class Smys extends GetView { children: [ Text( "${controller.model.smysStartTimeToString}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), SizedBox( width: 16.rpx, @@ -259,14 +253,12 @@ class Smys extends GetView { children: [ Text( '结束时间', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 26.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () async { @@ -288,14 +280,12 @@ class Smys extends GetView { children: [ Text( "${controller.model.smysEndTimeToString}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), SizedBox( width: 16.rpx, @@ -325,14 +315,12 @@ class Smys extends GetView { decoration: BoxDecoration(), child: Text( '*注:开启睡眠隐私功能后,在设置的时间段内,将不会采集您的睡眠数据。', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: 20.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: 20.rpx, + letterSpacing: 0, + ), ), ), ) diff --git a/lib/pages/mh_page/user/page/edit_userinfo_page.dart b/lib/pages/mh_page/user/page/edit_userinfo_page.dart index c416515..6b9208e 100644 --- a/lib/pages/mh_page/user/page/edit_userinfo_page.dart +++ b/lib/pages/mh_page/user/page/edit_userinfo_page.dart @@ -74,12 +74,12 @@ class _UpdateUserPageState extends State { children: [ Text( '编辑资料'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -186,14 +186,12 @@ class _UpdateUserPageState extends State { child: Center( child: Text( '点击更换头像'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: stringToColor("#85F5FF"), - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: stringToColor("#85F5FF"), + ), ), ), ), @@ -242,25 +240,19 @@ class _UpdateUserPageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '未命名'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -281,9 +273,6 @@ class _UpdateUserPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of( - context) - .error, width: 1.rpx, ), borderRadius: @@ -293,9 +282,6 @@ class _UpdateUserPageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of( - context) - .error, width: 1.rpx, ), borderRadius: @@ -304,15 +290,13 @@ class _UpdateUserPageState extends State { ), filled: false, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), textAlign: TextAlign.center, cursorColor: themeController .currentColor.sc3, diff --git a/lib/pages/mh_page/user/page/find_password_page.dart b/lib/pages/mh_page/user/page/find_password_page.dart index fbf8844..3642c71 100644 --- a/lib/pages/mh_page/user/page/find_password_page.dart +++ b/lib/pages/mh_page/user/page/find_password_page.dart @@ -128,25 +128,18 @@ class FindPasswordPage extends GetView { // autofocus: true, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '请输入手机号'.tr, - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: InputBorder.none, errorBorder: InputBorder.none, @@ -157,15 +150,11 @@ class FindPasswordPage extends GetView { .fromSTEB(20.rpx, 0, 0, 0.rpx), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), ), @@ -204,33 +193,21 @@ class FindPasswordPage extends GetView { }, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - 20.rpx, - letterSpacing: - 0, - ), + labelStyle: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: 20.rpx, + letterSpacing: 0, + ), hintText: '请输验证码'.tr, - hintStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: Color( - 0xFF929699), - fontSize: - 26.rpx, - letterSpacing: - 0, - ), + hintStyle: TextStyle( + fontFamily: + 'Readex Pro', + color: + Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -244,15 +221,11 @@ class FindPasswordPage extends GetView { .fromSTEB(20.rpx, 0, 0, 0.rpx), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), ), @@ -383,28 +356,18 @@ class FindPasswordPage extends GetView { obscureText: controller.model.pdshow!, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '请输入新密码'.tr, - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: - Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -434,15 +397,11 @@ class FindPasswordPage extends GetView { }, ), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ); }), ), @@ -479,28 +438,18 @@ class FindPasswordPage extends GetView { obscureText: controller.model.cpdshow!, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '确认新密码', - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: - Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -530,15 +479,11 @@ class FindPasswordPage extends GetView { }, ), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ); }), ), @@ -590,7 +535,7 @@ class FindPasswordPage extends GetView { } String msg = await controller .confirmCode(context); - if (msg.isEmpty) { + if (msg.isEmpty) { Get.toNamed("/loginPage"); } }, @@ -612,15 +557,12 @@ class FindPasswordPage extends GetView { ), child: Text( "提交", - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0XFF003058), - letterSpacing: 0, - fontSize: 26.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0XFF003058), + letterSpacing: 0, + fontSize: 26.rpx, + ), ), ), )), diff --git a/lib/pages/mh_page/user/page/mht_login_page.dart b/lib/pages/mh_page/user/page/mht_login_page.dart index 0ad3bdb..a7ff4d6 100644 --- a/lib/pages/mh_page/user/page/mht_login_page.dart +++ b/lib/pages/mh_page/user/page/mht_login_page.dart @@ -287,19 +287,18 @@ class MHTLoginPage extends GetView { 0, 1), child: Text( '密码登录'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: - stringToColor("#84F5FF"), - fontSize: - AppFontsize.title_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: stringToColor( + "#84F5FF"), + fontSize: + AppFontsize + .title_size, + letterSpacing: + 0, + ), ), ), ), @@ -385,20 +384,18 @@ class MHTLoginPage extends GetView { 0, 1), child: Text( '短信登录'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors - .white, - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: Colors + .white, + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), ), ), @@ -487,19 +484,18 @@ class MHTLoginPage extends GetView { 0, 1), child: Text( '密码登录'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors - .white, - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: Colors + .white, + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), ), ), @@ -582,19 +578,18 @@ class MHTLoginPage extends GetView { 0, 1), child: Text( '短信登录'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: - stringToColor("#84F5FF"), - fontSize: - AppFontsize.title_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: stringToColor( + "#84F5FF"), + fontSize: + AppFontsize + .title_size, + letterSpacing: + 0, + ), ), ), ), @@ -673,29 +668,19 @@ class MHTLoginPage extends GetView { controller.model.account, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), hintText: '请输入账号', - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: - Color(0xFFD2D2D2), - fontSize: 13.px, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFFD2D2D2), + fontSize: 13.px, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -708,16 +693,12 @@ class MHTLoginPage extends GetView { .fromSTEB( 10, 0, 0, 5), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -768,35 +749,23 @@ class MHTLoginPage extends GetView { .model.password, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + labelStyle: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), hintText: '请输入密码', - hintStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: Color( - 0xFFD2D2D2), - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + hintStyle: TextStyle( + fontFamily: + 'Readex Pro', + color: + Color(0xFFD2D2D2), + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -834,16 +803,13 @@ class MHTLoginPage extends GetView { }, ), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -1007,30 +973,20 @@ class MHTLoginPage extends GetView { }, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), hintText: '请输入手机号'.tr, - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: - Color(0xFFD2D2D2), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFFD2D2D2), + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -1043,16 +999,12 @@ class MHTLoginPage extends GetView { .fromSTEB( 10, 0, 0, 5), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -1101,35 +1053,23 @@ class MHTLoginPage extends GetView { obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + labelStyle: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), hintText: '请输入验证码', - hintStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: Color( - 0xFFD2D2D2), - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + hintStyle: TextStyle( + fontFamily: + 'Readex Pro', + color: + Color(0xFFD2D2D2), + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -1143,16 +1083,13 @@ class MHTLoginPage extends GetView { .fromSTEB(10, 0, 0, 5), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -1421,9 +1358,8 @@ class MHTLoginPage extends GetView { }, side: BorderSide( width: 1.5, - color: FlutterFlowTheme - .of(context) - .secondaryText, + color: + Colors.white, ), activeColor: stringToColor( @@ -1469,18 +1405,14 @@ class MHTLoginPage extends GetView { 0, 0), child: Text( '我已阅读并同意'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors - .white, - fontSize: 12, - letterSpacing: - 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + Colors.white, + fontSize: 12, + letterSpacing: 0, + ), ), ), Align( @@ -1498,19 +1430,16 @@ class MHTLoginPage extends GetView { }, child: Text( '《用户协议》'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + stringToColor( "FF9F66"), - fontSize: - 12, - letterSpacing: - 0, - ), + fontSize: 12, + letterSpacing: + 0, + ), ), ), ), @@ -1520,18 +1449,14 @@ class MHTLoginPage extends GetView { 0, 0), child: Text( '与'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors - .white, - fontSize: 12, - letterSpacing: - 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + Colors.white, + fontSize: 12, + letterSpacing: 0, + ), ), ), Align( @@ -1549,19 +1474,16 @@ class MHTLoginPage extends GetView { }, child: Text( '《隐私协议》'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + stringToColor( "FF9F66"), - fontSize: - 12, - letterSpacing: - 0, - ), + fontSize: 12, + letterSpacing: + 0, + ), ), ), ), @@ -1657,19 +1579,17 @@ class MHTLoginPage extends GetView { child: Text( '注:首次登录会自动创建账号' .tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( - "#FFFFFF"), - fontSize: - 23.rpx, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: stringToColor( + "#FFFFFF"), + fontSize: + 23.rpx, + letterSpacing: + 0, + ), ), ), ], @@ -1843,8 +1763,7 @@ class MHTLoginPage extends GetView { BorderSide( width: 1.5, - color: FlutterFlowTheme.of(context) - .secondaryText, + color: Colors.white, ), activeColor: stringToColor( @@ -1919,19 +1838,18 @@ class MHTLoginPage extends GetView { }, child: Text( '找回密码'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( - "#84F5FF"), - fontSize: - AppFontsize.small_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: stringToColor( + "#84F5FF"), + fontSize: + AppFontsize + .small_text_size, + letterSpacing: + 0, + ), ), ), ), @@ -1985,19 +1903,17 @@ class MHTLoginPage extends GetView { }, child: Text( '注册'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: - stringToColor("#84F5FF"), - fontSize: - AppFontsize.small_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + color: stringToColor( + "#84F5FF"), + fontSize: + AppFontsize.small_text_size, + letterSpacing: + 0, + ), ), )), ), @@ -2073,7 +1989,8 @@ class MHTLoginPage extends GetView { // } // await loginController // .wxLoginSendAuth(context); - TopSlideNotification.show(context,text: "测试阶段,暂不支持".tr); + TopSlideNotification.show(context, + text: "测试阶段,暂不支持".tr); }, child: Container( width: 90.rpx, @@ -2135,28 +2052,24 @@ class MHTLoginPage extends GetView { alignment: AlignmentDirectional(0, 0), child: Text( '合肥眠花糖家具有限责任公司版权所有', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: AppFontsize.explain_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: AppFontsize.explain_size, + letterSpacing: 0, + ), ), ), Align( alignment: AlignmentDirectional(0, 0), child: Text( 'Copyright© 2019-2029', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF9EA4B7), - fontSize: AppFontsize.explain_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF9EA4B7), + fontSize: AppFontsize.explain_size, + letterSpacing: 0, + ), ), ), // Align( diff --git a/lib/pages/mh_page/user/page/register_page.dart b/lib/pages/mh_page/user/page/register_page.dart index cacb32a..e747876 100644 --- a/lib/pages/mh_page/user/page/register_page.dart +++ b/lib/pages/mh_page/user/page/register_page.dart @@ -118,24 +118,18 @@ class RegisterPage extends GetView { }, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '请输入手机号'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: InputBorder.none, errorBorder: InputBorder.none, @@ -145,13 +139,11 @@ class RegisterPage extends GetView { EdgeInsetsDirectional.fromSTEB( 20.rpx, 0, 0, 10.rpx), ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), ), @@ -185,25 +177,18 @@ class RegisterPage extends GetView { obscureText: controller.model.pdshow!, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '请输入密码'.tr, - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: InputBorder.none, errorBorder: InputBorder.none, @@ -231,15 +216,11 @@ class RegisterPage extends GetView { }, ), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ); })), ), @@ -274,25 +255,18 @@ class RegisterPage extends GetView { obscureText: controller.model.cpdshow!, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '请输入确认密码'.tr, - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: InputBorder.none, errorBorder: InputBorder.none, @@ -320,15 +294,11 @@ class RegisterPage extends GetView { }, ), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ); })), ), @@ -365,28 +335,18 @@ class RegisterPage extends GetView { // focusNode: _focusNode4, obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + labelStyle: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), hintText: '请输入验证码', - hintStyle: FlutterFlowTheme - .of(context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: - Color(0xFF929699), - fontSize: 26.rpx, - letterSpacing: 0, - ), + hintStyle: TextStyle( + fontFamily: 'Readex Pro', + color: Color(0xFF929699), + fontSize: 26.rpx, + letterSpacing: 0, + ), enabledBorder: InputBorder.none, focusedBorder: @@ -399,15 +359,11 @@ class RegisterPage extends GetView { .fromSTEB(20.rpx, 0, 0, 0.rpx), ), - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + fontSize: 26.rpx, + letterSpacing: 0, + ), ), ), ), @@ -579,9 +535,7 @@ class RegisterPage extends GetView { }, side: BorderSide( width: 1.5, - color: FlutterFlowTheme - .of(context) - .secondaryText, + color: Colors.white, ), activeColor: const Color( @@ -632,18 +586,13 @@ class RegisterPage extends GetView { 0, 0), child: Text( '我已阅读并同意'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors - .white, - fontSize: 12, - letterSpacing: - 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: 12, + letterSpacing: 0, + ), ), ), Align( @@ -659,18 +608,15 @@ class RegisterPage extends GetView { }, child: Text( '《用户协议》'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + stringToColor( "FF9F66"), - fontSize: 12, - letterSpacing: - 0, - ), + fontSize: 12, + letterSpacing: 0, + ), ), ), ), @@ -680,18 +626,13 @@ class RegisterPage extends GetView { 0, 0), child: Text( '与'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors - .white, - fontSize: 12, - letterSpacing: - 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: 12, + letterSpacing: 0, + ), ), ), Align( @@ -707,18 +648,15 @@ class RegisterPage extends GetView { }, child: Text( '《隐私协议》'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: stringToColor( + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + stringToColor( "FF9F66"), - fontSize: 12, - letterSpacing: - 0, - ), + fontSize: 12, + letterSpacing: 0, + ), ), ), ), @@ -776,15 +714,12 @@ class RegisterPage extends GetView { ), child: Text( "提交".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: - stringToColor("#011D33"), - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#011D33"), + letterSpacing: 0, + fontSize: 30.rpx, + ), ), ), )), diff --git a/lib/pages/mh_page/user/page/rxhx_mht.dart b/lib/pages/mh_page/user/page/rxhx_mht.dart index 78ab7be..a9d6b38 100644 --- a/lib/pages/mh_page/user/page/rxhx_mht.dart +++ b/lib/pages/mh_page/user/page/rxhx_mht.dart @@ -232,7 +232,7 @@ class _RxhxMhtState extends State { // children: [ // Text( // '柔性唤醒', - // style: FlutterFlowTheme.of(context).bodyMedium.override( + // style: TextStyle( // fontFamily: 'Readex Pro', // color: Colors.white, // letterSpacing: 0, @@ -289,14 +289,12 @@ class _RxhxMhtState extends State { children: [ Text( '柔性唤醒功能', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), Container( @@ -356,14 +354,12 @@ class _RxhxMhtState extends State { children: [ Text( '唤醒时间', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () async { @@ -384,14 +380,12 @@ class _RxhxMhtState extends State { children: [ Text( "${controller.model.rxhxWakeTimeToString}", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), SizedBox( width: 16.rpx, @@ -421,14 +415,12 @@ class _RxhxMhtState extends State { children: [ Text( '按摩', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () { @@ -451,14 +443,12 @@ class _RxhxMhtState extends State { children: [ Text( controller.model.rxhxIsAnMo ? '开' : '关', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), SizedBox( width: 16.rpx, @@ -488,14 +478,12 @@ class _RxhxMhtState extends State { children: [ Text( '唤醒部位', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), InkWell( onTap: () { @@ -516,14 +504,12 @@ class _RxhxMhtState extends State { children: [ Text( location[controller.model.rxhxLocation], - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), SizedBox( width: 16.rpx, @@ -557,14 +543,12 @@ class _RxhxMhtState extends State { children: [ Text( '自定义', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Colors.white, - fontSize: 26.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 26.rpx, + letterSpacing: 0, + ), ), Padding( padding: EdgeInsetsDirectional.fromSTEB( @@ -633,14 +617,12 @@ class _RxhxMhtState extends State { decoration: const BoxDecoration(), child: Text( '*注:开启该功能后,在设置的时间点,设备将启动一段固定时长的柔性唤醒功能。', - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: Color(0xFF929699), - fontSize: 20.rpx, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: Colors.white, + fontSize: 20.rpx, + letterSpacing: 0, + ), ), ), Spacer(), diff --git a/lib/pages/mh_page/user/page/update_password_page.dart b/lib/pages/mh_page/user/page/update_password_page.dart index 486f978..4d93eb7 100644 --- a/lib/pages/mh_page/user/page/update_password_page.dart +++ b/lib/pages/mh_page/user/page/update_password_page.dart @@ -60,12 +60,12 @@ class UpdatePasswordPage extends GetView { /// 居中标题 Text( '修改密码'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -137,18 +137,14 @@ class UpdatePasswordPage extends GetView { -1, 0), child: Text( '输入手机号码'.tr, - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: - Colors.white, - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -178,29 +174,18 @@ class UpdatePasswordPage extends GetView { obscureText: false, decoration: InputDecoration( - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), - hintStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - letterSpacing: - 0, - ), + labelStyle: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), + hintStyle: TextStyle( + fontFamily: + 'Readex Pro', + letterSpacing: 0, + ), enabledBorder: UnderlineInputBorder( borderSide: @@ -231,9 +216,7 @@ class UpdatePasswordPage extends GetView { UnderlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme - .of(context) - .error, + color: Colors.red, width: 2, ), borderRadius: @@ -245,9 +228,7 @@ class UpdatePasswordPage extends GetView { UnderlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme - .of(context) - .error, + color: Colors.red, width: 2, ), borderRadius: @@ -260,19 +241,15 @@ class UpdatePasswordPage extends GetView { .fromSTEB(8, 0, 0, 8), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: themeController - .currentColor - .sc4, - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: themeController + .currentColor.sc4, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -295,18 +272,14 @@ class UpdatePasswordPage extends GetView { -1, 0), child: Text( '输入验证码', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: - Colors.white, - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -363,33 +336,31 @@ class UpdatePasswordPage extends GetView { false, decoration: InputDecoration( - labelStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + labelStyle: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), hintText: '请输验证码', - hintStyle: FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: themeController - .currentColor - .sc4, - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + hintStyle: + TextStyle( + fontFamily: + 'Readex Pro', + color: themeController + .currentColor + .sc4, + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), enabledBorder: InputBorder .none, @@ -409,17 +380,16 @@ class UpdatePasswordPage extends GetView { 0, 12), ), - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize.normal_text_size, - letterSpacing: - 0, - ), + style: + TextStyle( + fontFamily: + 'Readex Pro', + fontSize: + AppFontsize + .normal_text_size, + letterSpacing: + 0, + ), ), ), ), @@ -537,17 +507,14 @@ class UpdatePasswordPage extends GetView { -1, 0), child: Text( '输入新密码', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -575,35 +542,24 @@ class UpdatePasswordPage extends GetView { decoration: InputDecoration( hintText: "请输入新密码".tr, - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), - hintStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: themeController - .currentColor - .sc4, - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + labelStyle: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), + hintStyle: TextStyle( + fontFamily: + 'Readex Pro', + color: + themeController + .currentColor + .sc4, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), enabledBorder: UnderlineInputBorder( borderSide: @@ -634,9 +590,7 @@ class UpdatePasswordPage extends GetView { UnderlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme - .of(context) - .error, + color: Colors.red, width: 2, ), borderRadius: @@ -648,9 +602,7 @@ class UpdatePasswordPage extends GetView { UnderlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme - .of(context) - .error, + color: Colors.red, width: 2, ), borderRadius: @@ -689,18 +641,15 @@ class UpdatePasswordPage extends GetView { }, ), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Color( - 0xFF333333), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + Color(0xFF333333), + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ); }), ), @@ -721,17 +670,14 @@ class UpdatePasswordPage extends GetView { -1, 0), child: Text( '确认新密码', - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Colors.white, - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: Colors.white, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ), ), ), @@ -760,35 +706,24 @@ class UpdatePasswordPage extends GetView { InputDecoration( hintText: "请输入确认密码".tr, - labelStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), - hintStyle: - FlutterFlowTheme.of( - context) - .labelMedium - .override( - fontFamily: - 'Readex Pro', - color: themeController - .currentColor - .sc4, - fontSize: - AppFontsize - .normal_text_size, - letterSpacing: - 0, - ), + labelStyle: TextStyle( + fontFamily: + 'Readex Pro', + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), + hintStyle: TextStyle( + fontFamily: + 'Readex Pro', + color: + themeController + .currentColor + .sc4, + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), enabledBorder: UnderlineInputBorder( borderSide: @@ -819,9 +754,7 @@ class UpdatePasswordPage extends GetView { UnderlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme - .of(context) - .error, + color: Colors.red, width: 2, ), borderRadius: @@ -833,9 +766,7 @@ class UpdatePasswordPage extends GetView { UnderlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme - .of(context) - .error, + color: Colors.red, width: 2, ), borderRadius: @@ -875,18 +806,15 @@ class UpdatePasswordPage extends GetView { }, ), ), - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: - 'Readex Pro', - color: Color( - 0xFF333333), - fontSize: AppFontsize - .normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: + 'Readex Pro', + color: + Color(0xFF333333), + fontSize: AppFontsize + .normal_text_size, + letterSpacing: 0, + ), ); }), ), @@ -950,14 +878,12 @@ class UpdatePasswordPage extends GetView { child: Center( child: Text( '确定'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Readex Pro', - color: stringToColor("#003058"), - fontSize: AppFontsize.normal_text_size, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: stringToColor("#003058"), + fontSize: AppFontsize.normal_text_size, + letterSpacing: 0, + ), ), ), ), diff --git a/lib/pages/person/person_page.dart b/lib/pages/person/person_page.dart index d04063c..73e7a7f 100644 --- a/lib/pages/person/person_page.dart +++ b/lib/pages/person/person_page.dart @@ -89,12 +89,12 @@ class _EPageState extends State { /// 居中标题 Text( '人员资料.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -133,13 +133,11 @@ class _EPageState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '人员资料.保存'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -191,24 +189,18 @@ class _EPageState extends State { decoration: InputDecoration( fillColor: Colors.transparent, isDense: true, - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), hintText: '人员资料.名字输入提示'.tr, - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -227,8 +219,6 @@ class _EPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -236,8 +226,6 @@ class _EPageState extends State { ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -245,14 +233,11 @@ class _EPageState extends State { ), filled: true, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: - themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -307,21 +292,16 @@ class _EPageState extends State { ), Text( '男'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: isMaleGreyed - ? themeController - .currentColor - .sc4 - : themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: isMaleGreyed + ? themeController + .currentColor.sc4 + : themeController + .currentColor.sc3, + ), ), ].divide( SizedBox(height: 14.rpx)), @@ -361,21 +341,16 @@ class _EPageState extends State { ), Text( '女'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: isFemaleGreyed - ? themeController - .currentColor - .sc4 - : themeController - .currentColor - .sc3, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: isFemaleGreyed + ? themeController + .currentColor.sc4 + : themeController + .currentColor.sc3, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide( SizedBox(height: 14.rpx)), @@ -427,20 +402,15 @@ class _EPageState extends State { personController.dateTime!) : '人员资料.生日输入提示'.tr, textAlign: TextAlign.right, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: personController.dateTime != - null - ? themeController - .currentColor.sc3 - : themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: personController.dateTime != null + ? themeController.currentColor.sc3 + : themeController.currentColor.sc4, + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0, + ), ), ), ), @@ -480,14 +450,11 @@ class _EPageState extends State { }, autofocus: false, obscureText: false, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Colors.transparent, // 隐藏输入文字 - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.transparent, // 隐藏输入文字 + letterSpacing: 0.0, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -495,17 +462,14 @@ class _EPageState extends State { fillColor: Colors.transparent, isDense: true, hintText: '身高输入提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -524,9 +488,6 @@ class _EPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -535,9 +496,6 @@ class _EPageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -555,16 +513,13 @@ class _EPageState extends State { : Text( '${height}cm', textAlign: TextAlign.center, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + ), ); }), ], @@ -605,14 +560,11 @@ class _EPageState extends State { }, autofocus: false, obscureText: false, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Colors.transparent, // 隐藏输入文字 - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.transparent, // 隐藏输入文字 + letterSpacing: 0.0, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -620,17 +572,14 @@ class _EPageState extends State { fillColor: Colors.transparent, isDense: true, hintText: '人员资料.体重输入提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -649,9 +598,6 @@ class _EPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -660,9 +606,6 @@ class _EPageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -680,16 +623,13 @@ class _EPageState extends State { : Text( '${weight}kg', textAlign: TextAlign.center, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + ), ); }), ], @@ -707,14 +647,12 @@ class _EPageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '人员资料.疾病标题'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Color(0xFFF3F4F5), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF3F4F5), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -791,14 +729,12 @@ class _EPageState extends State { Expanded( child: Text( '人员资料.提示'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController.currentColor.sc4, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc4, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ].divide(SizedBox(width: 23.rpx)), @@ -841,12 +777,12 @@ class _EPageState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFC2CED7), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFC2CED7), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/person/select_time.dart b/lib/pages/person/select_time.dart index b1bce2c..4eccd68 100644 --- a/lib/pages/person/select_time.dart +++ b/lib/pages/person/select_time.dart @@ -78,15 +78,12 @@ Future showDateSelectionDialog(BuildContext context, InkWell( child: Text( "日期.取消".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: - themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: AppConstants() - .normal_text_fontSize), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: + AppConstants().normal_text_fontSize), ), onTap: () { Get.back(); @@ -94,28 +91,23 @@ Future showDateSelectionDialog(BuildContext context, ), Text( "$title", - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: - AppConstants().title_text_fontSize), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: + AppConstants().title_text_fontSize), ), // closeIconWhite, InkWell( child: Text( "日期.确定".tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: - themeController.currentColor.sc2, - letterSpacing: 0, - fontSize: AppConstants() - .normal_text_fontSize), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc2, + letterSpacing: 0, + fontSize: + AppConstants().normal_text_fontSize), ), onTap: () { checkChange?.call(DateTime(years[yearIndex], @@ -217,12 +209,12 @@ Future showDateSelectionDialog(BuildContext context, } TextStyle _unitStyle(BuildContext context) { - return FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - letterSpacing: 0, - ); + return TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + letterSpacing: 0, + ); } getOnePicker(BuildContext context, List arr, int checkIndex, @@ -248,11 +240,11 @@ getOnePicker(BuildContext context, List arr, int checkIndex, alignment: Alignment.center, child: Text( "${arr[index]}$unit", // ✅ 每项都带单位 - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + fontSize: 30.rpx, + ), ), ); }), diff --git a/lib/pages/person/update_person_page.dart b/lib/pages/person/update_person_page.dart index df545fe..22cd234 100644 --- a/lib/pages/person/update_person_page.dart +++ b/lib/pages/person/update_person_page.dart @@ -84,12 +84,12 @@ class _UpdatePageState extends State { /// 居中标题 Text( '人员资料.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -132,13 +132,11 @@ class _UpdatePageState extends State { 16.rpx, 0, 16.rpx, 0), child: Text( '完成'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -191,24 +189,18 @@ class _UpdatePageState extends State { decoration: InputDecoration( fillColor: Colors.transparent, isDense: true, - labelStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), hintText: '人员资料.名字输入提示'.tr, - hintStyle: FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -227,8 +219,6 @@ class _UpdatePageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -236,8 +226,6 @@ class _UpdatePageState extends State { ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -245,14 +233,11 @@ class _UpdatePageState extends State { ), filled: true, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - letterSpacing: 0.0, - color: - themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -307,21 +292,16 @@ class _UpdatePageState extends State { ), Text( '男'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: isMaleGreyed - ? themeController - .currentColor - .sc4 - : themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: isMaleGreyed + ? themeController + .currentColor.sc4 + : themeController + .currentColor.sc3, + ), ), ].divide( SizedBox(height: 14.rpx)), @@ -361,21 +341,16 @@ class _UpdatePageState extends State { ), Text( '女'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: isFemaleGreyed - ? themeController - .currentColor - .sc4 - : themeController - .currentColor - .sc3, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: isFemaleGreyed + ? themeController + .currentColor.sc4 + : themeController + .currentColor.sc3, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ].divide( SizedBox(height: 14.rpx)), @@ -429,20 +404,15 @@ class _UpdatePageState extends State { personController.dateTime!) : '人员资料.生日输入提示'.tr, textAlign: TextAlign.right, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Readex Pro', - color: personController.dateTime != - null - ? themeController - .currentColor.sc3 - : themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: personController.dateTime != null + ? themeController.currentColor.sc3 + : themeController.currentColor.sc4, + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0, + ), ), ), ), @@ -481,14 +451,11 @@ class _UpdatePageState extends State { }, autofocus: false, obscureText: false, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Colors.transparent, // 隐藏输入文字 - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.transparent, // 隐藏输入文字 + letterSpacing: 0.0, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -496,17 +463,14 @@ class _UpdatePageState extends State { fillColor: Colors.transparent, isDense: true, hintText: '身高输入提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -525,9 +489,6 @@ class _UpdatePageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -536,9 +497,6 @@ class _UpdatePageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -556,16 +514,13 @@ class _UpdatePageState extends State { : Text( '${height}cm', textAlign: TextAlign.center, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + ), ); }), ], @@ -607,14 +562,11 @@ class _UpdatePageState extends State { }, autofocus: false, obscureText: false, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Colors.transparent, // 隐藏输入文字 - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Colors.transparent, // 隐藏输入文字 + letterSpacing: 0.0, + ), textAlign: TextAlign.center, cursorColor: themeController.currentColor.sc3, @@ -622,17 +574,14 @@ class _UpdatePageState extends State { fillColor: Colors.transparent, isDense: true, hintText: '人员资料.体重输入提示'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc4, - fontSize: AppConstants() - .normal_text_fontSize, - letterSpacing: 0.0, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc4, + fontSize: AppConstants() + .normal_text_fontSize, + letterSpacing: 0.0, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -651,9 +600,6 @@ class _UpdatePageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -662,9 +608,6 @@ class _UpdatePageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: - FlutterFlowTheme.of(context) - .error, width: 1.rpx, ), borderRadius: @@ -682,16 +625,13 @@ class _UpdatePageState extends State { : Text( '${weight}kg', textAlign: TextAlign.center, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .normal_text_fontSize, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .normal_text_fontSize, + ), ); }), ], @@ -709,14 +649,12 @@ class _UpdatePageState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '人员资料.疾病标题'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: Color(0xFFF3F4F5), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFF3F4F5), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ), ), @@ -795,14 +733,12 @@ class _UpdatePageState extends State { Expanded( child: Text( '人员资料.提示'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController.currentColor.sc4, - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController.currentColor.sc4, + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), ), ].divide(SizedBox(width: 23.rpx)), @@ -848,12 +784,12 @@ class _UpdatePageState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFC2CED7), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFC2CED7), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/repair/apply_repair_page.dart b/lib/pages/repair/apply_repair_page.dart index a0d3e7e..26d5318 100644 --- a/lib/pages/repair/apply_repair_page.dart +++ b/lib/pages/repair/apply_repair_page.dart @@ -373,15 +373,13 @@ class _ApplyRepairPageState extends State { children: [ Text( '提交'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -443,9 +441,9 @@ class _ApplyRepairPageState extends State { isDense: true, labelStyle: TextStyle( letterSpacing: 0.0, - fontWeight: - FlutterFlowTheme.of(context).labelMedium.fontWeight, - fontStyle: FlutterFlowTheme.of(context).labelMedium.fontStyle, + // fontWeight: + // FlutterFlowTheme.of(context).labelMedium.fontWeight, + // fontStyle: FlutterFlowTheme.of(context).labelMedium.fontStyle, ), hintText: hinttext, hintStyle: TextStyle( @@ -470,14 +468,14 @@ class _ApplyRepairPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, + // width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, + // width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/repair/apply_repair_success.dart b/lib/pages/repair/apply_repair_success.dart index cedd38f..5a2a6b9 100644 --- a/lib/pages/repair/apply_repair_success.dart +++ b/lib/pages/repair/apply_repair_success.dart @@ -60,12 +60,12 @@ class _ApplyRepairSuccessState extends State { /// 居中标题 Text( '报修成功标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -135,14 +135,12 @@ class _ApplyRepairSuccessState extends State { alignment: AlignmentDirectional(0, 0), child: Text( '报修成功'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 48.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 48.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc3, + ), ), ), ), @@ -182,14 +180,12 @@ class _ApplyRepairSuccessState extends State { alignment: AlignmentDirectional(-1, 0), child: Text( '报修成功标语'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc4, + ), ), ), ), @@ -231,15 +227,13 @@ class _ApplyRepairSuccessState extends State { ), Text( '查看报修历史'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -273,15 +267,13 @@ class _ApplyRepairSuccessState extends State { children: [ Text( '绑定成功.返回'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: AppConstants() - .normal_text_fontSize, // 自定义字体大小 - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: AppConstants() + .normal_text_fontSize, // 自定义字体大小 + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 17.rpx)), ), @@ -324,12 +316,12 @@ class _ApplyRepairSuccessState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFC2CED7), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFC2CED7), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/repair/component/RepairHistoryInfoWidget.dart b/lib/pages/repair/component/RepairHistoryInfoWidget.dart index 2e43835..ff3f76c 100644 --- a/lib/pages/repair/component/RepairHistoryInfoWidget.dart +++ b/lib/pages/repair/component/RepairHistoryInfoWidget.dart @@ -77,12 +77,6 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, color: themeController.currentColor.sc4, ), ), @@ -94,12 +88,6 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, color: themeController.currentColor.sc3, ), ), @@ -125,12 +113,6 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, color: themeController.currentColor.sc4, ), ), @@ -143,12 +125,6 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, color: themeController.currentColor.sc3, ), ), @@ -175,12 +151,6 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, color: themeController.currentColor.sc4, ), ), @@ -192,12 +162,7 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, + color: themeController.currentColor.sc3, ), ), @@ -223,12 +188,6 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, color: themeController.currentColor.sc4, ), ), @@ -240,12 +199,7 @@ class _RepairHistoryInfoWidgetState extends State { style: TextStyle( fontSize: 26.rpx, letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .bodyMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .bodyMedium - .fontStyle, + color: themeController.currentColor.sc3, ), ), @@ -277,12 +231,12 @@ class _RepairHistoryInfoWidgetState extends State { child: Center( child: Text( "查看".tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: Colors.white, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: Colors.white, + ), ), ), ), diff --git a/lib/pages/repair/component/RepairModelReadOnlyWidget.dart b/lib/pages/repair/component/RepairModelReadOnlyWidget.dart index 37136bf..317b7ff 100644 --- a/lib/pages/repair/component/RepairModelReadOnlyWidget.dart +++ b/lib/pages/repair/component/RepairModelReadOnlyWidget.dart @@ -116,12 +116,6 @@ class _RepairModelReadOnlyWidgetState extends State { isDense: true, labelStyle: TextStyle( letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .labelMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .labelMedium - .fontStyle, ), hintText: "设备参数提示".tr, hintStyle: TextStyle( @@ -146,14 +140,12 @@ class _RepairModelReadOnlyWidgetState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), @@ -220,12 +212,7 @@ class _RepairModelReadOnlyWidgetState extends State { isDense: true, labelStyle: TextStyle( letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .labelMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .labelMedium - .fontStyle, + ), hintText: "设备参数提示".tr, hintStyle: TextStyle( @@ -250,14 +237,12 @@ class _RepairModelReadOnlyWidgetState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), @@ -308,10 +293,7 @@ class _RepairModelReadOnlyWidgetState extends State { isDense: true, labelStyle: TextStyle( letterSpacing: 0.0, - fontWeight: - FlutterFlowTheme.of(context).labelMedium.fontWeight, - fontStyle: - FlutterFlowTheme.of(context).labelMedium.fontStyle, + ), hintText: '问题描述'.tr, hintStyle: TextStyle( @@ -335,14 +317,12 @@ class _RepairModelReadOnlyWidgetState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, width: 1, ), borderRadius: BorderRadius.circular(8.rpx), @@ -464,14 +444,12 @@ class _RepairModelReadOnlyWidgetState extends State { children: [ Text( '删除'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc9, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc9, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, diff --git a/lib/pages/repair/component/RepairModelWidget.dart b/lib/pages/repair/component/RepairModelWidget.dart index 440ed1b..47f1b25 100644 --- a/lib/pages/repair/component/RepairModelWidget.dart +++ b/lib/pages/repair/component/RepairModelWidget.dart @@ -21,7 +21,7 @@ class RepairModelWidget extends StatefulWidget { int length; final GlobalKey widgetKey; // 新增 final bool showDelete; // ✅ 新增 - + RepairModelWidget({ super.key, required this.model, @@ -143,7 +143,7 @@ class _RepairModelWidgetState extends State { ), icon: Icon( Icons.keyboard_arrow_down_rounded, - color: FlutterFlowTheme.of(context).secondaryText, + color:Colors.white, size: 24.rpx, ), fillColor: themeController.currentColor.sc15, @@ -208,12 +208,6 @@ class _RepairModelWidgetState extends State { isDense: true, labelStyle: TextStyle( letterSpacing: 0.0, - fontWeight: FlutterFlowTheme.of(context) - .labelMedium - .fontWeight, - fontStyle: FlutterFlowTheme.of(context) - .labelMedium - .fontStyle, ), hintText: "设备参数提示".tr, hintStyle: TextStyle( @@ -238,14 +232,14 @@ class _RepairModelWidgetState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, + // width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, + // width: 1.rpx, ), borderRadius: BorderRadius.circular(8.rpx), @@ -295,10 +289,6 @@ class _RepairModelWidgetState extends State { isDense: true, labelStyle: TextStyle( letterSpacing: 0.0, - fontWeight: - FlutterFlowTheme.of(context).labelMedium.fontWeight, - fontStyle: - FlutterFlowTheme.of(context).labelMedium.fontStyle, ), hintText: '问题描述'.tr, hintStyle: TextStyle( @@ -322,14 +312,14 @@ class _RepairModelWidgetState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, + // width: 1, ), borderRadius: BorderRadius.circular(8.rpx), ), focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of(context).error, + // width: 1, ), borderRadius: BorderRadius.circular(8.rpx), @@ -451,14 +441,12 @@ class _RepairModelWidgetState extends State { children: [ Text( '删除'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc9, - fontFamily: 'Inter', - fontSize: AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc9, + fontFamily: 'Inter', + fontSize: AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, diff --git a/lib/pages/setting/language_setting.dart b/lib/pages/setting/language_setting.dart index 08f9ffd..c518cb9 100644 --- a/lib/pages/setting/language_setting.dart +++ b/lib/pages/setting/language_setting.dart @@ -56,12 +56,12 @@ class _LanguageSettingState extends State { /// 居中标题 Text( '选择语言'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -140,19 +140,14 @@ class _LanguageSettingState extends State { child: Text( language.language_name ?? '语言名称', // 显示语言名称 - style: FlutterFlowTheme - .of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - themeController - .currentColor - .sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), maxLines: 1, overflow: TextOverflow .ellipsis, // 省略号处理 @@ -249,12 +244,12 @@ class _LanguageSettingState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFC2CED7), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFC2CED7), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/sleep_report/mht_new_sleep_report_page.dart b/lib/pages/sleep_report/mht_new_sleep_report_page.dart index 0cde4a8..aa1ba79 100644 --- a/lib/pages/sleep_report/mht_new_sleep_report_page.dart +++ b/lib/pages/sleep_report/mht_new_sleep_report_page.dart @@ -91,6 +91,7 @@ class _MHTNewSleepReportPageState extends State { sleepReportController.updateAll(); print(res); }); + super.initState(); } @@ -100,7 +101,40 @@ class _MHTNewSleepReportPageState extends State { } @override - Widget build(BuildContext context) { + Widget build(BuildContext context) { + sleepReportController.sleepReport.value = {}; + if (widget.data['date'] == null) { + widget.data['date'] = DateTime.now(); + } + calendarController.selectedDate.value = + DateTime.fromMillisecondsSinceEpoch(widget.data['date']); + sleepReportController.selectedDate.value = + DateTime.fromMillisecondsSinceEpoch(widget.data['date']); + if (widget.data['type'] != null) { + sleepReportController.model.type = widget.data['type']; + } else { + sleepReportController.model.type = 1; + } + String date = MyUtils.formatToDate(widget.data['date']); + // String date = '2025-5-27'; + requestWithLog( + logTitle: "查询睡眠报告", + method: MyHttpMethod.get, + queryUrl: + "https://sleepdata.he-info.com/api/analysis/sleep/analysis?mac=${widget.data['mac']}&time=${date}&type=${sleepReportController.model.type}", + onSuccess: (res) { + print(res); + sleepReportController.sleepReport.value = res.data; + sleepReportController.updateAll(); + _scrollToTargetComponent(sleepReportController.sleepReport); + }, + onFailure: (res) { + TopSlideNotification.show(context, + text: res.msg!, textColor: themeController.currentColor.sc9); + sleepReportController.sleepReport.value = {}; + sleepReportController.updateAll(); + print(res); + }); double lineWidth = 115.rpx; return LayoutBuilder( builder: (context, bodySize) => GestureDetector( @@ -133,12 +167,12 @@ class _MHTNewSleepReportPageState extends State { /// 居中标题 Text( '健康报告'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -206,26 +240,19 @@ class _MHTNewSleepReportPageState extends State { Alignment.center, // 文字居中 child: Text( '日报'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - color: - sleepReportController - .model - .type == - 1 - ? themeController - .currentColor - .sc2 - : themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + color: sleepReportController + .model.type == + 1 + ? themeController + .currentColor.sc2 + : themeController + .currentColor.sc3, + ), ), ), SizedBox(height: 10.rpx), @@ -413,29 +440,23 @@ class _MHTNewSleepReportPageState extends State { children: [ Text( '姓名'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '年龄'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -453,29 +474,23 @@ class _MHTNewSleepReportPageState extends State { .data['person']!['name'] .toString() : '未知数据'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), Text( '${MyUtils.getAgeByDate(MyUtils.formatBirthdayTime(widget.data['person']?['birthday'])) ?? '未知数据'.tr}', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -501,29 +516,23 @@ class _MHTNewSleepReportPageState extends State { children: [ Text( '设备ID'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '体重'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -534,31 +543,25 @@ class _MHTNewSleepReportPageState extends State { Text( '${widget.data['code'] ?? '未知数据'.tr}', // "D11250300003", - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), Text( '${widget.data['person']?['weight'] ?? '未知数据'.tr}kg', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), diff --git a/lib/pages/sleep_report/new_sleep_report_page copy.dart b/lib/pages/sleep_report/new_sleep_report_page copy.dart index fa7ce80..94979b3 100644 --- a/lib/pages/sleep_report/new_sleep_report_page copy.dart +++ b/lib/pages/sleep_report/new_sleep_report_page copy.dart @@ -112,12 +112,12 @@ class _NewSleepReportPageState extends State { /// 居中标题 Text( '健康报告'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -180,26 +180,19 @@ class _NewSleepReportPageState extends State { Alignment.center, // 文字居中 child: Text( '日报'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - color: - sleepReportController - .model - .type == - 1 - ? themeController - .currentColor - .sc2 - : themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + color: sleepReportController + .model.type == + 1 + ? themeController + .currentColor.sc2 + : themeController + .currentColor.sc3, + ), ), ), SizedBox(height: 10.rpx), @@ -384,29 +377,23 @@ class _NewSleepReportPageState extends State { children: [ Text( '姓名'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '年龄'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -416,29 +403,23 @@ class _NewSleepReportPageState extends State { children: [ Text( '传感器1号', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), Text( '69', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -464,29 +445,23 @@ class _NewSleepReportPageState extends State { children: [ Text( '设备ID'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '体重'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -497,29 +472,23 @@ class _NewSleepReportPageState extends State { Text( '1231212', // "D11250300003", - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), Text( '55kg', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), diff --git a/lib/pages/sleep_report/new_sleep_report_page.dart b/lib/pages/sleep_report/new_sleep_report_page.dart index f83456c..f68b177 100644 --- a/lib/pages/sleep_report/new_sleep_report_page.dart +++ b/lib/pages/sleep_report/new_sleep_report_page.dart @@ -9,6 +9,7 @@ import 'package:vbvs_app/common/util/requestWithLog.dart'; import 'package:vbvs_app/component/tool/ClickableContainer.dart'; import 'package:vbvs_app/component/tool/TopSlideNotification.dart'; import 'package:vbvs_app/controller/date/CalendarController.dart'; +import 'package:vbvs_app/controller/home/home_controller.dart'; import 'package:vbvs_app/controller/sleep/sleep_report_controller.dart'; import 'package:vbvs_app/language/AppLanguage.dart'; import 'package:vbvs_app/pages/common/selectDialog.dart'; @@ -32,16 +33,16 @@ import 'package:vbvs_app/pages/sleep_report/component/ZiZhuShenJingPercentWidget class NewSleepReportPage extends StatefulWidget { var data; - NewSleepReportPage({super.key, required this.data}); + NewSleepReportPage({super.key, required this.data}) {} @override State createState() => _NewSleepReportPageState(); } class _NewSleepReportPageState extends State { - SleepReportController sleepReportController = Get.find(); + late SleepReportController sleepReportController; CalendarController calendarController = Get.find(); - + _NewSleepReportPageState() {} final GlobalKey sleepCardKey = GlobalKey(); final GlobalKey heartRateCardKey = GlobalKey(); final GlobalKey breatheCardKey = GlobalKey(); @@ -58,6 +59,11 @@ class _NewSleepReportPageState extends State { @override void initState() { + if (Get.isRegistered(tag: widget.data["tag"]) == + false) { + Get.put(tag: widget.data["tag"], SleepReportController()); + } + sleepReportController = Get.find(tag: widget.data["tag"]); sleepReportController.sleepReport.value = {}; if (widget.data['date'] == null) { widget.data['date'] = DateTime.now(); @@ -91,7 +97,6 @@ class _NewSleepReportPageState extends State { sleepReportController.updateAll(); print(res); }); - super.initState(); } @override @@ -101,6 +106,44 @@ class _NewSleepReportPageState extends State { @override Widget build(BuildContext context) { + if (Get.isRegistered(tag: widget.data["tag"]) == + false) { + Get.put(tag: widget.data["tag"], SleepReportController()); + } + sleepReportController = Get.find(tag: widget.data["tag"]); + sleepReportController.sleepReport.value = {}; + if (widget.data['date'] == null) { + widget.data['date'] = DateTime.now(); + } + calendarController.selectedDate.value = + DateTime.fromMillisecondsSinceEpoch(widget.data['date']); + sleepReportController.selectedDate.value = + DateTime.fromMillisecondsSinceEpoch(widget.data['date']); + if (widget.data['type'] != null) { + sleepReportController.model.type = widget.data['type']; + } else { + sleepReportController.model.type = 1; + } + String date = MyUtils.formatToDate(widget.data['date']); + // String date = '2025-5-27'; + requestWithLog( + logTitle: "查询睡眠报告", + method: MyHttpMethod.get, + queryUrl: + "https://sleepdata.he-info.com/api/analysis/sleep/analysis?mac=${widget.data['mac']}&time=${date}&type=${sleepReportController.model.type}", + onSuccess: (res) { + print(res); + sleepReportController.sleepReport.value = res.data; + sleepReportController.updateAll(); + _scrollToTargetComponent(sleepReportController.sleepReport); + }, + onFailure: (res) { + TopSlideNotification.show(context, + text: res.msg!, textColor: themeController.currentColor.sc9); + sleepReportController.sleepReport.value = {}; + sleepReportController.updateAll(); + print(res); + }); double lineWidth = 115.rpx; return LayoutBuilder( builder: (context, bodySize) => GestureDetector( @@ -133,12 +176,12 @@ class _NewSleepReportPageState extends State { /// 居中标题 Text( '健康报告'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -206,26 +249,19 @@ class _NewSleepReportPageState extends State { Alignment.center, // 文字居中 child: Text( '日报'.tr, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - color: - sleepReportController - .model - .type == - 1 - ? themeController - .currentColor - .sc2 - : themeController - .currentColor - .sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + color: sleepReportController + .model.type == + 1 + ? themeController + .currentColor.sc2 + : themeController + .currentColor.sc3, + ), ), ), SizedBox(height: 10.rpx), @@ -413,29 +449,23 @@ class _NewSleepReportPageState extends State { children: [ Text( '姓名'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '年龄'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -453,29 +483,23 @@ class _NewSleepReportPageState extends State { .data['person']!['name'] .toString() : '未知数据'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), Text( '${MyUtils.getAgeByDate(MyUtils.formatBirthdayTime(widget.data['person']?['birthday'])) ?? '未知数据'.tr}', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -501,29 +525,23 @@ class _NewSleepReportPageState extends State { children: [ Text( '设备ID'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), Text( '体重'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), ), ].divide(SizedBox(height: 34.rpx)), ), @@ -534,31 +552,25 @@ class _NewSleepReportPageState extends State { Text( '${widget.data['code'] ?? '未知数据'.tr}', // "D11250300003", - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), maxLines: 1, overflow: TextOverflow.ellipsis, ), Text( '${widget.data['person']?['weight'] ?? '未知数据'.tr}kg', - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc3, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc3, + ), ), ].divide(SizedBox(height: 34.rpx)), ), diff --git a/lib/pages/sleep_report/sleep_report_page.dart b/lib/pages/sleep_report/sleep_report_page.dart index 7e97ab2..9622efc 100644 --- a/lib/pages/sleep_report/sleep_report_page.dart +++ b/lib/pages/sleep_report/sleep_report_page.dart @@ -66,7 +66,7 @@ class _SleepReportPageState extends State { /// 居中标题 Text( '健康报告'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( + style: TextStyle( fontFamily: 'Readex Pro', color: themeController.currentColor.sc3, letterSpacing: 0, diff --git a/lib/pages/user/about_us_page copy.dart b/lib/pages/user/about_us_page copy.dart index fd1f00e..9e6d658 100644 --- a/lib/pages/user/about_us_page copy.dart +++ b/lib/pages/user/about_us_page copy.dart @@ -60,7 +60,7 @@ // /// 居中标题 // Text( // '关于我们.标题'.tr, -// style: FlutterFlowTheme.of(context).bodyMedium.override( +// style: TextStyle( // fontFamily: 'Readex Pro', // color: themeController.currentColor.sc3, // letterSpacing: 0, diff --git a/lib/pages/user/about_us_page.dart b/lib/pages/user/about_us_page.dart index fd506c5..b610ae9 100644 --- a/lib/pages/user/about_us_page.dart +++ b/lib/pages/user/about_us_page.dart @@ -55,12 +55,12 @@ class _AboutUsPageState extends State { /// 居中标题 Text( '关于我们'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 diff --git a/lib/pages/user/privacy_scheme_page.dart b/lib/pages/user/privacy_scheme_page.dart index 8762a2a..2313e2c 100644 --- a/lib/pages/user/privacy_scheme_page.dart +++ b/lib/pages/user/privacy_scheme_page.dart @@ -61,12 +61,12 @@ class _PrivacySchemePageState extends State { /// 居中标题 Text( '隐私协议'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 diff --git a/lib/pages/user/setting_page.dart b/lib/pages/user/setting_page.dart index 720ae7e..71887f9 100644 --- a/lib/pages/user/setting_page.dart +++ b/lib/pages/user/setting_page.dart @@ -67,12 +67,12 @@ class _SettingPageState extends State { /// 居中标题 Text( '设置页.标题'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 @@ -135,17 +135,14 @@ class _SettingPageState extends State { children: [ Text( '设置页.主题模式'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -154,16 +151,12 @@ class _SettingPageState extends State { children: [ Text( '深色'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Color(0xFFD9E3EB), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFD9E3EB), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ), SvgPicture.asset( 'assets/img/icon/arrow_right.svg', @@ -205,17 +198,14 @@ class _SettingPageState extends State { children: [ Text( '设置页.选择语言'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -228,16 +218,12 @@ class _SettingPageState extends State { .selectLanguage .value! .language_name!, - style: FlutterFlowTheme.of( - context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: - Color(0xFFD9E3EB), - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: Color(0xFFD9E3EB), + fontSize: 26.rpx, + letterSpacing: 0.0, + ), ); }), SvgPicture.asset( @@ -279,17 +265,14 @@ class _SettingPageState extends State { children: [ Text( '消息通知'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -330,17 +313,14 @@ class _SettingPageState extends State { children: [ Text( '关于我们'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -382,17 +362,14 @@ class _SettingPageState extends State { children: [ Text( '用户协议'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -434,17 +411,14 @@ class _SettingPageState extends State { children: [ Text( '隐私协议'.tr, - style: - FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - color: themeController - .currentColor.sc3, - fontSize: AppConstants() - .title_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: themeController + .currentColor.sc3, + fontSize: AppConstants() + .title_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox(width: 22.rpx)), ), @@ -507,15 +481,13 @@ class _SettingPageState extends State { children: [ Text( '退出登录'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc3, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc3, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -554,15 +526,13 @@ class _SettingPageState extends State { children: [ Text( '注销账号'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: themeController.currentColor.sc9, - fontFamily: 'Inter', - fontSize: - AppConstants().normal_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc9, + fontFamily: 'Inter', + fontSize: + AppConstants().normal_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( width: 17.rpx, @@ -598,30 +568,24 @@ class _SettingPageState extends State { children: [ Text( 'ICP备案号:浙ICP备2023000785号-1'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: - themeController.currentColor.sc4, - fontFamily: 'Inter', - fontSize: AppConstants() - .smaller_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc4, + fontFamily: 'Inter', + fontSize: + AppConstants().smaller_text_fontSize, + letterSpacing: 0.0, + ), ), Text( 'Copyright © 202-2025 嘉兴太和信息技术有限责任公司 版权所有' .tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - color: - themeController.currentColor.sc4, - fontFamily: 'Inter', - fontSize: AppConstants() - .smaller_text_fontSize, - letterSpacing: 0.0, - ), + style: TextStyle( + color: themeController.currentColor.sc4, + fontFamily: 'Inter', + fontSize: + AppConstants().smaller_text_fontSize, + letterSpacing: 0.0, + ), ), ].divide(SizedBox( height: 17.rpx, @@ -666,12 +630,12 @@ class _SettingPageState extends State { children: [ Text( title, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Inter', - color: const Color(0xFFC2CED7), - fontSize: 30.rpx, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter', + color: const Color(0xFFC2CED7), + fontSize: 30.rpx, + letterSpacing: 0.0, + ), ), ClipRRect( borderRadius: BorderRadius.circular(8.rpx), diff --git a/lib/pages/user/update_user_page.dart b/lib/pages/user/update_user_page.dart index 26d0dfb..8539b11 100644 --- a/lib/pages/user/update_user_page.dart +++ b/lib/pages/user/update_user_page.dart @@ -74,12 +74,12 @@ class _UpdateUserPageState extends State { children: [ Text( '修改资料页.个人信息'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), Positioned( left: 0, @@ -119,13 +119,11 @@ class _UpdateUserPageState extends State { 16.rpx, 0.rpx, 16.rpx, 0.rpx), child: Text( '修改资料页.保存'.tr, - style: FlutterFlowTheme.of(context) - .titleSmall - .override( - fontFamily: 'Inter Tight', - color: themeController.currentColor.sc3, - letterSpacing: 0.0, - ), + style: TextStyle( + fontFamily: 'Inter Tight', + color: themeController.currentColor.sc3, + letterSpacing: 0.0, + ), ), ), ), @@ -187,14 +185,12 @@ class _UpdateUserPageState extends State { child: Center( child: Text( '修改资料页.点击更换头像'.tr, - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController.currentColor.sc2, - ), + style: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController.currentColor.sc2, + ), ), ), ), @@ -243,25 +239,19 @@ class _UpdateUserPageState extends State { obscureText: false, decoration: InputDecoration( isDense: true, - labelStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - ), + labelStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + ), hintText: '未命名'.tr, - hintStyle: - FlutterFlowTheme.of(context) - .labelMedium - .override( - fontFamily: 'Inter', - fontSize: 26.rpx, - letterSpacing: 0.0, - color: themeController - .currentColor.sc4, - ), + hintStyle: TextStyle( + fontFamily: 'Inter', + fontSize: 26.rpx, + letterSpacing: 0.0, + color: themeController + .currentColor.sc4, + ), enabledBorder: OutlineInputBorder( borderSide: BorderSide( color: Color(0x00000000), @@ -282,9 +272,6 @@ class _UpdateUserPageState extends State { ), errorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of( - context) - .error, width: 1.rpx, ), borderRadius: @@ -294,9 +281,6 @@ class _UpdateUserPageState extends State { focusedErrorBorder: OutlineInputBorder( borderSide: BorderSide( - color: FlutterFlowTheme.of( - context) - .error, width: 1.rpx, ), borderRadius: @@ -305,9 +289,7 @@ class _UpdateUserPageState extends State { ), filled: false, ), - style: FlutterFlowTheme.of(context) - .bodyMedium - .override( + style: TextStyle( fontFamily: 'Inter', fontSize: 26.rpx, letterSpacing: 0.0, diff --git a/lib/pages/user/user_scheme_page.dart b/lib/pages/user/user_scheme_page.dart index 5e1fb51..674656c 100644 --- a/lib/pages/user/user_scheme_page.dart +++ b/lib/pages/user/user_scheme_page.dart @@ -61,12 +61,12 @@ class _UserSchemePageState extends State { /// 居中标题 Text( '用户协议'.tr, - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: 'Readex Pro', - color: themeController.currentColor.sc3, - letterSpacing: 0, - fontSize: 30.rpx, - ), + style: TextStyle( + fontFamily: 'Readex Pro', + color: themeController.currentColor.sc3, + letterSpacing: 0, + fontSize: 30.rpx, + ), ), /// 左边返回按钮 diff --git a/pubspec.yaml b/pubspec.yaml index 3b3b543..347d895 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -13,7 +13,8 @@ dependencies: sdk: flutter ef: git: - url: http://admin@git.real.he-info.cn:8080/r/ef.git + # url: http://admin@git.real.he-info.cn:8080/r/ef.git + url: https://gitea.wslpc.real.he-info.cn:94/flutter/ef.git ref: main get_storage: ^2.1.1 cupertino_icons: ^1.0.8