This commit centralizes 'display name' generation into a helper, and updates it to respect core preferences for `enable_names` and `prioritize_username_in_ux`.