I have a CircularProgressIndicator in my TextFormField's suffix icon. How to make it smaller?

Advertisements

I have a CircularProgressIndicator in my TextFormField‘s suffix icon. I want to make it smaller.

My code:

TextFormField(
  …
  decoration: InputDecoration(
    …
    suffixIcon: const SizedBox(
      height: 10,
      width: 10,
      child: CircularProgressIndicator(),
    ),
  ),
),

I tried the code above but it didn’t work.

>Solution :

Use Suffix instead of SuffixIcon

Leave a ReplyCancel reply