作者:mobiledu2502925333 | 来源:互联网 | 2022-12-09 18:17
下面是仅发生扩展的示例,但我希望单击该行使其折叠。
https://stackblitz.com/edit/angular-material-expandable-table-rows?file=app%2Ftable%2Ftable.component.ts
我希望我的桌子是这样的:
请帮忙。
1> Yousef khan..:
更换
(click)="expandedElement = row"
与
(click)="expandedElement === row? expandedElement = null : expandedElement = row"
https://stackblitz.com/edit/angular-material-expandable-table-rows-8ypyfu?file=app%2Ftable%2Ftable.component.html