Add truncatechars_html template filter.

Fixes #19496.