Showing
11 changed files
with
112 additions
and
160 deletions
| ... | @@ -43,7 +43,22 @@ class _CategoriesPageState extends State<CategoriesPage> | ... | @@ -43,7 +43,22 @@ class _CategoriesPageState extends State<CategoriesPage> |
| 43 | return ChangeNotifierProvider<CategoriesPageProvider>( | 43 | return ChangeNotifierProvider<CategoriesPageProvider>( |
| 44 | create: (_) => provider, | 44 | create: (_) => provider, |
| 45 | child: Scaffold( | 45 | child: Scaffold( |
| 46 | - appBar: MyAppBar( | 46 | + appBar: MyAppBar( |
| 47 | + homeMenuHeader: Container( | ||
| 48 | + alignment: Alignment.center, | ||
| 49 | + margin: const EdgeInsets.symmetric(horizontal: 5.0), | ||
| 50 | + child: const Text( | ||
| 51 | + "众妙", | ||
| 52 | + style: TextStyle(color: Colors.white), | ||
| 53 | + ), | ||
| 54 | + ), | ||
| 55 | + homeActionWidgets: IconButton( | ||
| 56 | + icon: const Icon( | ||
| 57 | + Icons.search, | ||
| 58 | + color: Colors.white, | ||
| 59 | + ), | ||
| 60 | + onPressed: () {}, | ||
| 61 | + ), | ||
| 47 | ), | 62 | ), |
| 48 | body: Column( | 63 | body: Column( |
| 49 | key: _bodyKey, | 64 | key: _bodyKey, | ... | ... |
| ... | @@ -22,7 +22,7 @@ class CategoryListPage extends StatefulWidget { | ... | @@ -22,7 +22,7 @@ class CategoryListPage extends StatefulWidget { |
| 22 | 22 | ||
| 23 | class _CategoryListPageState extends State<CategoryListPage> with AutomaticKeepAliveClientMixin<CategoryListPage>, SingleTickerProviderStateMixin { | 23 | class _CategoryListPageState extends State<CategoryListPage> with AutomaticKeepAliveClientMixin<CategoryListPage>, SingleTickerProviderStateMixin { |
| 24 | 24 | ||
| 25 | - int _selectIndex = -1; | 25 | + final int _selectIndex = -1; |
| 26 | late Animation<double> _animation; | 26 | late Animation<double> _animation; |
| 27 | late AnimationController _controller; | 27 | late AnimationController _controller; |
| 28 | List<CategoryItemEntity> _list = []; | 28 | List<CategoryItemEntity> _list = []; |
| ... | @@ -105,45 +105,10 @@ class _CategoryListPageState extends State<CategoryListPage> with AutomaticKeepA | ... | @@ -105,45 +105,10 @@ class _CategoryListPageState extends State<CategoryListPage> with AutomaticKeepA |
| 105 | loadMore: _loadMore, | 105 | loadMore: _loadMore, |
| 106 | hasMore: _page < _maxPage, | 106 | hasMore: _page < _maxPage, |
| 107 | itemBuilder: (_, index) { | 107 | itemBuilder: (_, index) { |
| 108 | - final String heroTag = 'goodsImg${widget.index}-$index'; | ||
| 109 | return CategoryItem( | 108 | return CategoryItem( |
| 110 | index: index, | 109 | index: index, |
| 111 | - heroTag: heroTag, | ||
| 112 | selectIndex: _selectIndex, | 110 | selectIndex: _selectIndex, |
| 113 | item: _list[index], | 111 | item: _list[index], |
| 114 | - animation: _animation, | ||
| 115 | - onTapMenu: () { | ||
| 116 | - /// 点击其他item时,重置状态 | ||
| 117 | - if (_selectIndex != index) { | ||
| 118 | - _animationStatus = AnimationStatus.dismissed; | ||
| 119 | - } | ||
| 120 | - /// 避免动画中重复执行 | ||
| 121 | - if (_animationStatus == AnimationStatus.dismissed) { | ||
| 122 | - // 开始执行动画 | ||
| 123 | - _controller.forward(from: 0.0); | ||
| 124 | - } | ||
| 125 | - setState(() { | ||
| 126 | - _selectIndex = index; | ||
| 127 | - }); | ||
| 128 | - }, | ||
| 129 | - onTapMenuClose: () { | ||
| 130 | - if (_animationStatus == AnimationStatus.completed) { | ||
| 131 | - _controller.reverse(from: 1.1); | ||
| 132 | - } | ||
| 133 | - _selectIndex = -1; | ||
| 134 | - }, | ||
| 135 | - onTapEdit: () { | ||
| 136 | - setState(() { | ||
| 137 | - _selectIndex = -1; | ||
| 138 | - }); | ||
| 139 | - }, | ||
| 140 | - onTapOperation: () { | ||
| 141 | - | ||
| 142 | - }, | ||
| 143 | - onTapDelete: () { | ||
| 144 | - _controller.reverse(from: 1.1); | ||
| 145 | - _selectIndex = -1; | ||
| 146 | - }, | ||
| 147 | ); | 112 | ); |
| 148 | } | 113 | } |
| 149 | ); | 114 | ); | ... | ... |
| 1 | -import 'package:common_utils/common_utils.dart'; | 1 | +import 'dart:ui'; |
| 2 | + | ||
| 2 | import 'package:flutter/cupertino.dart'; | 3 | import 'package:flutter/cupertino.dart'; |
| 3 | import 'package:flutter/material.dart'; | 4 | import 'package:flutter/material.dart'; |
| 4 | import 'package:one_poem/category/models/category_item_entity.dart'; | 5 | import 'package:one_poem/category/models/category_item_entity.dart'; |
| 6 | +import 'package:one_poem/poem/poem_router.dart'; | ||
| 5 | import 'package:one_poem/res/gaps.dart'; | 7 | import 'package:one_poem/res/gaps.dart'; |
| 6 | import 'package:one_poem/res/resources.dart'; | 8 | import 'package:one_poem/res/resources.dart'; |
| 7 | -import 'package:one_poem/util/device_utils.dart'; | 9 | +import 'package:one_poem/routers/fluro_navigator.dart'; |
| 8 | -import 'package:one_poem/util/other_utils.dart'; | 10 | +import 'package:one_poem/setting/setting_router.dart'; |
| 9 | -import 'package:one_poem/widgets/load_image.dart'; | ||
| 10 | 11 | ||
| 11 | class CategoryItem extends StatelessWidget { | 12 | class CategoryItem extends StatelessWidget { |
| 12 | const CategoryItem({ | 13 | const CategoryItem({ |
| ... | @@ -14,117 +15,84 @@ class CategoryItem extends StatelessWidget { | ... | @@ -14,117 +15,84 @@ class CategoryItem extends StatelessWidget { |
| 14 | required this.item, | 15 | required this.item, |
| 15 | required this.index, | 16 | required this.index, |
| 16 | required this.selectIndex, | 17 | required this.selectIndex, |
| 17 | - required this.onTapMenu, | ||
| 18 | - required this.onTapEdit, | ||
| 19 | - required this.onTapOperation, | ||
| 20 | - required this.onTapDelete, | ||
| 21 | - required this.onTapMenuClose, | ||
| 22 | - required this.animation, | ||
| 23 | - required this.heroTag, | ||
| 24 | }) : super(key: key); | 18 | }) : super(key: key); |
| 25 | 19 | ||
| 26 | final CategoryItemEntity item; | 20 | final CategoryItemEntity item; |
| 27 | final int index; | 21 | final int index; |
| 28 | final int selectIndex; | 22 | final int selectIndex; |
| 29 | - final VoidCallback onTapMenu; | ||
| 30 | - final VoidCallback onTapEdit; | ||
| 31 | - final VoidCallback onTapOperation; | ||
| 32 | - final VoidCallback onTapDelete; | ||
| 33 | - final VoidCallback onTapMenuClose; | ||
| 34 | - final Animation<double> animation; | ||
| 35 | - final String heroTag; | ||
| 36 | 23 | ||
| 37 | @override | 24 | @override |
| 38 | Widget build(BuildContext context) { | 25 | Widget build(BuildContext context) { |
| 39 | - return Padding( | 26 | + return InkWell( |
| 40 | - padding: const EdgeInsets.only(left: 10.0, top: 10.0, right: 10.0), | 27 | + onTap: () { |
| 41 | - child: DecoratedBox( | 28 | + NavigatorUtils.push(context, '${PoemRouter.poemDetailPage}?id=100'); |
| 29 | + }, | ||
| 30 | + child: Container( | ||
| 31 | + margin: const EdgeInsets.symmetric(vertical: 5.0, horizontal: 10.0), | ||
| 32 | + width: double.infinity, | ||
| 42 | decoration: BoxDecoration( | 33 | decoration: BoxDecoration( |
| 43 | - image: const DecorationImage( | 34 | + color: Colors.grey.shade200.withOpacity(0.1), |
| 44 | - image: AssetImage("assets/images/category/category_item_bg.png"), | ||
| 45 | - fit: BoxFit.fill, | ||
| 46 | - ), | ||
| 47 | border: Border.all(color: Colors.grey, width: 0.5), // 边色与边宽度 | 35 | border: Border.all(color: Colors.grey, width: 0.5), // 边色与边宽度 |
| 48 | - borderRadius: BorderRadius.circular(2.0), | ||
| 49 | ), | 36 | ), |
| 50 | - child: Padding( | 37 | + child: ClipRect( |
| 51 | - padding: const EdgeInsets.all(10.0), | 38 | + child: BackdropFilter( |
| 52 | - child: Column( | 39 | + filter: ImageFilter.blur( |
| 53 | - crossAxisAlignment: CrossAxisAlignment.center, | 40 | + sigmaX: 10.0, |
| 54 | - children: <Widget>[ | 41 | + sigmaY: 10.0, |
| 55 | - Row( | 42 | + ), |
| 56 | - mainAxisAlignment: MainAxisAlignment.spaceBetween, | 43 | + child: Container( |
| 57 | - mainAxisSize: MainAxisSize.max, | 44 | + decoration: BoxDecoration( |
| 58 | - //交叉轴的布局方式,对于column来说就是水平方向的布局方式 | 45 | + color: Colors.grey.shade200.withOpacity(0.1), |
| 59 | - crossAxisAlignment: CrossAxisAlignment.center, | ||
| 60 | - children: <Widget>[ | ||
| 61 | - const Text("此地"), | ||
| 62 | - // Icon( | ||
| 63 | - // Icons.query_builder_outlined, | ||
| 64 | - // size: 15.0, | ||
| 65 | - // ), | ||
| 66 | - Wrap( | ||
| 67 | - crossAxisAlignment: WrapCrossAlignment.center, | ||
| 68 | - children: const [ | ||
| 69 | - Icon( | ||
| 70 | - Icons.room_outlined, | ||
| 71 | - size: 15.0, | ||
| 72 | - ), | ||
| 73 | - Text( | ||
| 74 | - "北京 海淀 万泉庄", | ||
| 75 | - maxLines: 3, | ||
| 76 | - ), | ||
| 77 | - ], | ||
| 78 | - ), | ||
| 79 | - const Text("京", style: TextStyle(fontSize: 30)), | ||
| 80 | - ], | ||
| 81 | ), | 46 | ), |
| 82 | - Gaps.vGap16, | 47 | + child: Padding( |
| 83 | - const Text( | 48 | + padding: const EdgeInsets.all(10.0), |
| 84 | - "前不见古人,后不见来者。\n念天地之悠悠,独怆然而涕下。\n", | 49 | + child: Column( |
| 85 | - style: TextStyle(fontSize: 22.0, fontFamily: "ZCOOLXiaoWei"), | 50 | + crossAxisAlignment: CrossAxisAlignment.center, |
| 51 | + children: <Widget>[ | ||
| 52 | + Row( | ||
| 53 | + mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
| 54 | + mainAxisSize: MainAxisSize.max, | ||
| 55 | + //交叉轴的布局方式,对于column来说就是水平方向的布局方式 | ||
| 56 | + crossAxisAlignment: CrossAxisAlignment.center, | ||
| 57 | + children: <Widget>[ | ||
| 58 | + const Text("此地"), | ||
| 59 | + // Icon( | ||
| 60 | + // Icons.query_builder_outlined, | ||
| 61 | + // size: 15.0, | ||
| 62 | + // ), | ||
| 63 | + Wrap( | ||
| 64 | + crossAxisAlignment: WrapCrossAlignment.center, | ||
| 65 | + children: const [ | ||
| 66 | + Icon( | ||
| 67 | + Icons.room_outlined, | ||
| 68 | + size: 15.0, | ||
| 69 | + ), | ||
| 70 | + Text( | ||
| 71 | + "北京 海淀 万泉庄", | ||
| 72 | + maxLines: 3, | ||
| 73 | + ), | ||
| 74 | + ], | ||
| 75 | + ), | ||
| 76 | + const Text("京", style: TextStyle(fontSize: 30)), | ||
| 77 | + ], | ||
| 78 | + ), | ||
| 79 | + Gaps.vGap16, | ||
| 80 | + const Text( | ||
| 81 | + "前不见古人,后不见来者。\n念天地之悠悠,独怆然而涕下。\n", | ||
| 82 | + style: | ||
| 83 | + TextStyle(fontSize: 22.0, fontFamily: "ZCOOLXiaoWei"), | ||
| 84 | + ), | ||
| 85 | + const Text( | ||
| 86 | + "[唐] 陈子昂《登幽州台歌》", | ||
| 87 | + maxLines: 1, | ||
| 88 | + ), | ||
| 89 | + ], | ||
| 90 | + ), | ||
| 86 | ), | 91 | ), |
| 87 | - const Text( | 92 | + ), |
| 88 | - "[唐] 陈子昂《登幽州台歌》", | ||
| 89 | - maxLines: 1, | ||
| 90 | - ), | ||
| 91 | - ], | ||
| 92 | ), | 93 | ), |
| 93 | ), | 94 | ), |
| 94 | ), | 95 | ), |
| 95 | ); | 96 | ); |
| 96 | } | 97 | } |
| 97 | } | 98 | } |
| 98 | - | ||
| 99 | -class _GoodsItemTag extends StatelessWidget { | ||
| 100 | - const _GoodsItemTag({ | ||
| 101 | - Key? key, | ||
| 102 | - required this.color, | ||
| 103 | - required this.text, | ||
| 104 | - }) : super(key: key); | ||
| 105 | - | ||
| 106 | - final Color? color; | ||
| 107 | - final String text; | ||
| 108 | - | ||
| 109 | - @override | ||
| 110 | - Widget build(BuildContext context) { | ||
| 111 | - return Container( | ||
| 112 | - padding: const EdgeInsets.symmetric(horizontal: 4.0), | ||
| 113 | - margin: const EdgeInsets.only(right: 4.0), | ||
| 114 | - decoration: BoxDecoration( | ||
| 115 | - color: color, | ||
| 116 | - borderRadius: BorderRadius.circular(2.0), | ||
| 117 | - ), | ||
| 118 | - height: 16.0, | ||
| 119 | - alignment: Alignment.center, | ||
| 120 | - child: Text( | ||
| 121 | - text, | ||
| 122 | - style: TextStyle( | ||
| 123 | - color: Colors.white, | ||
| 124 | - fontSize: Dimens.font_sp10, | ||
| 125 | - height: Device.isAndroid ? 1.1 : null, | ||
| 126 | - ), | ||
| 127 | - ), | ||
| 128 | - ); | ||
| 129 | - } | ||
| 130 | -} | ... | ... |
| ... | @@ -146,7 +146,7 @@ class MyApp extends StatelessWidget { | ... | @@ -146,7 +146,7 @@ class MyApp extends StatelessWidget { |
| 146 | Widget _buildMaterialApp( | 146 | Widget _buildMaterialApp( |
| 147 | ThemeProvider provider, LocaleProvider localeProvider) { | 147 | ThemeProvider provider, LocaleProvider localeProvider) { |
| 148 | return MaterialApp( | 148 | return MaterialApp( |
| 149 | - title: 'Flutter Deer', | 149 | + title: '一言', |
| 150 | // showPerformanceOverlay: true, //显示性能标签 | 150 | // showPerformanceOverlay: true, //显示性能标签 |
| 151 | // debugShowCheckedModeBanner: false, // 去除右上角debug的标签 | 151 | // debugShowCheckedModeBanner: false, // 去除右上角debug的标签 |
| 152 | // checkerboardRasterCacheImages: true, | 152 | // checkerboardRasterCacheImages: true, | ... | ... |
| ... | @@ -3,11 +3,8 @@ import 'dart:ui'; | ... | @@ -3,11 +3,8 @@ import 'dart:ui'; |
| 3 | import 'package:flutter/cupertino.dart'; | 3 | import 'package:flutter/cupertino.dart'; |
| 4 | import 'package:flutter/material.dart'; | 4 | import 'package:flutter/material.dart'; |
| 5 | import 'package:one_poem/res/gaps.dart'; | 5 | import 'package:one_poem/res/gaps.dart'; |
| 6 | -import 'package:one_poem/util/theme_utils.dart'; | ||
| 7 | -import 'package:one_poem/util/toast_utils.dart'; | ||
| 8 | import 'package:one_poem/widgets/bars/home_action_bar.dart'; | 6 | import 'package:one_poem/widgets/bars/home_action_bar.dart'; |
| 9 | -import 'package:one_poem/widgets/bars/home_title_bar.dart'; | 7 | +import 'package:one_poem/widgets/bars/home_menu_bar.dart'; |
| 10 | -import 'package:one_poem/widgets/load_image.dart'; | ||
| 11 | import 'package:one_poem/widgets/my_app_bar.dart'; | 8 | import 'package:one_poem/widgets/my_app_bar.dart'; |
| 12 | 9 | ||
| 13 | class PoemDetailPage extends StatefulWidget { | 10 | class PoemDetailPage extends StatefulWidget { |
| ... | @@ -29,10 +26,11 @@ class _PoemDetailPageState extends State<PoemDetailPage> { | ... | @@ -29,10 +26,11 @@ class _PoemDetailPageState extends State<PoemDetailPage> { |
| 29 | Widget build(BuildContext context) { | 26 | Widget build(BuildContext context) { |
| 30 | return Scaffold( | 27 | return Scaffold( |
| 31 | appBar: MyAppBar( | 28 | appBar: MyAppBar( |
| 29 | + isBack: true, | ||
| 32 | isTransparent: false, | 30 | isTransparent: false, |
| 33 | - homeTitleHeader: HomeTitleHeader( | 31 | + homeMenuHeader: HomeMenuHeader( |
| 34 | funcLeft: () { | 32 | funcLeft: () { |
| 35 | - print("lefltlelfle"); | 33 | + print("lefltlelfle poem id=" + widget.poemId.toString()); |
| 36 | }, | 34 | }, |
| 37 | ), | 35 | ), |
| 38 | homeActionWidgets: HomeActionWidgets( | 36 | homeActionWidgets: HomeActionWidgets( |
| ... | @@ -60,8 +58,8 @@ class _PoemDetailPageState extends State<PoemDetailPage> { | ... | @@ -60,8 +58,8 @@ class _PoemDetailPageState extends State<PoemDetailPage> { |
| 60 | width: double.infinity, | 58 | width: double.infinity, |
| 61 | decoration: BoxDecoration( | 59 | decoration: BoxDecoration( |
| 62 | color: Colors.grey.shade200.withOpacity(0.1), | 60 | color: Colors.grey.shade200.withOpacity(0.1), |
| 63 | - border: Border.all(color: Colors.grey, width: 0.1), // 边色与边宽度 | 61 | + border: Border.all(color: Colors.grey.shade50, width: 0.5), // 边色与边宽度 |
| 64 | - borderRadius: BorderRadius.circular(2.0), | 62 | + // borderRadius: BorderRadius.circular(2.0), |
| 65 | ), | 63 | ), |
| 66 | child: ClipRect( | 64 | child: ClipRect( |
| 67 | child: BackdropFilter( | 65 | child: BackdropFilter( | ... | ... |
| 1 | import 'package:fluro/fluro.dart'; | 1 | import 'package:fluro/fluro.dart'; |
| 2 | import 'package:one_poem/routers/i_router.dart'; | 2 | import 'package:one_poem/routers/i_router.dart'; |
| 3 | 3 | ||
| 4 | +import 'page/poem_detail.dart'; | ||
| 4 | import 'page/poem_page.dart'; | 5 | import 'page/poem_page.dart'; |
| 5 | 6 | ||
| 6 | -class PoemRouter implements IRouterProvider{ | 7 | +class PoemRouter implements IRouterProvider { |
| 7 | - | ||
| 8 | static String poemPage = '/poem'; | 8 | static String poemPage = '/poem'; |
| 9 | + static String poemDetailPage = '/detail'; | ||
| 9 | 10 | ||
| 10 | @override | 11 | @override |
| 11 | void initRouter(FluroRouter router) { | 12 | void initRouter(FluroRouter router) { |
| 12 | - router.define(poemPage, handler: Handler(handlerFunc: (_, __) => const PoemPage())); | 13 | + router.define(poemPage, |
| 14 | + handler: Handler(handlerFunc: (_, __) => const PoemPage())); | ||
| 15 | + router.define(poemDetailPage, | ||
| 16 | + handler: Handler(handlerFunc: (_, Map<String, List<String>> params) { | ||
| 17 | + String? id = params['id']?.first; | ||
| 18 | + return PoemDetailPage( | ||
| 19 | + poemId: int.parse(id!), | ||
| 20 | + ); | ||
| 21 | + })); | ||
| 13 | } | 22 | } |
| 14 | - | ||
| 15 | } | 23 | } | ... | ... |
| 1 | import 'dart:ui'; | 1 | import 'dart:ui'; |
| 2 | 2 | ||
| 3 | import 'package:flutter/material.dart'; | 3 | import 'package:flutter/material.dart'; |
| 4 | -import 'package:one_poem/res/resources.dart'; | ||
| 5 | -import 'package:one_poem/tiktok/style/style.dart'; | ||
| 6 | 4 | ||
| 7 | class TikTokTopInfoColumn extends StatelessWidget { | 5 | class TikTokTopInfoColumn extends StatelessWidget { |
| 8 | final double? bottomPadding; | 6 | final double? bottomPadding; |
| ... | @@ -23,7 +21,7 @@ class TikTokTopInfoColumn extends StatelessWidget { | ... | @@ -23,7 +21,7 @@ class TikTokTopInfoColumn extends StatelessWidget { |
| 23 | decoration: BoxDecoration( | 21 | decoration: BoxDecoration( |
| 24 | color: Colors.grey.shade200.withOpacity(0.1), | 22 | color: Colors.grey.shade200.withOpacity(0.1), |
| 25 | border: Border.all(color: Colors.grey, width: 0.1), // 边色与边宽度 | 23 | border: Border.all(color: Colors.grey, width: 0.1), // 边色与边宽度 |
| 26 | - borderRadius: BorderRadius.circular(2.0), | 24 | + // borderRadius: BorderRadius.circular(2.0), |
| 27 | ), | 25 | ), |
| 28 | child: ClipRect( | 26 | child: ClipRect( |
| 29 | child: BackdropFilter( | 27 | child: BackdropFilter( | ... | ... |
| ... | @@ -25,7 +25,7 @@ class TikTokVidePoem extends StatelessWidget { | ... | @@ -25,7 +25,7 @@ class TikTokVidePoem extends StatelessWidget { |
| 25 | decoration: BoxDecoration( | 25 | decoration: BoxDecoration( |
| 26 | color: Colors.grey.shade200.withOpacity(0.1), | 26 | color: Colors.grey.shade200.withOpacity(0.1), |
| 27 | border: Border.all(color: Colors.grey, width: 0.1), // 边色与边宽度 | 27 | border: Border.all(color: Colors.grey, width: 0.1), // 边色与边宽度 |
| 28 | - borderRadius: BorderRadius.circular(2.0), | 28 | + // borderRadius: BorderRadius.circular(2.0), |
| 29 | ), | 29 | ), |
| 30 | height: 220.0, | 30 | height: 220.0, |
| 31 | width: double.infinity, | 31 | width: double.infinity, | ... | ... |
| 1 | import 'package:flutter/material.dart'; | 1 | import 'package:flutter/material.dart'; |
| 2 | 2 | ||
| 3 | -class HomeTitleHeader extends StatelessWidget { | 3 | +class HomeMenuHeader extends StatelessWidget { |
| 4 | - const HomeTitleHeader({ | 4 | + const HomeMenuHeader({ |
| 5 | Key? key, | 5 | Key? key, |
| 6 | this.funcLeft, | 6 | this.funcLeft, |
| 7 | this.funcCenter, | 7 | this.funcCenter, | ... | ... |
| ... | @@ -10,7 +10,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { | ... | @@ -10,7 +10,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { |
| 10 | this.backgroundColor, | 10 | this.backgroundColor, |
| 11 | this.onPressed, | 11 | this.onPressed, |
| 12 | this.isBack = true, | 12 | this.isBack = true, |
| 13 | - this.homeTitleHeader, | 13 | + this.homeMenuHeader, |
| 14 | this.homeActionWidgets, | 14 | this.homeActionWidgets, |
| 15 | this.isTransparent = false, | 15 | this.isTransparent = false, |
| 16 | }) : super(key: key); | 16 | }) : super(key: key); |
| ... | @@ -20,7 +20,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { | ... | @@ -20,7 +20,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { |
| 20 | final bool isBack; | 20 | final bool isBack; |
| 21 | final bool isTransparent; | 21 | final bool isTransparent; |
| 22 | 22 | ||
| 23 | - final Widget? homeTitleHeader; | 23 | + final Widget? homeMenuHeader; |
| 24 | final Widget? homeActionWidgets; | 24 | final Widget? homeActionWidgets; |
| 25 | 25 | ||
| 26 | @override | 26 | @override |
| ... | @@ -44,7 +44,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { | ... | @@ -44,7 +44,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { |
| 44 | }, | 44 | }, |
| 45 | tooltip: '返回', | 45 | tooltip: '返回', |
| 46 | padding: const EdgeInsets.all(12.0), | 46 | padding: const EdgeInsets.all(12.0), |
| 47 | - icon: const Icon(Icons.arrow_back_ios_outlined), | 47 | + icon: const Icon(Icons.arrow_back_ios_outlined, color: Colors.white,), |
| 48 | ) | 48 | ) |
| 49 | : Gaps.empty; | 49 | : Gaps.empty; |
| 50 | 50 | ||
| ... | @@ -62,7 +62,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { | ... | @@ -62,7 +62,7 @@ class MyAppBar extends StatelessWidget implements PreferredSizeWidget { |
| 62 | ), | 62 | ), |
| 63 | SizedBox( | 63 | SizedBox( |
| 64 | width: MediaQuery.of(context).size.width, | 64 | width: MediaQuery.of(context).size.width, |
| 65 | - child: homeTitleHeader, | 65 | + child: homeMenuHeader, |
| 66 | ), | 66 | ), |
| 67 | SizedBox( | 67 | SizedBox( |
| 68 | child: Container( | 68 | child: Container( | ... | ... |
| ... | @@ -68,7 +68,7 @@ dependencies: | ... | @@ -68,7 +68,7 @@ dependencies: |
| 68 | # 格式化String https://github.com/Naddiseo/dart-sprintf | 68 | # 格式化String https://github.com/Naddiseo/dart-sprintf |
| 69 | sprintf: ^6.0.0 | 69 | sprintf: ^6.0.0 |
| 70 | # 状态管理 https://github.com/rrousselGit/provider | 70 | # 状态管理 https://github.com/rrousselGit/provider |
| 71 | - provider: ^6.0.1 | 71 | + provider: ^6.0.2 |
| 72 | # 扫码 https://github.com/juliuscanute/qr_code_scanner | 72 | # 扫码 https://github.com/juliuscanute/qr_code_scanner |
| 73 | qr_code_scanner: 0.6.1 | 73 | qr_code_scanner: 0.6.1 |
| 74 | # App Shortcuts https://github.com/flutter/plugins/tree/master/packages/quick_actions | 74 | # App Shortcuts https://github.com/flutter/plugins/tree/master/packages/quick_actions | ... | ... |
-
Please register or login to post a comment