I am trying to set the hover property states using [ngStyle]. The following only sets the normal state colors. When I mouse over the button, the button does not change to the pressed colors as expected.
<button (click)="logout()"
class="btn register-button"
[ngStyle]=" hover ? {'color': theme.logoutButtonColorPressed,
'border-color': theme.logoutButtonBorderColorPressed,
'background-color': theme.logoutButtonBackgroundColorPressed } :
{'color': theme.logoutButtonColorNormal,
'border-color': theme.logoutButtonBorderColorNormal,
'background-color': theme.logoutButtonBackgroundColorNormal }">Logout</button>
If you want to switch styles on hover, add the following to the button
<button (mouseover)="hover=true" (mouseleave)="hover=false"...