Remove old password field from User Profile block (use case: users are initially invited with magic links)

<script>
   window.addEventListener('block-loaded-user-accounts1', () => {
   		document.querySelectorAll('#user-accounts1 form')[1].children[1].style.display = 'none'
   });
</script>

Insert this into Page Settings>Custom Code>Header or Footer and replace user-accounts1 to your respective User Profile block name