Adds JavaScript class for deleting an element with children