added js function to prompt user with note deletion confirmation