filter chips improvement.

main_production_RSG
Sikander Saleem 2 months ago
parent c553253917
commit 5a2a4093cb

@ -266,7 +266,7 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
Widget _buildActiveFiltersChips() {
return Container(
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 4),
decoration: BoxDecoration(
color: AppColor.background(context),
border: Border(
@ -275,6 +275,7 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
spacing: 4,
children: [
Text(
'Active Filters',
@ -289,7 +290,7 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
height: 40.toScreenHeight,
child: ListView.separated(
scrollDirection: Axis.horizontal,
padding: const EdgeInsets.only(top: 8, right: 0, left: 0, bottom: 0),
padding: EdgeInsets.zero,
itemBuilder: (cxt, index) => _getActiveFilterChips()[index],
separatorBuilder: (cxt, index) => 8.width,
itemCount: _getActiveFilterChips().length),
@ -459,7 +460,6 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
showDelete: false,
));
}
return chips;
}
@ -470,6 +470,7 @@ class _MyRequestsPageState extends State<MyRequestsPage> {
backgroundColor: AppColor.backgroundTabBarColor(context),
side: BorderSide(color: AppColor.border2Color(context)),
label: Text(label),
visualDensity: VisualDensity.compact,
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(30.0)),
labelStyle: AppTextStyles.tinyFont2.copyWith(color: AppColor.labelTextStyleColor(context)),
deleteIconColor: showDelete ? AppColor.icon2Color(context) : null,

@ -261,7 +261,7 @@ class _MyAssetsPageState extends State<MyAssetsPage> {
Widget _buildActiveFiltersChips() {
return Container(
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 4),
decoration: BoxDecoration(
color: AppColor.background(context),
border: Border(
@ -270,13 +270,11 @@ class _MyAssetsPageState extends State<MyAssetsPage> {
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
spacing: 4,
children: [
Text(
'Active Filters',
style: AppTextStyles.tinyFont2.copyWith(
color: AppColor.labelTextStyleColor(context),
fontWeight: FontWeight.w600,
),
style: AppTextStyles.tinyFont2.copyWith(color: AppColor.labelTextStyleColor(context), fontWeight: FontWeight.w600),
),
Row(
mainAxisSize: MainAxisSize.min,
@ -287,7 +285,7 @@ class _MyAssetsPageState extends State<MyAssetsPage> {
height: 40.toScreenHeight,
child: ListView.separated(
scrollDirection: Axis.horizontal,
padding: const EdgeInsets.only(top: 8, right: 0, left: 0, bottom: 0),
padding: EdgeInsets.zero,
itemBuilder: (cxt, index) => _getActiveFilterChips()[index],
separatorBuilder: (cxt, index) => 8.width,
itemCount: _getActiveFilterChips().length,
@ -492,13 +490,11 @@ class _MyAssetsPageState extends State<MyAssetsPage> {
Widget _buildFilterChip({required String label, required VoidCallback onDelete}) {
return Theme(
data: Theme.of(context).copyWith(
splashColor: Colors.transparent,
highlightColor: Colors.transparent,
),
data: Theme.of(context).copyWith(splashColor: Colors.transparent, highlightColor: Colors.transparent),
child: Chip(
backgroundColor: AppColor.backgroundTabBarColor(context),
side: BorderSide(color: AppColor.border2Color(context)),
visualDensity: VisualDensity.compact,
label: Text(label),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(30.0),

Loading…
Cancel
Save