Updated truncate mixin, configurable.