我的图标指向右,如何更改它以便指向左

VC.labelSelected = self.details[(indexPath as NSIndexPath).row] + "✏️"

最佳答案

仅将self.details[(indexPath as NSIndexPath).row]带到下一个屏幕。

将图标分配给labelIcon,将其翻转,隐藏,然后将其文本分配给labelSelected

labelIcon.text = "✏️"
labelIcon.transform = CGAffineTransformMakeScale(-1, 1);
labelIcon.hidden = true

labelSelected.text = self.details[(indexPath as NSIndexPath).row] + labelIcon.text

10-07 12:55