I have a custom post with a large number of custom fields. Some of this information is confidential and only meant for employees (who will be tagged with a specific custom role on toolset), while the other information can be shared with the public.
When a website visitor views this custom post, I want it to not show up the fields meant for employees. However, when employees log in, they should be able to see this content.
Are you using the Gutenburg Editor ? If so then you can use the conditional block and then place the custom fields that you want to be hidden inside this conditional block. See Screenshot
If are not using the gutenburg editor then you can use the conditional shortcode below.
[wpv-conditional if="( '[wpv-current-user info='role']' eq 'administrator' )"]
Some Content goes here
[/wpv-conditional]
Ofcourse you will change administrator to the slug of the role that you want to see the fields and then add your custom field shortcodes within the conditional.