pub fn truncate_and_trailoff(s: &str, max_chars: usize) -> StringExpand description
Removes characters from the end of the string if its length is greater than max_chars and
appends “…” to the string. Returns string unchanged if its length is smaller than max_chars.