added hide/unhide merge/unmerge javascript