fix trim text in element