Skip to content

fix: 🐛 [IOSSDKBUG-1337] wrap long text of action button in cardfooter#1471

Closed
zzchao-1999 wants to merge 4 commits intoSAP:mainfrom
zzchao-1999:IOSSDKBUG-1337
Closed

fix: 🐛 [IOSSDKBUG-1337] wrap long text of action button in cardfooter#1471
zzchao-1999 wants to merge 4 commits intoSAP:mainfrom
zzchao-1999:IOSSDKBUG-1337

Conversation

@zzchao-1999
Copy link
Collaborator

No description provided.

@zzchao-1999 zzchao-1999 requested a review from a team as a code owner January 7, 2026 01:06
@zzchao-1999 zzchao-1999 requested review from billzhou0223 and removed request for a team January 7, 2026 01:06
@billzhou0223 billzhou0223 requested a review from shengxu7 January 7, 2026 01:18
Copy link
Member

@shengxu7 shengxu7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zzchao-1999 What problem do you try to solve? Can you provide a before and after screenshots. Original version should support text wrapping for buttons.


let subViewSizes = subviews.reversed().map {
$0.sizeThatFits(proposal)
// Use width-constrained proposal when calculating subview sizes to enable text wrapping
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zzchao-1999 This is not necessary since maxButtonWidth is always nil so far.

// check if overflow should be shown
if numToShow < numButtons {
requiredFinalWidth += min(self.maxButtonWidth, overflowSize.width) + theSpacing
maxHeight = max(maxHeight, overflowSize.height)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@zzchao-1999 This is not needed since line 198 does this.
if numToHide > 0 {
maxHeight = max(maxHeight, overflowSize.height)
}

@dyongxu
Copy link
Collaborator

dyongxu commented Jan 9, 2026

Simulator Screenshot - iPad Pro 13-inch (M5) - 2026-01-08 at 16 06 02

@dyongxu
Copy link
Collaborator

dyongxu commented Jan 9, 2026

@zzchao-1999 Can you also check for iOS 26.2 if working? Looks to me the layout of the two buttons is not correct. There is a "overflow" icon to the right. See screenshot

@zzchao-1999
Copy link
Collaborator Author

@zzchao-1999 What problem do you try to solve? Can you provide a before and after screenshots. Original version should support text wrapping for buttons.

I double checked it, the long text wrap issue has been fixed by the commit on Jan. 6. Sorry, I'll close it.

@zzchao-1999
Copy link
Collaborator Author

@zzchao-1999 Can you also check for iOS 26.2 if working? Looks to me the layout of the two buttons is not correct. There is a "overflow" icon to the right. See screenshot

It seems that this is a new issue. I’ll check it and create a new ticket to fix it.

@zzchao-1999
Copy link
Collaborator Author

The issue has been fixed by below checkin:
#1465.

@zzchao-1999 zzchao-1999 closed this Jan 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants