Answer the question
In order to leave comments, you need to log in
How to change style in Angular based on condition?
How to set a certain style depending on the conditions?
For example if $scope.stage.status_stage = 1 then STYLE = color: #ccc
<tr ng-repeat="stage in stage" ng-style="STYLE">
<td>{{$index+1}}</td>
Answer the question
In order to leave comments, you need to log in
You can try like this:
ng-style="{color:stage.status_stage==1?'#ccc':''}"
или
style="{{stage.status_stage==1?'color: #ccc':''}}"
It is necessary to hang the class corresponding to the state through ngClass.
https://scotch.io/tutorials/the-many-ways-to-use-n...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question