Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR HTML

mat-tooltip on disabled button

This doesn't work because it is triggered by mouseenter event which doesn't get fired by most browsers for disabled elements. A workaround is to add matTooltip to a parent element:
<div matTooltip="You cannot delete that" [matTooltipDisabled]="!isButtonDisabled()">
    <button mat-raised-button [disabled]="isButtonDisabled()">
        <mat-icon>delete</mat-icon>
    </button>
</div>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #disabled #button
ADD COMMENT
Topic
Name
9+1 =