Its been my experience that its alright to just be with the family while they cope with a loved one that is dying. Take every opportunity to affirm them and let them know how much they are loved.
...