Fixes #5000, generate labels client side.