Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
B
book-app
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
book-app
Commits
ed335851
提交
ed335851
authored
1月 20, 2024
作者:
yueweilu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修正
上级
07b17b5c
显示空白字符变更
内嵌
并排
正在显示
40 个修改的文件
包含
201 行增加
和
161 行删除
+201
-161
Podfile.lock
ios/Podfile.lock
+12
-0
index.dart
lib/pages/ad/index.dart
+1
-0
view.dart
lib/pages/ad/view.dart
+5
-5
index.dart
lib/pages/book_category/index.dart
+1
-0
item.dart
lib/pages/book_category/widgets/item.dart
+5
-5
index.dart
lib/pages/book_detail/index.dart
+1
-0
view.dart
lib/pages/book_detail/view.dart
+12
-12
book.dart
lib/pages/book_detail/widgets/book.dart
+8
-8
study.dart
lib/pages/book_detail/widgets/study.dart
+7
-7
index.dart
lib/pages/book_info/index.dart
+1
-0
view.dart
lib/pages/book_info/view.dart
+9
-9
index.dart
lib/pages/book_pay/index.dart
+1
-0
view.dart
lib/pages/book_pay/view.dart
+5
-5
item.dart
lib/pages/book_pay/widgets/item.dart
+13
-13
pay_count.dart
lib/pages/book_pay/widgets/pay_count.dart
+8
-8
pay_way.dart
lib/pages/book_pay/widgets/pay_way.dart
+9
-9
index.dart
lib/pages/book_score/index.dart
+1
-0
item.dart
lib/pages/book_score/widgets/item.dart
+2
-2
view.dart
lib/pages/course/view.dart
+1
-1
index.dart
lib/pages/credit_points/index.dart
+2
-0
view.dart
lib/pages/credit_points/view.dart
+3
-3
view.dart
lib/pages/login/view.dart
+1
-1
view.dart
lib/pages/mine/view.dart
+17
-13
account.dart
lib/pages/mine/widgets/account.dart
+10
-10
read.dart
lib/pages/mine/widgets/read.dart
+14
-5
user.dart
lib/pages/mine/widgets/user.dart
+13
-13
view.dart
lib/pages/search/view.dart
+1
-1
index.dart
lib/pages/study_report/index.dart
+2
-0
card.dart
lib/pages/study_report/widgets/card.dart
+8
-8
item.dart
lib/pages/user_coupon/widgets/item.dart
+5
-1
view.dart
lib/pages/user_gender/view.dart
+1
-1
view.dart
lib/pages/user_info/view.dart
+1
-1
view.dart
lib/pages/user_nick/view.dart
+1
-1
view.dart
lib/pages/user_set/view.dart
+1
-1
theme.dart
lib/theme.dart
+1
-1
index.dart
lib/utils/index.dart
+1
-0
styles.dart
lib/utils/styles.dart
+12
-12
app_bar.dart
lib/widgets/app_bar.dart
+1
-1
dialog.dart
lib/widgets/dialog.dart
+3
-3
tab_bar.dart
lib/widgets/tab_bar.dart
+1
-1
没有找到文件。
ios/Podfile.lock
浏览文件 @
ed335851
...
...
@@ -2,6 +2,8 @@ PODS:
- audio_session (0.0.1):
- Flutter
- Flutter (1.0.0)
- flutter_app_update (0.0.1):
- Flutter
- flutter_inappwebview (0.0.1):
- Flutter
- flutter_inappwebview/Core (= 0.0.1)
...
...
@@ -24,6 +26,8 @@ PODS:
- image_picker_ios (0.0.1):
- Flutter
- OrderedSet (5.0.0)
- package_info_plus (0.4.5):
- Flutter
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
...
...
@@ -37,11 +41,13 @@ PODS:
DEPENDENCIES:
- audio_session (from `.symlinks/plugins/audio_session/ios`)
- Flutter (from `Flutter`)
- flutter_app_update (from `.symlinks/plugins/flutter_app_update/ios`)
- flutter_inappwebview (from `.symlinks/plugins/flutter_inappwebview/ios`)
- flutter_sound (from `.symlinks/plugins/flutter_sound/ios`)
- flutter_tts (from `.symlinks/plugins/flutter_tts/ios`)
- fluwx (from `.symlinks/plugins/fluwx/ios`)
- image_picker_ios (from `.symlinks/plugins/image_picker_ios/ios`)
- package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
- permission_handler_apple (from `.symlinks/plugins/permission_handler_apple/ios`)
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
...
...
@@ -57,6 +63,8 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/audio_session/ios"
Flutter:
:path: Flutter
flutter_app_update:
:path: ".symlinks/plugins/flutter_app_update/ios"
flutter_inappwebview:
:path: ".symlinks/plugins/flutter_inappwebview/ios"
flutter_sound:
...
...
@@ -67,6 +75,8 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/fluwx/ios"
image_picker_ios:
:path: ".symlinks/plugins/image_picker_ios/ios"
package_info_plus:
:path: ".symlinks/plugins/package_info_plus/ios"
path_provider_foundation:
:path: ".symlinks/plugins/path_provider_foundation/darwin"
permission_handler_apple:
...
...
@@ -77,6 +87,7 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
audio_session: 4f3e461722055d21515cf3261b64c973c062f345
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
flutter_app_update: 65f61da626cb111d1b24674abc4b01728d7723bc
flutter_inappwebview: 3d32228f1304635e7c028b0d4252937730bbc6cf
flutter_sound: c60effa2a350fb977885f0db2fbc4c1ad5160900
flutter_sound_core: 26c10e5832e76aaacfae252d8925232281c486ae
...
...
@@ -84,6 +95,7 @@ SPEC CHECKSUMS:
fluwx: 3c7b6df42f83d444d4538f3eaeae079f12d30c37
image_picker_ios: 99dfe1854b4fa34d0364e74a78448a0151025425
OrderedSet: aaeb196f7fef5a9edf55d89760da9176ad40b93c
package_info_plus: 115f4ad11e0698c8c1c5d8a689390df880f47e85
path_provider_foundation: 3784922295ac71e43754bd15e0653ccfd36a147c
permission_handler_apple: e76247795d700c14ea09e3a2d8855d41ee80a2e6
shared_preferences_foundation: b4c3b4cddf1c21f02770737f147a3f5da9d39695
...
...
lib/pages/ad/index.dart
浏览文件 @
ed335851
...
...
@@ -3,6 +3,7 @@ library ad;
import
'dart:async'
;
import
'package:flutter/material.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:get/get.dart'
;
import
'package:go_router/go_router.dart'
;
import
'package:shared_preferences/shared_preferences.dart'
;
...
...
lib/pages/ad/view.dart
浏览文件 @
ed335851
...
...
@@ -18,15 +18,15 @@ class _AdPageState extends State<AdPage> {
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
Container
(
height:
200
,
width:
200
,
height:
200
.
w
,
width:
200
.
w
,
color:
Colors
.
lime
,
),
const
SizedBox
(
height:
20
),
SizedBox
(
height:
20
.
w
),
Text
(
'倒计时:
${controller._countdown}
'
,
style:
const
TextStyle
(
fontSize:
20
style:
TextStyle
(
fontSize:
20
.
w
),
),
],
...
...
lib/pages/book_category/index.dart
浏览文件 @
ed335851
...
...
@@ -3,6 +3,7 @@ library book_category;
import
'package:flutter/material.dart'
;
import
'package:flutter_book/theme.dart'
;
import
'package:flutter_book/utils/index.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'../../models/index.dart'
;
...
...
lib/pages/book_category/widgets/item.dart
浏览文件 @
ed335851
...
...
@@ -24,8 +24,8 @@ class _BuildItemState extends State<BuildItem> {
});
},
child:
Container
(
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
15
),
height:
30
,
margin:
EdgeInsets
.
symmetric
(
horizontal:
15
.
w
),
height:
30
.
w
,
color:
Colors
.
white
,
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
...
...
@@ -33,17 +33,17 @@ class _BuildItemState extends State<BuildItem> {
Row
(
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
Text
(
widget
.
model
.
name
??
''
,
style:
TextStyle
(
fontSize:
14
,
color:
widget
.
model
.
seen
==
0
?
Colours
.
c3
:
Colours
.
c9
,
fontWeight:
Fonts
.
medium
,
height:
1.4
),),
Text
(
widget
.
model
.
name
??
''
,
style:
TextStyle
(
fontSize:
14
.
w
,
color:
widget
.
model
.
seen
==
0
?
Colours
.
c3
:
Colours
.
c9
,
fontWeight:
Fonts
.
medium
,
height:
1.4
),),
Gaps
.
hGaps5
,
widget
.
model
.
isReading
==
1
?
Container
(
height:
17
,
width:
17
,
alignment:
Alignment
.
center
,
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
8.5
),
borderRadius:
BorderRadius
.
circular
(
8.5
.
w
),
border:
Border
.
all
(
width:
1
,
color:
AppTheme
.
primary
)
),
child:
const
Text
(
'试'
,
style:
TextStyle
(
fontSize:
12
,
color:
AppTheme
.
primary
),),
child:
Text
(
'试'
,
style:
TextStyle
(
fontSize:
12
.
w
,
color:
AppTheme
.
primary
),),
):
const
SizedBox
(),
],
),
...
...
lib/pages/book_detail/index.dart
浏览文件 @
ed335851
...
...
@@ -5,6 +5,7 @@ import 'package:flutter_book/apis/index.dart';
import
'package:flutter_book/theme.dart'
;
import
'package:flutter_book/utils/index.dart'
;
import
'package:flutter_book/widgets/index.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:flutter_star/custom_rating.dart'
;
import
'package:flutter_star/star.dart'
;
import
'package:flutter_star/star_score.dart'
;
...
...
lib/pages/book_detail/view.dart
浏览文件 @
ed335851
...
...
@@ -48,7 +48,7 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
children:
[
BuildBook
(
model:
controller
.
bookDetails
,),
Container
(
height:
10
,
height:
10
.
w
,
color:
const
Color
(
0xFFF9F9F9
),
),
BuildStudy
(
model:
controller
.
bookDetails
,),
...
...
@@ -59,9 +59,9 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
TabBar
(
labelColor:
AppTheme
.
primary
,
// isScrollable: true,
labelStyle:
const
TextStyle
(
fontSize:
15
,
height:
1.4
,
fontWeight:
Fonts
.
medium
),
labelStyle:
TextStyle
(
fontSize:
15
.
w
,
height:
1.4
,
fontWeight:
Fonts
.
medium
),
unselectedLabelColor:
Colours
.
c9
,
unselectedLabelStyle:
const
TextStyle
(
fontSize:
15
,
height:
1.4
),
unselectedLabelStyle:
TextStyle
(
fontSize:
15
.
w
,
height:
1.4
),
indicatorSize:
TabBarIndicatorSize
.
label
,
indicatorColor:
AppTheme
.
primary
,
tabs:
controller
.
tabs
,
...
...
@@ -74,9 +74,9 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
children:
[
BookCategoryPage
(
chapters:
controller
.
chapters
,),
Container
(
margin:
const
EdgeInsets
.
only
(
left:
15
,
right:
15
,
top:
12
),
margin:
EdgeInsets
.
only
(
left:
15
.
w
,
right:
15
.
w
,
top:
12
.
w
),
// color: Colors.lightBlue,
child:
Text
(
controller
.
bookDetails
.
content
??
''
,
style:
const
TextStyle
(
fontSize:
12
,
height:
1.5
,
color:
Colours
.
c3
),),
child:
Text
(
controller
.
bookDetails
.
content
??
''
,
style:
TextStyle
(
fontSize:
12
.
w
,
height:
1.5
,
color:
Colours
.
c3
),),
),
BookInfoPage
(
model:
controller
.
bookDetails
,)
],
...
...
@@ -87,7 +87,7 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
),
bottomNavigationBar:
SafeArea
(
child:
Container
(
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
15
),
margin:
EdgeInsets
.
symmetric
(
horizontal:
15
.
w
),
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceEvenly
,
children:
[
...
...
@@ -100,7 +100,7 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
alignment:
Alignment
.
center
,
height:
35
,
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
17.5
),
borderRadius:
BorderRadius
.
circular
(
17.5
.
w
),
border:
Border
.
all
(
width:
0.5
,
color:
Colours
.
c9
...
...
@@ -108,7 +108,7 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
// color: Colours.cE0.withOpacity(0.5),
),
// padding: EdgeInsets.symmetric(vertical: 8),
child:
controller
.
bookDetails
.
isHave
==
1
?
Text
(
'学习报告'
,
style:
TextStyle
(
fontSize:
13
,
color:
Colours
.
c9
,
height:
1.5
),):
Text
(
'加入书架'
,
style:
TextStyle
(
fontSize:
13
,
color:
AppTheme
.
primary
,
height:
1.5
),),
child:
controller
.
bookDetails
.
isHave
==
1
?
Text
(
'学习报告'
,
style:
TextStyle
(
fontSize:
13
.
w
,
color:
Colours
.
c9
,
height:
1.5
),):
Text
(
'加入书架'
,
style:
TextStyle
(
fontSize:
13
.
w
,
color:
AppTheme
.
primary
,
height:
1.5
),),
),
),
),
...
...
@@ -127,13 +127,13 @@ class _BookDetailPageState extends State<BookDetailPage> with SingleTickerProvid
},
child:
Container
(
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
17.5
),
borderRadius:
BorderRadius
.
circular
(
17.5
.
w
),
color:
AppTheme
.
primary
.
withOpacity
(
0.1
)
),
height:
35
,
height:
35
.
w
,
alignment:
Alignment
.
center
,
padding:
const
EdgeInsets
.
symmetric
(
vertical:
8
),
child:
const
Text
(
'阅读'
,
style:
TextStyle
(
fontSize:
13
,
color:
AppTheme
.
primary
,
height:
1.5
),),
padding:
EdgeInsets
.
symmetric
(
vertical:
8
.
w
),
child:
Text
(
'阅读'
,
style:
TextStyle
(
fontSize:
13
.
w
,
color:
AppTheme
.
primary
,
height:
1.5
),),
),
),
)
...
...
lib/pages/book_detail/widgets/book.dart
浏览文件 @
ed335851
...
...
@@ -24,7 +24,7 @@ class BuildBook extends StatelessWidget {
children:
[
///左侧
Container
(
margin:
const
EdgeInsets
.
only
(
left:
15
,
right:
15
),
margin:
EdgeInsets
.
only
(
left:
15
.
w
,
right:
15
.
w
),
child:
Row
(
children:
[
CustomCard
(
...
...
@@ -37,7 +37,7 @@ class BuildBook extends StatelessWidget {
Expanded
(
child:
Container
(
// color: Colors.cyan,
padding:
const
EdgeInsets
.
only
(
top:
12
,
bottom:
15
),
padding:
EdgeInsets
.
only
(
top:
12
.
w
,
bottom:
15
.
w
),
child:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
crossAxisAlignment:
CrossAxisAlignment
.
start
,
...
...
@@ -45,17 +45,17 @@ class BuildBook extends StatelessWidget {
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
Text
(
model
.
bookName
??
''
,
style:
const
TextStyle
(
fontSize:
16
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),
maxLines:
1
,
overflow:
TextOverflow
.
ellipsis
,),
const
SizedBox
(
height:
5
,),
Text
(
model
.
authors
??
''
,
style:
const
TextStyle
(
fontSize:
13
,
fontWeight:
FontWeight
.
w400
,
color:
Colours
.
c6
)),
Text
(
model
.
bookName
??
''
,
style:
TextStyle
(
fontSize:
16
.
w
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),
maxLines:
1
,
overflow:
TextOverflow
.
ellipsis
,),
SizedBox
(
height:
5
.
w
,),
Text
(
model
.
authors
??
''
,
style:
TextStyle
(
fontSize:
13
.
w
,
fontWeight:
FontWeight
.
w400
,
color:
Colours
.
c6
)),
],
),
Row
(
children:
[
Text
(
'¥
${model.vipPrice}
'
,
style:
const
TextStyle
(
fontSize:
14
,
fontWeight:
FontWeight
.
w500
,
color:
AppTheme
.
primary
)),
Text
(
'¥
${model.vipPrice}
'
,
style:
TextStyle
(
fontSize:
14
.
w
,
fontWeight:
FontWeight
.
w500
,
color:
AppTheme
.
primary
)),
Gaps
.
hGaps10
,
Text
(
'¥
${model.price}
'
,
style:
const
TextStyle
(
fontSize:
12
,
color:
Colours
.
c9
,
Text
(
'¥
${model.price}
'
,
style:
TextStyle
(
fontSize:
12
.
w
,
color:
Colours
.
c9
,
decoration:
TextDecoration
.
lineThrough
,
decorationColor:
Colours
.
c9
,
// 可选,指定删除线的颜色
decorationThickness:
1
...
...
lib/pages/book_detail/widgets/study.dart
浏览文件 @
ed335851
...
...
@@ -15,7 +15,7 @@ class _BuildStudyState extends State<BuildStudy> {
@override
Widget
build
(
BuildContext
context
)
{
return
Container
(
height:
50
,
height:
50
.
w
,
color:
Colors
.
white
,
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceEvenly
,
...
...
@@ -27,8 +27,8 @@ class _BuildStudyState extends State<BuildStudy> {
Row
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
Text
(
widget
.
model
.
rating
??
''
,
style:
const
TextStyle
(
fontSize:
16
,
height:
1.5
,
fontWeight:
Fonts
.
medium
,
color:
AppTheme
.
primary
)),
const
Text
(
'/5.0'
,
style:
TextStyle
(
fontSize:
13
,
height:
1.5
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c9
),)
Text
(
widget
.
model
.
rating
??
''
,
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.5
,
fontWeight:
Fonts
.
medium
,
color:
AppTheme
.
primary
)),
Text
(
'/5.0'
,
style:
TextStyle
(
fontSize:
13
.
w
,
height:
1.5
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c9
),)
],
),
AbsorbPointer
(
...
...
@@ -36,10 +36,10 @@ class _BuildStudyState extends State<BuildStudy> {
child:
CustomRating
(
max:
5
,
score:
widget
.
model
.
rating
!=
null
?
double
.
parse
(
widget
.
model
.
rating
!):
0
,
star:
const
Star
(
star:
Star
(
progress:
7
,
fillColor:
AppTheme
.
primary
,
size:
12
,
size:
12
.
w
,
emptyColor:
Colours
.
cE2
,
),
onRating:
(
double
a
)
{},
),
...
...
@@ -55,7 +55,7 @@ class _BuildStudyState extends State<BuildStudy> {
children:
[
TextSpan
(
text:
widget
.
model
.
readNum
.
toString
(),
style:
const
TextStyle
(
fontSize:
16
,
color:
Colours
.
c3
,
fontWeight:
Fonts
.
medium
,
height:
1.3
)
style:
TextStyle
(
fontSize:
16
.
w
,
color:
Colours
.
c3
,
fontWeight:
Fonts
.
medium
,
height:
1.3
)
),
// TextSpan(
// text: '万',
...
...
@@ -63,7 +63,7 @@ class _BuildStudyState extends State<BuildStudy> {
// )
]
)),
const
Text
(
'学习次数'
,
style:
TextStyle
(
fontSize:
12
,
color:
Colours
.
c9
,
height:
1.3
)),
Text
(
'学习次数'
,
style:
TextStyle
(
fontSize:
12
.
w
,
color:
Colours
.
c9
,
height:
1.3
)),
],
),
)
...
...
lib/pages/book_info/index.dart
浏览文件 @
ed335851
...
...
@@ -3,6 +3,7 @@ library book_info;
import
'package:flutter/material.dart'
;
import
'package:flutter_book/utils/index.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:flutter_star/custom_rating.dart'
;
import
'package:flutter_star/star.dart'
;
import
'package:flutter_star/star_score.dart'
;
...
...
lib/pages/book_info/view.dart
浏览文件 @
ed335851
...
...
@@ -10,7 +10,7 @@ class BookInfoPage extends StatelessWidget {
@override
Widget
build
(
BuildContext
context
)
{
return
Container
(
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
15
,
vertical:
18
),
margin:
EdgeInsets
.
symmetric
(
horizontal:
15
.
w
,
vertical:
18
.
w
),
child:
Column
(
children:
[
// 评分容器
...
...
@@ -19,19 +19,19 @@ class BookInfoPage extends StatelessWidget {
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
children:
[
const
Text
(
'评分及书评'
,
style:
TextStyle
(
fontSize:
14
,
color:
Colours
.
c3
,
height:
1.6
,
fontWeight:
Fonts
.
medium
),),
Text
(
'评分及书评'
,
style:
TextStyle
(
fontSize:
14
.
w
,
color:
Colours
.
c3
,
height:
1.6
,
fontWeight:
Fonts
.
medium
),),
Row
(
children:
[
GestureDetector
(
child:
const
Text
(
'查看全部'
,
style:
TextStyle
(
fontSize:
11
,
color:
Colours
.
c9
),),
child:
Text
(
'查看全部'
,
style:
TextStyle
(
fontSize:
11
.
w
,
color:
Colours
.
c9
),),
onTap:
(){
context
.
pushNamed
(
Routes
.
bookScore
,
queryParameters:
{
'book_id'
:
'110'
});
},
),
Gaps
.
hGaps5
,
SizedBox
(
width:
5
,
height:
8
,
width:
5
.
w
,
height:
8
.
w
,
// color: Colors.cyan,
child:
Image
.
asset
(
'assets/images/right_arrow.png'
,
...
...
@@ -42,23 +42,23 @@ class BookInfoPage extends StatelessWidget {
],
),
Container
(
margin:
const
EdgeInsets
.
symmetric
(
vertical:
10
),
margin:
EdgeInsets
.
symmetric
(
vertical:
10
.
w
),
child:
Row
(
children:
[
Column
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
// crossAxisAlignment: CrossAxisAlignment.center,
children:
[
Text
(
model
.
rating
??
''
,
style:
const
TextStyle
(
fontSize:
35
,
height:
1.5
,
fontWeight:
Fonts
.
boldSemi
,
color:
AppTheme
.
primary
),),
Text
(
model
.
rating
??
''
,
style:
TextStyle
(
fontSize:
35
.
w
,
height:
1.5
.
w
,
fontWeight:
Fonts
.
boldSemi
,
color:
AppTheme
.
primary
),),
AbsorbPointer
(
absorbing:
true
,
child:
CustomRating
(
max:
5
,
score:
model
.
rating
!=
null
?
double
.
parse
(
model
.
rating
!):
0
,
star:
const
Star
(
star:
Star
(
progress:
7
,
fillColor:
AppTheme
.
primary
,
size:
12
,
size:
12
.
w
,
emptyColor:
Colours
.
cE2
,
),
onRating:
(
double
a
)
{},
),
...
...
lib/pages/book_pay/index.dart
浏览文件 @
ed335851
...
...
@@ -4,6 +4,7 @@ library book_pay;
import
'package:decimal/decimal.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter_book/theme.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:flutter_slidable/flutter_slidable.dart'
;
import
'package:get/get.dart'
;
...
...
lib/pages/book_pay/view.dart
浏览文件 @
ed335851
...
...
@@ -32,25 +32,25 @@ class _BookPayPageState extends State<BookPayPage> {
itemCount:
controller
.
buy
.
length
,
),
const
SizedBox
(
height:
10
,),
SizedBox
(
height:
10
.
w
,),
Container
(
margin:
const
EdgeInsets
.
only
(
left:
10
,
right:
10
),
margin:
EdgeInsets
.
only
(
left:
10
.
w
,
right:
10
.
w
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
8
),
borderRadius:
BorderRadius
.
circular
(
8
.
w
),
color:
Colors
.
white
,
boxShadow:
[
BoxShadow
(
color:
Colours
.
cC7
.
withOpacity
(
0.5
),
spreadRadius:
2
,
blurRadius:
5
,
offset:
const
Offset
(
3
,
0
),
// changes the position of the shadow
offset:
Offset
(
3
.
w
,
0
),
// changes the position of the shadow
),
]
),
child:
Column
(
children:
[
_buildPointWidget
(),
Container
(
height:
0.5
,
color:
Colours
.
cF0
,
margin:
const
EdgeInsets
.
only
(
left:
10
),),
Container
(
height:
0.5
.
w
,
color:
Colours
.
cF0
,
margin:
EdgeInsets
.
only
(
left:
10
.
w
),),
_buildCouponWidget
()
],
),
...
...
lib/pages/book_pay/widgets/item.dart
浏览文件 @
ed335851
...
...
@@ -11,29 +11,29 @@ class BuildItem extends StatelessWidget {
Widget
build
(
BuildContext
context
)
{
return
Container
(
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
5
),
borderRadius:
BorderRadius
.
circular
(
5
.
w
),
color:
Colors
.
white
,
boxShadow:
[
BoxShadow
(
color:
const
Color
(
0xFFC7C7C7
).
withOpacity
(
0.5
),
spreadRadius:
2
,
blurRadius:
5
,
offset:
const
Offset
(
3
,
0
),
// changes the position of the shadow
spreadRadius:
2
.
w
,
blurRadius:
5
.
w
,
offset:
Offset
(
3
.
w
,
0
),
// changes the position of the shadow
),
]
),
margin:
const
EdgeInsets
.
only
(
left:
10
,
right:
10
,
top:
10
),
margin:
EdgeInsets
.
only
(
left:
10
.
w
,
right:
10
.
w
,
top:
10
.
w
),
height:
110
,
child:
Row
(
children:
[
///左侧
Container
(
margin:
const
EdgeInsets
.
only
(
left:
12
,
right:
11
),
margin:
EdgeInsets
.
only
(
left:
12
.
w
,
right:
11
.
w
),
child:
Row
(
children:
[
CustomCard
(
width:
72
,
height:
86
,
width:
72
.
w
,
height:
86
.
w
,
url:
model
.
img
??
''
,
)
],
...
...
@@ -42,7 +42,7 @@ class BuildItem extends StatelessWidget {
///右侧
Expanded
(
child:
Container
(
padding:
const
EdgeInsets
.
only
(
top:
12
,
bottom:
10
),
padding:
EdgeInsets
.
only
(
top:
12
.
w
,
bottom:
10
.
w
),
child:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
crossAxisAlignment:
CrossAxisAlignment
.
start
,
...
...
@@ -50,12 +50,12 @@ class BuildItem extends StatelessWidget {
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
Text
(
model
.
bookName
??
''
,
style:
const
TextStyle
(
fontSize:
13
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),
maxLines:
2
,
overflow:
TextOverflow
.
ellipsis
,),
const
SizedBox
(
height:
5
,),
Text
(
model
.
authors
??
''
,
style:
const
TextStyle
(
fontSize:
11
,
color:
Colours
.
c9
)),
Text
(
model
.
bookName
??
''
,
style:
TextStyle
(
fontSize:
13
.
w
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),
maxLines:
2
,
overflow:
TextOverflow
.
ellipsis
,),
SizedBox
(
height:
5
.
w
,),
Text
(
model
.
authors
??
''
,
style:
TextStyle
(
fontSize:
11
.
w
,
color:
Colours
.
c9
)),
],
),
Text
(
'¥
${model.vipPrice??''}
'
,
style:
const
TextStyle
(
fontSize:
14
,
fontWeight:
FontWeight
.
w500
,
color:
AppTheme
.
primary
)),
Text
(
'¥
${model.vipPrice??''}
'
,
style:
TextStyle
(
fontSize:
14
.
w
,
fontWeight:
FontWeight
.
w500
,
color:
AppTheme
.
primary
)),
],
),
),
...
...
lib/pages/book_pay/widgets/pay_count.dart
浏览文件 @
ed335851
...
...
@@ -6,26 +6,26 @@ class BuildPayCount extends StatelessWidget {
@override
Widget
build
(
BuildContext
context
)
{
return
Container
(
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
15
),
height:
55
,
padding:
EdgeInsets
.
symmetric
(
horizontal:
15
.
w
),
height:
55
.
w
,
color:
Colors
.
white
,
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
const
Row
(
Row
(
children:
[
Text
(
'应付:'
,
style:
TextStyle
(
fontSize:
14
,
color:
Colours
.
c3
,
height:
1.1
),),
Text
(
'¥98.9'
,
style:
TextStyle
(
fontSize:
15
,
color:
AppTheme
.
primary
,
fontWeight:
Fonts
.
medium
,
height:
1.1
),)
Text
(
'应付:'
,
style:
TextStyle
(
fontSize:
14
.
w
,
color:
Colours
.
c3
,
height:
1.1
),),
Text
(
'¥98.9'
,
style:
TextStyle
(
fontSize:
15
.
w
,
color:
AppTheme
.
primary
,
fontWeight:
Fonts
.
medium
,
height:
1.1
),)
],
),
Container
(
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
15
),
borderRadius:
BorderRadius
.
circular
(
15
.
w
),
color:
AppTheme
.
primary
),
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
13.5
,
vertical:
8
),
child:
const
Text
(
'确认支付'
,
style:
TextStyle
(
fontSize:
14
,
fontWeight:
Fonts
.
medium
,
color:
Colors
.
white
),),
padding:
EdgeInsets
.
symmetric
(
horizontal:
13.5
.
w
,
vertical:
8
.
w
),
child:
Text
(
'确认支付'
,
style:
TextStyle
(
fontSize:
14
.
w
,
fontWeight:
Fonts
.
medium
,
color:
Colors
.
white
),),
)
],
),
...
...
lib/pages/book_pay/widgets/pay_way.dart
浏览文件 @
ed335851
...
...
@@ -12,7 +12,7 @@ class BuildPayWay extends StatelessWidget {
return
Column
(
children:
[
Container
(
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
4
),
padding:
EdgeInsets
.
symmetric
(
horizontal:
4
.
w
),
color:
Colors
.
white
,
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
...
...
@@ -20,27 +20,27 @@ class BuildPayWay extends StatelessWidget {
Row
(
children:
[
Container
(
margin:
const
EdgeInsets
.
symmetric
(
vertical:
12
),
margin:
EdgeInsets
.
symmetric
(
vertical:
12
.
w
),
// color: Colors.cyan,
width:
20
,
height:
20
,
width:
20
.
w
,
height:
20
.
w
,
child:
Image
.
asset
(
model
.
icon
),
),
const
SizedBox
(
width:
7
,),
Text
(
model
.
name
,
style:
const
TextStyle
(
fontSize:
14
,
color:
Colours
.
c3
,
height:
1.1
)),
SizedBox
(
width:
7
.
w
,),
Text
(
model
.
name
,
style:
TextStyle
(
fontSize:
14
.
w
,
color:
Colours
.
c3
,
height:
1.1
)),
],
),
SizedBox
(
// color: Colors.cyan,
width:
15
,
height:
15
,
width:
15
.
w
,
height:
15
.
w
,
child:
Image
.
asset
(
model
.
selected
?
'assets/images/pay_check.png'
:
'assets/images/pay_uncheck.png'
),
)
],
),
),
Container
(
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
10
),
margin:
EdgeInsets
.
symmetric
(
horizontal:
10
.
w
),
height:
0.5
,
color:
Colours
.
cF0
,
)
...
...
lib/pages/book_score/index.dart
浏览文件 @
ed335851
...
...
@@ -5,6 +5,7 @@ import 'package:flutter/material.dart';
import
'package:flutter_book/theme.dart'
;
import
'package:flutter_book/utils/index.dart'
;
import
'package:flutter_book/widgets/index.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:flutter_star/flutter_star.dart'
;
import
'package:get/get.dart'
;
...
...
lib/pages/book_score/widgets/item.dart
浏览文件 @
ed335851
...
...
@@ -10,9 +10,9 @@ class BuildItem extends StatelessWidget {
@override
Widget
build
(
BuildContext
context
)
{
return
Container
(
margin:
const
EdgeInsets
.
only
(
left:
10
,
top:
10
,
right:
10
),
margin:
EdgeInsets
.
only
(
left:
10
.
w
,
top:
10
.
w
,
right:
10
.
w
),
child:
Container
(
padding:
const
EdgeInsets
.
only
(
left:
15
,
top:
15
,
right:
10
,
bottom:
15
),
padding:
EdgeInsets
.
only
(
left:
15
.
w
,
top:
15
.
w
,
right:
10
.
w
,
bottom:
15
.
w
),
decoration:
BoxDecoration
(
color:
Colors
.
white
,
boxShadow:
const
[
...
...
lib/pages/course/view.dart
浏览文件 @
ed335851
...
...
@@ -16,7 +16,7 @@ class _CoursePageState extends State<CoursePage> {
appBar:
CustomAppBar
(
titleSpacing:
0
,
title:
Padding
(
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
padding:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
child:
CustomInputSearch
(
readOnly:
true
,
hintText:
'请输入书籍名称'
,
...
...
lib/pages/credit_points/index.dart
浏览文件 @
ed335851
...
...
@@ -5,6 +5,7 @@ library credit_points;
import
'package:flutter/material.dart'
;
import
'package:flutter_book/theme.dart'
;
import
'package:flutter_book/utils/index.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:go_router/go_router.dart'
;
part
'view.dart'
;
\ No newline at end of file
lib/pages/credit_points/view.dart
浏览文件 @
ed335851
...
...
@@ -40,12 +40,12 @@ class CreditPointsPage extends StatelessWidget {
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
const
Column
(
Column
(
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
Text
(
'可用积分'
,
style:
TextStyle
(
fontSize:
16
,
height:
1.4
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),),
Text
(
'可用积分'
,
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.4
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),),
Gaps
.
vGaps13
,
Text
(
'999'
,
style:
TextStyle
(
fontSize:
25
,
height:
1.4
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),),
Text
(
'999'
,
style:
TextStyle
(
fontSize:
25
.
w
,
height:
1.4
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),),
],
),
Row
(
...
...
lib/pages/login/view.dart
浏览文件 @
ed335851
...
...
@@ -36,7 +36,7 @@ class _LoginPageState extends State<LoginPage> {
),
SafeArea
(
top:
false
,
minimum:
const
EdgeInsets
.
all
(
AppTheme
.
margin
).
copyWith
(
minimum:
EdgeInsets
.
all
(
AppTheme
.
margin
).
copyWith
(
// top:Screen.statusBar,
left:
25
,
right:
25
,
...
...
lib/pages/mine/view.dart
浏览文件 @
ed335851
...
...
@@ -15,7 +15,11 @@ class _MinePageState extends State<MinePage> {
init:
MineController
(),
builder:
(
controller
)
=>
Stack
(
children:
[
Image
.
asset
(
'assets/images/mine_bg.png'
),
Image
.
asset
(
'assets/images/mine_bg.png'
,
fit:
BoxFit
.
contain
,
width:
double
.
infinity
,
),
Scaffold
(
backgroundColor:
Colors
.
transparent
,
appBar:
CustomAppBar
(
...
...
@@ -84,28 +88,28 @@ class _MinePageState extends State<MinePage> {
controller
.
ads
.
isNotEmpty
?
Container
(
color:
Colors
.
transparent
,
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
10
),
padding:
EdgeInsets
.
symmetric
(
horizontal:
10
.
w
),
child:
BuildBanner
(
items:
controller
.
ads
),
):
const
SizedBox
(),
Gaps
.
vGaps5
,
BuildAccount
(
items:
controller
.
accounts
,),
Gaps
.
vGaps10
,
Container
(
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
margin:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
8
),
borderRadius:
BorderRadius
.
circular
(
8
.
w
),
color:
Colors
.
white
,
boxShadow:
[
BoxShadow
(
color:
const
Color
(
0xFFC7C7C7
).
withOpacity
(
0.5
),
offset:
const
Offset
(
3
,
0
),
offset:
Offset
(
3
.
w
,
0
),
blurRadius:
10
.
w
,
spreadRadius:
0
.
w
,
),
],
),
child:
ClipRRect
(
borderRadius:
BorderRadius
.
circular
(
8
),
borderRadius:
BorderRadius
.
circular
(
8
.
w
),
child:
Column
(
children:
[
GestureDetector
(
...
...
@@ -113,14 +117,14 @@ class _MinePageState extends State<MinePage> {
context
.
pushNamed
(
Routes
.
security
,
extra:
controller
.
userInfo
);
},
child:
_buildItem
(
'账户安全'
)
),
Container
(
color:
Colours
.
cLine
,
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
15
),
height:
1
,),
Container
(
color:
Colours
.
cLine
,
margin:
EdgeInsets
.
symmetric
(
horizontal:
15
.
w
),
height:
1
.
w
,),
// _buildItem('意见反馈'),
GestureDetector
(
onTap:
(){
context
.
pushNamed
(
Routes
.
feedback
);
},
child:
_buildItem
(
'意见反馈'
)
),
Container
(
color:
Colours
.
cLine
,
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
15
),
height:
1
,),
Container
(
color:
Colours
.
cLine
,
margin:
EdgeInsets
.
symmetric
(
horizontal:
15
.
w
),
height:
1
.
w
,),
GestureDetector
(
onTap:
(){
context
.
pushNamed
(
Routes
.
about
);
...
...
@@ -142,17 +146,17 @@ class _MinePageState extends State<MinePage> {
Widget
_buildItem
(
String
title
)
{
return
Container
(
padding:
const
EdgeInsets
.
only
(
left:
18
,
right:
15
),
padding:
EdgeInsets
.
only
(
left:
18
.
w
,
right:
15
.
w
),
color:
Colors
.
white
,
height:
42
,
height:
42
.
w
,
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
crossAxisAlignment:
CrossAxisAlignment
.
center
,
children:
[
Text
(
title
,
style:
const
TextStyle
(
fontSize:
14
,
color:
Colours
.
c3
,),),
Text
(
title
,
style:
TextStyle
(
fontSize:
14
.
w
,
color:
Colours
.
c3
,),),
SizedBox
(
width:
5
,
height:
8
,
width:
5
.
w
,
height:
8
.
w
,
child:
Image
.
asset
(
'assets/images/right_arrow.png'
),
)
],
...
...
lib/pages/mine/widgets/account.dart
浏览文件 @
ed335851
...
...
@@ -12,14 +12,14 @@ class BuildAccount extends StatelessWidget {
@override
Widget
build
(
BuildContext
context
)
{
return
Container
(
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
margin:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
8
),
borderRadius:
BorderRadius
.
circular
(
8
.
w
),
color:
Colors
.
white
,
boxShadow:
[
BoxShadow
(
color:
const
Color
(
0xFFC7C7C7
).
withOpacity
(
0.5
),
offset:
const
Offset
(
3
,
0
),
offset:
Offset
(
3
.
w
,
0
),
blurRadius:
10
.
w
,
spreadRadius:
0
.
w
,
),
...
...
@@ -29,11 +29,11 @@ class BuildAccount extends StatelessWidget {
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
Container
(
padding:
const
EdgeInsets
.
only
(
left:
17
,
top:
14
,
bottom:
14
,
right:
17
),
child:
const
Text
(
'我的账户'
,
style:
TextStyle
(
color:
Colours
.
c3
,
fontSize:
16
,
height:
1.6
,
fontWeight:
Fonts
.
medium
),),
padding:
EdgeInsets
.
only
(
left:
17
.
w
,
top:
14
.
w
,
bottom:
14
.
w
,
right:
17
.
w
),
child:
Text
(
'我的账户'
,
style:
TextStyle
(
color:
Colours
.
c3
,
fontSize:
16
.
w
,
height:
1.6
,
fontWeight:
Fonts
.
medium
),),
),
Container
(
padding:
const
EdgeInsets
.
only
(
bottom:
13
,
top:
5
),
padding:
EdgeInsets
.
only
(
bottom:
13
.
w
,
top:
5
.
w
),
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceEvenly
,
children:
items
.
map
((
model
){
...
...
@@ -53,13 +53,13 @@ class BuildAccount extends StatelessWidget {
child:
Image
.
asset
(
model
.
icon
!),
),
Gaps
.
vGaps5
,
Text
(
model
.
name
,
style:
TextStyle
(
fontSize:
12
.
w
,
height:
1.6
,
color:
Colours
.
c9
),),
Text
(
model
.
name
,
style:
TextStyle
(
fontSize:
12
.
w
,
height:
1.6
.
w
,
color:
Colours
.
c9
),),
items
.
indexOf
(
model
)
==
0
?
Row
(
children:
[
Text
(
model
.
value
.
toString
(),
style:
const
TextStyle
(
fontSize:
16
,
height:
1.6
,
fontWeight:
Fonts
.
medium
,
color:
AppTheme
.
primary
,),),
const
Text
(
'张'
,
style:
TextStyle
(
fontSize:
12
,
height:
1.6
,
color:
Colours
.
c3
),)
Text
(
model
.
value
.
toString
(),
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.6
,
fontWeight:
Fonts
.
medium
,
color:
AppTheme
.
primary
,),),
Text
(
'张'
,
style:
TextStyle
(
fontSize:
12
.
w
,
height:
1.6
.
w
,
color:
Colours
.
c3
),)
],
):
Text
(
model
.
value
.
toString
(),
style:
const
TextStyle
(
fontSize:
16
,
height:
1.6
,
color:
Colours
.
c3
),)
):
Text
(
model
.
value
.
toString
(),
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.6
.
w
,
color:
Colours
.
c3
),)
],
),
);
...
...
lib/pages/mine/widgets/read.dart
浏览文件 @
ed335851
...
...
@@ -18,10 +18,18 @@ class BuildRead extends StatelessWidget {
children:
[
Container
(
width:
double
.
infinity
,
child:
Image
.
asset
(
'assets/images/read_bg.png'
,
fit:
BoxFit
.
cover
,)
child:
Image
.
asset
(
'assets/images/read_bg.png'
,
fit:
BoxFit
.
contain
,
width:
double
.
infinity
,
// height: 96,
)
),
Container
(
padding:
const
EdgeInsets
.
symmetric
(
vertical:
16.5
),
Positioned
(
// top: 10.w,
left:
0
,
right:
0
,
child:
Container
(
padding:
EdgeInsets
.
symmetric
(
vertical:
16.5
.
w
),
color:
Colors
.
transparent
,
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(8),
...
...
@@ -52,14 +60,15 @@ class BuildRead extends StatelessWidget {
},
child:
Column
(
children:
[
Text
(
model
.
value
,
style:
const
TextStyle
(
fontSize:
18
,
height:
1.6
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),),
Text
(
model
.
value
,
style:
TextStyle
(
fontSize:
18
.
w
,
height:
1.6
.
w
,
fontWeight:
Fonts
.
medium
,
color:
Colours
.
c3
),),
Gaps
.
vGaps5
,
Text
(
model
.
name
,
style:
const
TextStyle
(
fontSize:
13
,
height:
1.6
,
color:
Colours
.
c6
))
Text
(
model
.
name
,
style:
TextStyle
(
fontSize:
13
.
w
,
height:
1.6
.
w
,
color:
Colours
.
c6
))
],
),
);
}).
toList
(),
),
),
)
],
),
...
...
lib/pages/mine/widgets/user.dart
浏览文件 @
ed335851
...
...
@@ -18,7 +18,7 @@ class BuildUser extends StatelessWidget {
behavior:
HitTestBehavior
.
opaque
,
onTap:
onTap
,
child:
Container
(
margin:
const
EdgeInsets
.
only
(
left:
10
,
right:
10
),
margin:
EdgeInsets
.
only
(
left:
10
.
w
,
right:
10
.
w
),
color:
Colors
.
transparent
,
child:
Row
(
mainAxisAlignment:
MainAxisAlignment
.
spaceBetween
,
...
...
@@ -29,11 +29,11 @@ class BuildUser extends StatelessWidget {
width:
45
.
w
,
height:
45
.
w
,
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
22.5
),
borderRadius:
BorderRadius
.
circular
(
22.5
.
w
),
color:
Colors
.
cyan
,
),
// color: Colors.cyan,
child:
CustomImage
.
network
(
url:
userInfo
.
headImg
??
''
,
radius:
22.5
,),
child:
CustomImage
.
network
(
url:
userInfo
.
headImg
??
''
,
radius:
22.5
.
w
,),
),
Gaps
.
hGaps10
,
Column
(
...
...
@@ -52,10 +52,10 @@ class BuildUser extends StatelessWidget {
Stack
(
children:
[
Container
(
padding:
const
EdgeInsets
.
only
(
right:
8
,
left:
8
),
height:
20
,
padding:
EdgeInsets
.
only
(
right:
8
.
w
,
left:
8
.
w
),
height:
20
.
w
,
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
21
),
borderRadius:
BorderRadius
.
circular
(
21
.
w
),
gradient:
LinearGradient
(
colors:
[
AppTheme
.
primary
.
withOpacity
(
0.03
),
AppTheme
.
primary
.
withOpacity
(
0.1
)]
,
// 不可点击时的颜色,透明度为0.7
begin:
Alignment
.
centerLeft
,
...
...
@@ -64,18 +64,18 @@ class BuildUser extends StatelessWidget {
),
child:
Row
(
children:
[
const
SizedBox
(
width:
16
,
height:
17
,
SizedBox
(
width:
16
.
w
,
height:
17
.
w
,
),
Text
(
userInfo
.
gradeName
??
''
,
style:
const
TextStyle
(
fontSize:
11
,
color:
AppTheme
.
primary
),)
Text
(
userInfo
.
gradeName
??
''
,
style:
TextStyle
(
fontSize:
11
.
w
,
color:
AppTheme
.
primary
),)
],
),
),
Positioned
(
left:
8
,
child:
SizedBox
(
width:
16
,
height:
17
,
width:
16
.
w
,
height:
17
.
w
,
child:
Image
.
asset
(
'assets/images/grade.png'
)
),
)
...
...
@@ -94,8 +94,8 @@ class BuildUser extends StatelessWidget {
],
),
SizedBox
(
width:
5
,
height:
9
,
width:
5
.
w
,
height:
9
.
w
,
child:
Image
.
asset
(
'assets/images/right_arrow.png'
),
)
],
...
...
lib/pages/search/view.dart
浏览文件 @
ed335851
...
...
@@ -17,7 +17,7 @@ class _SearchPageState extends State<SearchPage> {
automaticallyImplyLeading:
false
,
titleSpacing:
0
,
title:
Padding
(
padding:
const
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
padding:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
child:
CustomInputSearch
(
controller:
controller
.
searchController
,
readOnly:
false
,
...
...
lib/pages/study_report/index.dart
浏览文件 @
ed335851
...
...
@@ -2,6 +2,7 @@ library study_report;
import
'package:flutter/material.dart'
;
import
'package:flutter_book/utils/index.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
part
'view.dart'
;
part
'widgets/card.dart'
;
\ No newline at end of file
lib/pages/study_report/widgets/card.dart
浏览文件 @
ed335851
...
...
@@ -23,31 +23,31 @@ class BuildCard extends StatelessWidget {
crossAxisAlignment:
CrossAxisAlignment
.
end
,
children:
[
Expanded
(
child:
const
Column
(
child:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
start
,
crossAxisAlignment:
CrossAxisAlignment
.
start
,
children:
[
Text
(
'恰如其分的孤独'
,
style:
TextStyle
(
fontSize:
20
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),),
Text
(
'恰如其分的孤独'
,
style:
TextStyle
(
fontSize:
20
.
w
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),),
Gaps
.
vGaps15
,
Row
(
children:
[
Text
(
'学习总进度'
,
style:
TextStyle
(
fontSize:
13
,
height:
1.4
,
color:
Colors
.
white
),),
Text
(
'学习总进度'
,
style:
TextStyle
(
fontSize:
13
.
w
,
height:
1.4
,
color:
Colors
.
white
),),
Gaps
.
hGaps15
,
Text
(
'4.98%'
,
style:
TextStyle
(
fontSize:
16
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),),
Text
(
'4.98%'
,
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),),
]
),
Gaps
.
vGaps10
,
Row
(
children:
[
Text
(
'学习总时长'
,
style:
TextStyle
(
fontSize:
13
,
height:
1.4
,
color:
Colors
.
white
),),
Text
(
'学习总时长'
,
style:
TextStyle
(
fontSize:
13
.
w
,
height:
1.4
,
color:
Colors
.
white
),),
Gaps
.
hGaps15
,
Text
(
'30分钟'
,
style:
TextStyle
(
fontSize:
16
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),),
Text
(
'30分钟'
,
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),),
]
),
Gaps
.
vGaps10
,
Text
(
'上次读到'
,
style:
TextStyle
(
fontSize:
13
,
height:
1.4
,
color:
Colors
.
white
),),
Text
(
'上次读到'
,
style:
TextStyle
(
fontSize:
13
.
w
,
height:
1.4
,
color:
Colors
.
white
),),
Gaps
.
vGaps5
,
Text
(
'第3章 情节…情节…情节情节情节情节'
,
style:
TextStyle
(
fontSize:
16
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),
maxLines:
1
,
overflow:
TextOverflow
.
ellipsis
,),
Text
(
'第3章 情节…情节…情节情节情节情节'
,
style:
TextStyle
(
fontSize:
16
.
w
,
height:
1.4
,
color:
Colors
.
white
,
fontWeight:
Fonts
.
medium
),
maxLines:
1
,
overflow:
TextOverflow
.
ellipsis
,),
]
),
),
...
...
lib/pages/user_coupon/widgets/item.dart
浏览文件 @
ed335851
...
...
@@ -16,7 +16,11 @@ class BuildItem extends StatelessWidget {
child:
Stack
(
children:
[
Container
(
child:
Image
.
asset
(
'assets/images/coupon_bg.png'
)
,
child:
Image
.
asset
(
'assets/images/coupon_bg.png'
,
fit:
BoxFit
.
contain
,
width:
double
.
infinity
,
)
,
),
Container
(
height:
105
,
...
...
lib/pages/user_gender/view.dart
浏览文件 @
ed335851
...
...
@@ -33,7 +33,7 @@ class _UserGenderPageState extends State<UserGenderPage> {
actions:
[],
),
body:
Container
(
margin:
const
EdgeInsets
.
symmetric
(
margin:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
,
vertical:
AppTheme
.
margin
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
8
),
...
...
lib/pages/user_info/view.dart
浏览文件 @
ed335851
...
...
@@ -21,7 +21,7 @@ class _UserInfoPageState extends State<UserInfoPage> {
centerTitle:
true
,
),
body:
Container
(
margin:
const
EdgeInsets
.
symmetric
(
margin:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
,
vertical:
AppTheme
.
margin
),
decoration:
BoxDecoration
(
borderRadius:
BorderRadius
.
circular
(
8
),
...
...
lib/pages/user_nick/view.dart
浏览文件 @
ed335851
...
...
@@ -51,7 +51,7 @@ class _UserNickPageState extends State<UserNickPage> {
],
),
body:
Container
(
margin:
const
EdgeInsets
.
only
(
left:
AppTheme
.
margin
,
right:
AppTheme
.
margin
,
top:
AppTheme
.
margin
),
margin:
EdgeInsets
.
only
(
left:
AppTheme
.
margin
,
right:
AppTheme
.
margin
,
top:
AppTheme
.
margin
),
height:
42
,
decoration:
BoxDecoration
(
boxShadow:
[
BoxShadow
(
...
...
lib/pages/user_set/view.dart
浏览文件 @
ed335851
...
...
@@ -116,7 +116,7 @@ class _UserSetPageState extends State<UserSetPage> {
),
],
),
margin:
const
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
margin:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
child:
const
Text
(
'退出登录'
,
style:
TextStyle
(
fontSize:
14
,
color:
Colours
.
c3
),),
),
)
...
...
lib/theme.dart
浏览文件 @
ed335851
...
...
@@ -7,7 +7,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
abstract
class
AppTheme
{
// 应用程序默认边距
static
const
margin
=
10.0
;
static
final
margin
=
10.0
.
w
;
// 主要/主题颜色的常量
static
const
primary
=
Color
(
0xFFAB1941
);
...
...
lib/utils/index.dart
浏览文件 @
ed335851
...
...
@@ -7,6 +7,7 @@ import 'dart:ui';
import
'package:flutter/cupertino.dart'
;
import
'package:flutter/foundation.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter_screenutil/flutter_screenutil.dart'
;
import
'package:image_picker/image_picker.dart'
;
import
'package:intl/intl.dart'
;
import
'package:logger/logger.dart'
;
...
...
lib/utils/styles.dart
浏览文件 @
ed335851
...
...
@@ -39,18 +39,18 @@ class Colours {
}
class
Gaps
{
static
const
Widget
hGaps5
=
SizedBox
(
width:
5
,);
static
const
Widget
hGaps10
=
SizedBox
(
width:
10
,);
static
const
Widget
hGaps15
=
SizedBox
(
width:
15
,);
static
const
Widget
hGaps20
=
SizedBox
(
width:
20
,);
static
const
Widget
vGaps5
=
SizedBox
(
height:
5
,);
static
const
Widget
vGaps8
=
SizedBox
(
height:
8
,);
static
const
Widget
vGaps10
=
SizedBox
(
height:
10
,);
static
const
Widget
vGaps13
=
SizedBox
(
height:
13
,);
static
const
Widget
vGaps15
=
SizedBox
(
height:
15
,);
static
const
Widget
vGaps25
=
SizedBox
(
height:
25
,);
static
const
Widget
vGaps40
=
SizedBox
(
height:
40
,);
static
Widget
hGaps5
=
SizedBox
(
width:
5
.
w
,);
static
Widget
hGaps10
=
SizedBox
(
width:
10
.
w
,);
static
Widget
hGaps15
=
SizedBox
(
width:
15
.
w
,);
static
Widget
hGaps20
=
SizedBox
(
width:
20
.
w
,);
static
Widget
vGaps5
=
SizedBox
(
height:
5
.
w
,);
static
Widget
vGaps8
=
SizedBox
(
height:
8
.
w
,);
static
Widget
vGaps10
=
SizedBox
(
height:
10
.
w
,);
static
Widget
vGaps13
=
SizedBox
(
height:
13
.
w
,);
static
Widget
vGaps15
=
SizedBox
(
height:
15
.
w
,);
static
Widget
vGaps25
=
SizedBox
(
height:
25
.
w
,);
static
Widget
vGaps40
=
SizedBox
(
height:
40
.
w
,);
// static const Widget line = Padding(
// padding: EdgeInsets.symmetric(horizontal: 15.0),
// child: Divider(color: Colours.cLine,),
...
...
lib/widgets/app_bar.dart
浏览文件 @
ed335851
...
...
@@ -27,7 +27,7 @@ class CustomAppBar extends AppBar {
for
(
var
element
in
items
!)
{
ws
.
add
(
Container
(
alignment:
Alignment
.
center
,
padding:
const
EdgeInsets
.
only
(
right:
AppTheme
.
margin
),
padding:
EdgeInsets
.
only
(
right:
AppTheme
.
margin
),
child:
element
,
));
}
...
...
lib/widgets/dialog.dart
浏览文件 @
ed335851
...
...
@@ -88,7 +88,7 @@ class CustomDialog extends StatelessWidget {
children:
[
if
(
title
!=
null
)
Padding
(
padding:
const
EdgeInsets
.
all
(
AppTheme
.
margin
),
padding:
EdgeInsets
.
all
(
AppTheme
.
margin
),
child:
DefaultTextStyle
.
merge
(
textAlign:
TextAlign
.
center
,
style:
DialogTheme
.
of
(
context
).
titleTextStyle
,
...
...
@@ -100,7 +100,7 @@ class CustomDialog extends StatelessWidget {
fit:
FlexFit
.
loose
,
child:
SingleChildScrollView
(
physics:
const
ClampingScrollPhysics
(),
padding:
const
EdgeInsets
.
all
(
AppTheme
.
margin
).
copyWith
(
padding:
EdgeInsets
.
all
(
AppTheme
.
margin
).
copyWith
(
top:
title
!=
null
?
0
:
null
,
bottom:
buttonGroup
.
isNotEmpty
?
0
:
null
,
),
...
...
@@ -119,7 +119,7 @@ class CustomDialog extends StatelessWidget {
),
if
(
buttonGroup
.
isNotEmpty
)
Padding
(
padding:
const
EdgeInsets
.
all
(
AppTheme
.
margin
),
padding:
EdgeInsets
.
all
(
AppTheme
.
margin
),
child:
Row
(
children:
buttonGroup
),
),
],
...
...
lib/widgets/tab_bar.dart
浏览文件 @
ed335851
...
...
@@ -185,7 +185,7 @@ class _CustomTabBarState extends State<CustomTabBar>
Widget
tabsChild
=
SafeArea
(
top:
false
,
bottom:
false
,
minimum:
const
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
minimum:
EdgeInsets
.
symmetric
(
horizontal:
AppTheme
.
margin
),
child:
Row
(
mainAxisSize:
MainAxisSize
.
min
,
children:
List
.
generate
(
widget
.
tabs
.
length
,
(
index
)
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论