Skip to content

Commit 748278f

Browse files
committed
文本样式
1 parent eb87940 commit 748278f

File tree

2 files changed

+36
-14
lines changed

2 files changed

+36
-14
lines changed

lib/common/style/GSYStyle.dart

Lines changed: 27 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,25 @@ class GSYConstant {
188188
fontSize: middleTextWhiteSize,
189189
);
190190

191+
static const middleTextBold = TextStyle(
192+
color: Color(GSYColors.mainTextColor),
193+
fontSize: middleTextWhiteSize,
194+
fontWeight:FontWeight.bold,
195+
);
196+
197+
198+
static const middleTextWhiteBold = TextStyle(
199+
color: Color(GSYColors.TextColorWhite),
200+
fontSize: middleTextWhiteSize,
201+
fontWeight:FontWeight.bold,
202+
);
203+
204+
static const middleSubTextBold = TextStyle(
205+
color: Color(GSYColors.subTextColor),
206+
fontSize: middleTextWhiteSize,
207+
fontWeight:FontWeight.bold,
208+
);
209+
191210
static const largeText = TextStyle(
192211
color: Color(GSYColors.mainTextColor),
193212
fontSize: bigTextSize,
@@ -204,21 +223,24 @@ class GSYConstant {
204223
fontSize: bigTextSize,
205224
);
206225

226+
static const largeTextWhiteBold = TextStyle(
227+
color: Color(GSYColors.TextColorWhite),
228+
fontSize: bigTextSize,
229+
fontWeight: FontWeight.bold,
230+
);
231+
207232
static const largeLargeTextWhite = TextStyle(
208233
color: Color(GSYColors.TextColorWhite),
209234
fontSize: largetTextSize,
235+
fontWeight: FontWeight.bold,
210236
);
211237

212238
static const largeLargeText = TextStyle(
213239
color: Color(GSYColors.primaryValue),
214240
fontSize: largetTextSize,
215-
);
216-
217-
static const largeTextWhiteBold = TextStyle(
218-
color: Color(GSYColors.TextColorWhite),
219-
fontSize: bigTextSize,
220241
fontWeight: FontWeight.bold,
221242
);
243+
222244
}
223245

224246
///字符文本

lib/widget/GSYMarkdownWidget.dart

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@ class GSYMarkdownWidget extends StatelessWidget {
4242
return _getCommonSheet(context, Color(GSYColors.primaryValue)).copyWith(
4343
p: GSYConstant.smallTextWhite,
4444
h1: GSYConstant.largeLargeTextWhite,
45-
h2: GSYConstant.largeTextWhite,
46-
h3: GSYConstant.normalTextWhite,
45+
h2: GSYConstant.largeTextWhiteBold,
46+
h3: GSYConstant.normalTextMitWhiteBold,
4747
h4: GSYConstant.middleTextWhite,
4848
h5: GSYConstant.smallTextWhite,
4949
h6: GSYConstant.smallTextWhite,
5050
em: const TextStyle(fontStyle: FontStyle.italic),
51-
strong: GSYConstant.middleTextWhite,
51+
strong: GSYConstant.middleTextWhiteBold,
5252
code: GSYConstant.subSmallText,
5353
);
5454
}
@@ -57,12 +57,12 @@ class GSYMarkdownWidget extends StatelessWidget {
5757
return _getCommonSheet(context, Color(GSYColors.primaryValue)).copyWith(
5858
p: GSYConstant.smallText,
5959
h1: GSYConstant.largeLargeText,
60-
h2: GSYConstant.largeText,
61-
h3: GSYConstant.normalText,
60+
h2: GSYConstant.largeTextBold,
61+
h3: GSYConstant.normalTextBold,
6262
h4: GSYConstant.middleText,
6363
h5: GSYConstant.smallText,
6464
h6: GSYConstant.smallText,
65-
strong: GSYConstant.middleText,
65+
strong: GSYConstant.middleTextBold,
6666
code: GSYConstant.subSmallText,
6767
);
6868
}
@@ -71,13 +71,13 @@ class GSYMarkdownWidget extends StatelessWidget {
7171
return _getCommonSheet(context, Color(GSYColors.subTextColor)).copyWith(
7272
p: GSYConstant.smallTextWhite,
7373
h1: GSYConstant.largeLargeTextWhite,
74-
h2: GSYConstant.largeTextWhite,
75-
h3: GSYConstant.normalTextWhite,
74+
h2: GSYConstant.largeTextWhiteBold,
75+
h3: GSYConstant.normalTextMitWhiteBold,
7676
h4: GSYConstant.middleTextWhite,
7777
h5: GSYConstant.smallTextWhite,
7878
h6: GSYConstant.smallTextWhite,
7979
em: const TextStyle(fontStyle: FontStyle.italic),
80-
strong: GSYConstant.middleTextWhite,
80+
strong: GSYConstant.middleTextWhiteBold,
8181
code: GSYConstant.subSmallText,
8282
);
8383
}

0 commit comments

Comments
 (0)