CMS-2762 Make ImageSelector set a valid name of embedded image content

New implementation of ContentName.ensureValidName