I have a dropdown list of many item and if I click on the select to display the list I want to highlight some items of that list in different color.
Expected Behaviour: When we click on the Select (before selecting any item), how to have the item "Section3" from the list be highlighted in Yellow (background section) if the tag Obligatory is true?
$scope.globalSections = [
{name: 'Section1', department: 'Summary'},
{name: 'Section2', department: 'Group1'},
{name: 'Section3', department: 'Group1', obligatory: true},
{name: 'Section4', department: 'Group2'},
{name: 'Section5', department: 'Group2'}
];
$scope.selectedSection = $scope.globalSections[0]; // Summary
<select ng-model="selectedSection" ng-options="section.name group by section.department for section in globalSections">