Reputation: 91
I'm using angular material component "mat-expansion-panel". the default opening direction for this component is down. i want the panel to open in different directions (left, right, up) how can i do that.
Upvotes: 2
Views: 4962
Reputation: 2859
Just do something like that
<p>Main text</p>
@if (showFiller) {
<p>Extra Lorem, ipsum dolor sit amet consectetur.</p>
}
<button (click)="showFiller = !showFiller" mat-raised-button>
Toggle extra text
</button>
Upvotes: 0
Reputation: 405
There are only one way to open mat-expansion-panel
. Its default nature is open down side as drop down works. But if you want to open it left or right side then you can use side bar.
https://material.angular.io/components/sidenav/examples
Upvotes: 1