On the user interface, I have a dynamic display of mat-grid-tile within a mat-grid-list. These tiles change in number and data based on backend values. When a user clicks on a mat-grid-tile, it triggers a function that receives the tile's data. My goal is to visually highlight the clicked mat-grid-tile until the user navigates away.
I've attempted using mat-grid-tile:active{background-color: #333} to change the background color upon click, but it only flashes for a brief moment instead of remaining highlighted.
{{tile.Name}}
I am looking for a solution where the selected tile remains visibly highlighted with the changed background color until the user leaves this page or section.