flutter-animated-counter icon indicating copy to clipboard operation
flutter-animated-counter copied to clipboard

Add ability for suffix textOverflow

Open sabifa opened this issue 1 year ago • 3 comments

Thanks for your package, I really like it so far. One thing that is missing for my usecase is the ability to specify a textOverflow for the suffix (e.g. ellipsis).

I've created a PR that adds this functionality. What are your thoughts on this?

sabifa avatar Sep 26 '24 12:09 sabifa

Another possibility would be to change the type of suffix / prefix to Widget instead of String. This way I could pass my adapted overflowable text widget into the widget like so instead of adding the suffixOverflow param.

AnimatedFlipCounter(
  duration: Duration(milliseconds: 500),
  value: _value,
  suffix: Flexible(
    child: Text(
      'my long text that is currently overflowing',
      overflow: TextOverflow.ellipsis,
    ),
  )
)

This would produce a breaking change though.

sabifa avatar Sep 26 '24 12:09 sabifa

I have the same problem.

Muhammarizo avatar Oct 17 '24 06:10 Muhammarizo

Same in case of prefix. we can't style to prefix or suffix.

AbhishekYadav03 avatar Feb 12 '25 10:02 AbhishekYadav03