image.dart 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. import 'package:cached_network_image/cached_network_image.dart';
  2. import 'package:flutter/material.dart';
  3. Widget arrowBack() => Image.asset("lib/assets/img/topbar_return.png");
  4. Widget arrowLeft() => Image.asset("lib/assets/img/btn_arrow_left.png");
  5. Widget arrowRight() => Image.asset("lib/assets/img/btn_arrow_right.png");
  6. Widget arrowTop() => Image.asset("lib/assets/img/btn_arrow_top.png");
  7. Widget arrowBottom() => Image.asset("lib/assets/img/btn_arrow_bottom.png");
  8. Widget arrowRight1() => Image.asset("lib/assets/img/btn_arrow_right1.png");
  9. Widget arrowRight2() => Image.asset("lib/assets/img/btn_arrow_right2.png");
  10. Widget arrowRight4() => Image.asset("lib/assets/img/btn_arrow_right4.png");
  11. Widget arrowRight5() => Image.asset("lib/assets/img/btn_arrow_right5.png");
  12. Widget arrowRight6() => Image.asset("lib/assets/img/btn_arrow_right6.png");
  13. Widget arrowRight7() => Image.asset("lib/assets/img/btn_arrow_right7.png");
  14. ImageProvider userAvatarProvider(String url) =>
  15. (url == null || url == "") ? AssetImage("lib/assets/img/user_default_avatar.png") : CachedNetworkImageProvider(url);
  16. Widget userAvatar(String url) => (url == null || url == "") ? Image.asset("lib/assets/img/user_default_avatar.png") : CachedNetworkImage(imageUrl: url);
  17. Widget iconMore() => Image.asset(
  18. "lib/assets/img/topbar_more_white.png",
  19. );
  20. Widget iconMoreGray() => Image.asset(
  21. "lib/assets/img/topbar_more.png",
  22. );
  23. final Widget dot = Container(
  24. margin: const EdgeInsets.symmetric(horizontal: 10.0),
  25. width: 2,
  26. height: 2,
  27. color: Color(0xff999999),
  28. );