angular directive snippet updated