That toggle adds a simple 300ms ease-in-out animation between states, and its automatic/preset so you can't really customize it unfortunately.
This is an
example of how it works on buttons, but this is probably a much simpler use case than what you're setting up