import TableHeaderCell from "./TableHeaderCell.js";
import type TableHeaderRow from "./TableHeaderRow.js";
export default function TableHeaderRowTemplate(this: TableHeaderRow, ariaColIndex: number = 1) {
return (
<>
{ this._hasSelector &&
{ this._tableSelection!.renderHeaderSelectionCell(this) }
}
{ this.cells.flatMap(cell => {
if (cell._popin) {
cell.role = null;
cell.ariaColIndex = null;
return [];
}
cell.role ??= cell.ariaRole;
cell.ariaColIndex = (cell.role === cell.ariaRole) ? `${ariaColIndex++}` : null;
return [];
})}
{ this._renderDummyCell && this._hasPopin &&
}
{ this._rowActionCount > 0 &&
{this._i18nRowActions}
}
{ this._renderNavigated &&
}
{ this._renderDummyCell && !this._hasPopin &&
}
{ this._hasPopin &&
{this._i18nRowPopin}
}
>
);
}