<div class="cell filename">
    <mat-icon [class.low-opacity]="item.isFile" [svgIcon]="item.icon" class="mr-16"></mat-icon>
    <div>
        <redaction-file-name-column
            *ngIf="item.isFile && file(item) as file"
            [dossierTemplateId]="file.dossierTemplateId"
            [file]="file"
        ></redaction-file-name-column>

        <redaction-dossier-name-column
            *ngIf="item.isDossier"
            [dossierStats]="dossierStats$ | async"
            [dossier]="dossier(item)"
        ></redaction-dossier-name-column>
    </div>
</div>

<div class="cell user-column">
    <iqser-initials-avatar [user]="item.ownerId" [withName]="true"></iqser-initials-avatar>
</div>

<div class="cell">
    <a
        *ngIf="item.isFile && fileDossier$ | async as fileDossier"
        [routerLink]="fileDossier.routerLink | tenant"
        class="small-label link-action"
    >
        {{ fileDossier.dossierName }}
    </a>

    <span *ngIf="item.isDossier" class="small-label">-</span>
</div>

<div class="cell">
    <span class="small-label">
        {{ item.softDeletedTime | date : 'exactDate' }}
    </span>
</div>

<div class="cell">
    <div class="small-label">
        {{ item.restoreDate | date : 'timeFromNow' }}
    </div>
    <div class="action-buttons">
        <iqser-circle-button
            (action)="restore.emit([item])"
            *ngIf="item.canRestore && item.hasRestoreRights"
            [tooltip]="'trash.action.restore' | translate"
            icon="red:put-back"
        ></iqser-circle-button>

        <iqser-circle-button
            (action)="hardDelete.emit([item])"
            *ngIf="item.hasHardDeleteRights"
            [tooltip]="'trash.action.delete' | translate"
            icon="iqser:trash"
        ></iqser-circle-button>
    </div>
</div>
