Ankur Bawiskar
Tera Patron

@KM SN 

But why to hide?

If the logged in user is able to toggle and see it means that user has correct permissions to view that.

check this

How to hide/disable Toggle Password Visibility of the Client Secret field for OAuth Entity 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader