ArticleInfo.dart 2.1KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. import 'package:flutter/material.dart';
  2. import 'package:flutter_screenutil/flutter_screenutil.dart';
  3. class ArticleInfo extends StatelessWidget {
  4. const ArticleInfo({Key? key}) : super(key: key);
  5. @override
  6. Widget build(BuildContext context) {
  7. return Scaffold(
  8. resizeToAvoidBottomInset: false,
  9. appBar: AppBar(
  10. title: Text('资讯'),
  11. leading: Icon(Icons.arrow_back_ios),
  12. // backgroundColor: Colors.transparent,
  13. centerTitle: true,
  14. ),
  15. body: Container(
  16. padding: EdgeInsets.fromLTRB(15, 30, 15, 50),
  17. child: Column(
  18. children: [
  19. Container(
  20. alignment: Alignment.center,
  21. child: Row(
  22. mainAxisAlignment: MainAxisAlignment.center,
  23. children: [
  24. Image(
  25. image: AssetImage('images/icons/decorate.png'),
  26. width: 17,
  27. ),
  28. Text(
  29. '我是22222222222标题',
  30. style: TextStyle(
  31. fontSize: 17.sp,
  32. fontWeight: FontWeight.bold,
  33. ),
  34. ),
  35. Image(
  36. image: AssetImage('images/icons/decorate.png'),
  37. width: 17),
  38. ],
  39. ),
  40. ),
  41. Container(
  42. padding: EdgeInsets.fromLTRB(0, 20, 0, 10),
  43. width: 344.w,
  44. child: Text(
  45. 'gr一年之计在于春,连日来,农业生产工作正在热火朝天的进行着:农技人员走村串户指导农户春耕生产,大型拖拉机忙着翻垦农田,植保无人机 ',
  46. style: TextStyle(fontSize: 14.sp),
  47. ),
  48. ),
  49. Container(
  50. padding: EdgeInsets.fromLTRB(0, 10, 0, 10),
  51. child: Image(
  52. image: AssetImage('images/cars.png'),
  53. width: 320.w,
  54. height: 260.w,
  55. fit: BoxFit.fill,
  56. ),
  57. )
  58. ],
  59. ),
  60. ),
  61. );
  62. }
  63. }