Fix Before and After css for custom string fields

Change-Id: I422af4e19343e271e86a5e27a8b405f9dab6a04b