fix : new bottom sheet
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
|
||||
class AppFonts {
|
||||
AppFonts._(); // Private constructor to prevent instantiation
|
||||
@@ -173,6 +174,15 @@ class AppFonts {
|
||||
height: _height,
|
||||
);
|
||||
|
||||
|
||||
static const TextStyle yekan14Bold = TextStyle(
|
||||
fontFamily: yekan,
|
||||
fontWeight: bold, // Use bold weight
|
||||
fontSize: 13,
|
||||
height: _height,
|
||||
);
|
||||
|
||||
|
||||
static const TextStyle yekan13Bold = TextStyle(
|
||||
fontFamily: yekan,
|
||||
fontWeight: bold, // Use bold weight
|
||||
@@ -180,10 +190,18 @@ class AppFonts {
|
||||
height: _height,
|
||||
);
|
||||
|
||||
static const TextStyle yekan10Bold = TextStyle(
|
||||
static TextStyle yekan12Bold = TextStyle(
|
||||
fontFamily: yekan,
|
||||
fontWeight: bold, // Use bold weight
|
||||
fontSize: 10,
|
||||
fontSize: 12.sp,
|
||||
height: _height,
|
||||
);
|
||||
|
||||
|
||||
static TextStyle yekan10Bold = TextStyle(
|
||||
fontFamily: yekan,
|
||||
fontWeight: bold, // Use bold weight
|
||||
fontSize: 10.sp,
|
||||
height: _height,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,82 +0,0 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:rasadyar_core/core.dart';
|
||||
|
||||
class BottomNavigation1 extends StatefulWidget {
|
||||
const BottomNavigation1({super.key, required this.items});
|
||||
|
||||
final List<BottomNavigation1Item> items;
|
||||
|
||||
@override
|
||||
State<BottomNavigation1> createState() => _BottomNavigation1State();
|
||||
}
|
||||
|
||||
class _BottomNavigation1State extends State<BottomNavigation1> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
height: 90,
|
||||
padding: EdgeInsets.fromLTRB(50, 10, 50, 10),
|
||||
decoration: BoxDecoration(
|
||||
color: AppColor.blueNormal,
|
||||
borderRadius: const BorderRadius.only(
|
||||
topLeft: Radius.circular(50),
|
||||
topRight: Radius.circular(50),
|
||||
),
|
||||
),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: widget.items,
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class BottomNavigation1Item extends StatelessWidget {
|
||||
final String icon;
|
||||
final String label;
|
||||
final bool isSelected;
|
||||
final Function() onTap;
|
||||
|
||||
const BottomNavigation1Item({
|
||||
super.key,
|
||||
required this.icon,
|
||||
required this.label,
|
||||
required this.isSelected,
|
||||
required this.onTap,
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
width: 80,
|
||||
height: 80,
|
||||
padding: const EdgeInsets.symmetric(horizontal: 10),
|
||||
decoration: BoxDecoration(
|
||||
color: isSelected ? Colors.white.withAlpha(208) : Colors.transparent,
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
),
|
||||
child: InkWell(
|
||||
onTap: onTap,
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
SvgGenImage.vec(icon).svg(
|
||||
width: 32,
|
||||
height: 32,
|
||||
colorFilter: ColorFilter.mode(
|
||||
isSelected ? AppColor.blueNormal : Colors.white,
|
||||
BlendMode.srcIn)
|
||||
),
|
||||
const SizedBox(height: 5),
|
||||
Text(
|
||||
label,
|
||||
style: AppFonts.yekan10.copyWith(
|
||||
color: isSelected ? AppColor.blueNormal : Colors.white,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,69 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:rasadyar_core/core.dart';
|
||||
|
||||
class RBottomNavigation extends StatefulWidget {
|
||||
const RBottomNavigation({super.key, required this.items});
|
||||
|
||||
final List<RBottomNavigationItem> items;
|
||||
|
||||
@override
|
||||
State<RBottomNavigation> createState() => _RBottomNavigationState();
|
||||
}
|
||||
|
||||
class _RBottomNavigationState extends State<RBottomNavigation> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
height: 100.h,
|
||||
padding: EdgeInsets.symmetric(horizontal: 11.w, vertical: 18.h),
|
||||
decoration: BoxDecoration(
|
||||
color: AppColor.blueNormal,
|
||||
borderRadius: const BorderRadius.only(topLeft: Radius.circular(32), topRight: Radius.circular(32)),
|
||||
),
|
||||
child: Row(mainAxisAlignment: MainAxisAlignment.spaceBetween, children: widget.items),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class RBottomNavigationItem extends StatelessWidget {
|
||||
final String icon;
|
||||
final String label;
|
||||
final bool isSelected;
|
||||
final Function() onTap;
|
||||
|
||||
const RBottomNavigationItem({
|
||||
super.key,
|
||||
required this.icon,
|
||||
required this.label,
|
||||
required this.isSelected,
|
||||
required this.onTap,
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
width: 70.w,
|
||||
height: 70.h,
|
||||
padding: const EdgeInsets.symmetric(horizontal: 10),
|
||||
decoration: BoxDecoration(
|
||||
color: isSelected ? Colors.white.withAlpha(208) : Colors.transparent,
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
),
|
||||
child: InkWell(
|
||||
onTap: onTap,
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
SvgGenImage.vec(icon).svg(
|
||||
width: 40.w,
|
||||
height: 40.h,
|
||||
colorFilter: ColorFilter.mode(isSelected ? AppColor.blueNormal : Colors.white, BlendMode.srcIn),
|
||||
),
|
||||
SizedBox(height: 5.h),
|
||||
Text(label, style: AppFonts.yekan10.copyWith(color: isSelected ? AppColor.blueNormal : Colors.white)),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
export 'app_bar/r_app_bar.dart';
|
||||
export 'bottom_navigation/bottom_navigation_1.dart';
|
||||
export 'bottom_navigation/r_bottom_navigation.dart';
|
||||
export 'bottom_navigation/wave_bottom_navigation.dart';
|
||||
export 'buttons/elevated.dart';
|
||||
export 'buttons/outline_elevated.dart';
|
||||
|
||||
Reference in New Issue
Block a user