microsoft / AdaptiveCards

A new way for developers to exchange card content in a common and consistent way.
https://adaptivecards.io
MIT License
1.75k stars 547 forks source link

Add actions.allowTitleToWrap to non JS platforms #3482

Open RebeccaAnne opened 5 years ago

RebeccaAnne commented 5 years ago

Platform

What platform is your issue or question related to? (Delete other platforms).

Issue

Javascript supports a host config property actions.allowTitleToWrap which allows long text on buttons to wrap. This property would likely be useful on other platforms and we should consider documenting and implementing it across renderers.

ghost commented 4 years ago

This issue has been automatically marked as stale because it has not had any activity for 5 days.

geo-msft commented 4 years ago

If this refers to text wrap on Action.Submit, it would be very useful to have this on Teams as well. I notice many users would like this feature.

Thank you.

Jageen commented 4 years ago

May I know any workaround for this issue ?

I had integrate this SDK into my project where I am rendering Adaptive Card.

When server send long text as action title it did not wrap and make as multi line button.

I had tried this so far.

  1. Make change in host config (i.e "actionTitleToWrap": true)
  2. Implemented ACRBaseActionElementRenderer and set UIButtons property such as "numberOfLines" as 2 and "lineBreakMode" as .byWordWrapping.

I had no luck so far.

FYI : I am having this issue in iOS platform. In android is working fine.

Jageen commented 3 years ago

I think it's fixed by now. V 5320 4739 4170