I am trying to make the mat-table
border as round. But it is not working. Tried this-
table {
width: 100%;
border-collapse: collapse;
border-radius: 1em;
}
How to achieve this?
The most simple solution that worked for me was to hide the overflow of certain elements that gave the unfinished look when we set the border-radius. So, we just handle that
.mat-table{
border-radius: 8px;
overflow:hidden !important;
}
Feel free to point out cases where this might cause other issues.
the problem is that you need over-ride the background-color of mat-table:
.mat-table
{
background-color:transparent!important;
}
table {
width: 100%;
border-collapse: collapse;
border-radius: 5em;
}
table tr:last-child td /*To remove the last border*/
{
border-bottom:0 solid
}
stackblitz
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With