Closed mohammadghk closed 5 years ago
Amazing, thank you!
@mohammadghk Hi again! I'm trying to get this to work, but setting textLabel?.textAlignment
does nothing for me. Do I need to setup the device in another way?
Yes Actually because textLabel?.textAlignment
is being override in refresh()
.
Well I wanted it to work for the whole app so I changed refresh()
in ActionSheetItemCell
. Try to use it in AppDelegate like this:
let item = ActionSheetItemCell.appearance()
item.itemTextAlignment = .right
I guess I need to make it applicable for each item instead of setting in appearance proxy so should I try to change ActionSheetItem
?
The result that I'm currently using is like this:
Ah, ok I see! I have removed the explicit text alignment logic from the cells and moved it all to the appearance class, so it's easily overridable now. You can test it in master
.
One thing I noticed, however, is that the rtl logic doesn't apply when the cell uses .subtitle
as cell style. See the image.
I will create a bug for this. Hopefully it's easily resolved.
itemTextAlignment
added to item proxies for changing item'stextLabel
anddetailedTextLabel
,textAlignment
to make Sheeeeeeeeet❤️ more RTL language friendly :)