jellyfin_back_button.dart 897 B

12345678910111213141516171819202122232425262728293031323334
  1. import 'package:flutter/material.dart';
  2. import '../../../core/theme/app_colors.dart';
  3. import '../../../core/widgets/app_icon.dart';
  4. import '../../../core/widgets/pressable.dart';
  5. class JellyfinBackButton extends StatelessWidget {
  6. const JellyfinBackButton({super.key});
  7. @override
  8. Widget build(BuildContext context) {
  9. final colors = context.colors;
  10. return Pressable(
  11. onTap: () => Navigator.of(context).pop(),
  12. semanticLabel: 'Back',
  13. pressedScale: 0.92,
  14. child: Container(
  15. width: 46,
  16. height: 46,
  17. decoration: BoxDecoration(
  18. color: colors.surface,
  19. shape: BoxShape.circle,
  20. border: Border.all(color: colors.border),
  21. ),
  22. alignment: Alignment.center,
  23. child: AppIcon(
  24. 'assets/icons/arrow-left.svg',
  25. size: 20,
  26. color: colors.ink,
  27. ),
  28. ),
  29. );
  30. }
  31. }