I’ve already published the script, and it’s working as expected. The user can show, or hide text in the password field. The problem is, I don’t know what to do about the icons.
They’re stacked on top of each other! But, the “hide” eye isn’t supposed to be visible until the “show” eye is clicked, and vice versa. How do I fix this? I thought about using a transform effect, but I don’t know if that’s the correct way to do it.
Here’s the read-only link. (Click here to see the script in action, since custom code only appears on published sites.)
I did try that, and was confused as to why the second icon was still visible. Turns out, I’d forgotten to actually hide the “hide” icon. This is embarrassing. Thank you!
(Dropping this here for future folks exploring the forums )
If you’re trying to find some code or a project to show and hide the contents of a password field, I just created a cloneable show password project you could use. If you have any questions, feel free to ping me!