I want the following thumb size to match as per the given image.
inactive switch sample active switch sample
But the switch looks like this in active and inactive mode.
this how my code makes it look
Here's the code:
Switch(
value: value,
onChanged: (){},
trackOutlineWidth: 0,
trackOutlineColor: value
? blue
: grey,
activeTrackColor: blue,
inactiveThumbColor: white,
inactiveTrackColor: grey,
),
What should I add/modify to make it match the design?
Not sure if there is a better way because this feels a bit like a work around but giving it this thumbIcon seems to work:
thumbIcon: WidgetStateProperty.all(const Icon(null)),
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With