Browse Source

FTitleField新增属性

loki.wu 2 years ago
parent
commit
2d3bdfbeb5
2 changed files with 11 additions and 5 deletions
  1. 7 1
      lib/components/form_relevant/title_filed_compenent.dart
  2. 4 4
      pubspec.yaml

+ 7 - 1
lib/components/form_relevant/title_filed_compenent.dart

@@ -23,6 +23,9 @@ class FTitleField extends StatelessWidget implements FWidget {
   ///是否加粗标题
   late bool isBold;
 
+  //标题颜色
+  late Color? titleColor;
+
   ///是否是必填项
   late bool isRequiredField;
   FTitleField(
@@ -35,6 +38,7 @@ class FTitleField extends StatelessWidget implements FWidget {
     this.minTitleWidth = 60,
     this.isBold = true,
     this.isRequiredField = false,
+    this.titleColor = null,
   }) : super(key: key);
   @override
   FWidget build(BuildContext context) {
@@ -71,7 +75,9 @@ class FTitleField extends StatelessWidget implements FWidget {
         TextSpan(children: [
           TextSpan(
             text: title,
-            style: isBold ? TextStyle(fontWeight: FontWeight.bold) : null,
+            style: isBold
+                ? TextStyle(fontWeight: FontWeight.bold, color: titleColor)
+                : TextStyle(color: titleColor),
           ),
           if (isRequiredField) ...[
             TextSpan(

+ 4 - 4
pubspec.yaml

@@ -42,19 +42,19 @@ dependency_overrides:
   fis_common:
     git:
       url: http://git.ius.plus:88/Project-Wing/fis_lib_common.git
-      ref: 63dcf70026
+      ref: 9cd9474
   fis_jsonrpc:
     git:
       url: http://git.ius.plus:88/Project-Wing/fis_lib_jsonrpc.git
-      ref: c241544354
+      ref: a67ae0c
   fis_i18n:
     git:
       url: http://git.ius.plus:88/Project-Wing/fis_lib_i18n.git
-      ref: e2016d4
+      ref: db8a335
   fis_ui:
     git:
       url: http://git.ius.plus:88/Project-Wing/fis_lib_ui.git
-      ref: 168a553
+      ref: adf8a2d
       # path: ../fis_lib_ui
 # For information on the generic Dart part of this file, see the
 # following page: https://dart.dev/tools/pub/pubspec