我们可以在可扩展行内使用clr-dg-row

时间:2018-12-12 11:15:09

标签: vmware-clarity

为清楚起见,在为可扩展行提供的示例中,对于MyDetailComponent,模板中未使用<clr-dg-row-detail>标签。是否可以在MyDetailComponent模板中放置没有<clr-dg-row> cell info here..</clr-dg-row>的其他标签,例如<clr-dg-row-detail>?我尝试了一下,效果很好,但想检查一下是否正确……

@Component({
    selector: "my-detail",
    template: `
        <div [ clrLoading ]="loading">...</div>
    `
})
class MyDetailComponent implements OnInit {
    @Input() user: User;

    loading: boolean;
<clr-dg-row *ngFor="let user of users">
  <-- Cells declarations -->
    <clr-dg-cell>...
    </clr-dg-cell>

    <my-detail *clrIfExpanded [user]="user" ngProjectAs="clr-dg-row-detail">
    </my-detail>
</clr-dg-row>

0 个答案:

没有答案
相关问题