ExpandableText
ExpandableText copied to clipboard
Expand button is displayed even though the text is very short
Here my expanable text:
ExpandableText(text: "Live long and prosper!")
Shouldn't the expand/collapse buttons be hidden for a single-line string?
In line 139
https://github.com/NuPlay/ExpandableText/blob/d140b404c6683bb169bb01ef4eeecdb6d9be8fb8/Sources/ExpandableText/ExpandableText.swift#L139
I added a print call:
print("size: \(geo.size.width)x\(geo.size.height)")
and the output is:
size: 0.0x656.6666666666666
It's very strange, that the width is zero. And because of it, is the height larger than normal and that is the cause, why truncated is set to true.