forked from eatvio/eatvio_app
create diet screen
This commit is contained in:
@@ -1,38 +0,0 @@
|
||||
import 'package:eatvio_app/core/theme/theme_helper.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class MainBackgroundBouble extends StatelessWidget {
|
||||
const MainBackgroundBouble(
|
||||
{super.key, required this.child, this.width, this.padding, this.enableShadow = false,});
|
||||
final double? width;
|
||||
final Widget child;
|
||||
final bool enableShadow;
|
||||
final EdgeInsetsGeometry? padding;
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return DecoratedBox(
|
||||
decoration: BoxDecoration(
|
||||
boxShadow: enableShadow
|
||||
? [
|
||||
BoxShadow(
|
||||
color: Color(0x00000000).withOpacity(0.2),
|
||||
spreadRadius: 0,
|
||||
blurRadius: 32,
|
||||
offset: Offset(0, 0),
|
||||
),
|
||||
]
|
||||
: null,),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(12),
|
||||
child: Container(
|
||||
decoration: BoxDecoration(
|
||||
color: appTheme.whiteA700,
|
||||
),
|
||||
width: width ?? MediaQuery.sizeOf(context).width,
|
||||
padding: padding,
|
||||
child: child,
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
import 'package:eatvio_app/core/const.dart';
|
||||
import 'package:eatvio_app/core/utils/toasts.dart';
|
||||
import 'package:eatvio_app/core/widgets/custom_divider.dart';
|
||||
import 'package:eatvio_app/features/diets/presentation/widgets/main_background_bouble.dart';
|
||||
import 'package:eatvio_app/core/widgets/main_background_bouble.dart';
|
||||
import 'package:eatvio_app/generated/l10n.dart';
|
||||
import 'package:eatvio_app/core/theme/custom_text_style.dart';
|
||||
import 'package:eatvio_app/core/theme/theme_helper.dart';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import 'package:eatvio_app/features/diets/presentation/widgets/main_background_bouble.dart';
|
||||
import 'package:eatvio_app/core/widgets/main_background_bouble.dart';
|
||||
import 'package:eatvio_app/features/feed/models/diets_pagination_model.dart';
|
||||
import 'package:eatvio_app/generated/l10n.dart';
|
||||
import 'package:eatvio_app/core/theme/custom_text_style.dart';
|
||||
@@ -23,15 +23,15 @@ class _TypeBadgesState extends State<TypeBadges> {
|
||||
Widget build(BuildContext context) {
|
||||
final s = S.of(context);
|
||||
final List<(String, Widget)> badgeSource = [];
|
||||
if (widget.type.alko == true) {
|
||||
if (widget.type.light == true) {
|
||||
badgeSource.add(
|
||||
(
|
||||
'assets/icons/cocktail.svg',
|
||||
_InfoOverlayEntry(
|
||||
onClose: closeOverlay,
|
||||
assetPath: 'assets/icons/cocktail.svg',
|
||||
title: s.alko_type,
|
||||
description: s.alko_type_desc,
|
||||
title: s.light_type,
|
||||
description: s.light_type_desc,
|
||||
)
|
||||
),
|
||||
);
|
||||
@@ -49,15 +49,15 @@ class _TypeBadgesState extends State<TypeBadges> {
|
||||
),
|
||||
);
|
||||
}
|
||||
if (widget.type.corb == true) {
|
||||
if (widget.type.carb == true) {
|
||||
badgeSource.add(
|
||||
(
|
||||
'assets/icons/bread.svg',
|
||||
_InfoOverlayEntry(
|
||||
onClose: closeOverlay,
|
||||
assetPath: 'assets/icons/bread.svg',
|
||||
title: s.corb_type,
|
||||
description: s.corb_type_desc,
|
||||
title: s.carb_type,
|
||||
description: s.carb_type_desc,
|
||||
)
|
||||
),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user