Can You Please Give Me This Output In Flutter . Im expecting This Kind Of output For My Implementation So Please Can You Use And Give it For Flutter
Widget buildScrollableScale({ required int min, required int max, required int selectedValue, required ValueChanged onValueChanged, }) { return Container( height: 80, decoration: BoxDecoration( color: Colors.pink, borderRadius: BorderRadius.circular(8), ), child: ListView.builder( scrollDirection: Axis.horizontal, itemCount: max - min + 1, itemBuilder: (context, index) { int value = min + index; bool isSelected = value == selectedValue;
return GestureDetector(
onTap: () => onValueChanged(value),
child: Container(
width: 50,
alignment: Alignment.center,
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(
"$value",
style: TextStyle(
color: isSelected ? Colors.white : Colors.grey[300],
fontSize: isSelected ? 24 : 18,
fontWeight: isSelected ? FontWeight.bold : FontWeight.normal,
),
),
Expanded(
child: Container(
width: 2,
color: isSelected ? Colors.white : Colors.grey[300],
),
),
],
),
),
);
},
),
); }
Currently Im Using like this