/* eslint no-unused-vars: 0 */
import { html, svg, repeat, classMap, styleMap, ifDefined, unsafeHTML, scopeTag } from "@gsmlg/ui5-webcomponents-base/dist/renderer/LitRenderer.js";

const block0 = (context, tags, suffix) => html`<div class="ui5-table-root" @focusin="${context._onfocusin}"><div id="${ifDefined(context._id)}-before" tabindex="0" class="ui5-table-focusarea"></div>${ context.busy ? block1(context, tags, suffix) : undefined }<table border="0" cellspacing="0" cellpadding="0" @keydown="${context._onkeydown}" role="table" aria-label="${ifDefined(context.tableAriaLabelText)}"><thead><tr id="${ifDefined(context._columnHeader.id)}" role="row" class="ui5-table-header-row" aria-label="${ifDefined(context.ariaLabelText)}" tabindex="${ifDefined(context._columnHeader._tabIndex)}" @click="${context._onColumnHeaderClick}" @focusin="${context._onColumnHeaderFocused}" @keydown="${context._onColumnHeaderKeydown}">${ context.isMultiSelect ? block2(context, tags, suffix) : undefined }${ repeat(context.visibleColumns, (item, index) => item._id || index, (item, index) => block3(item, index, context, tags, suffix)) }</tr></thead><tbody>${ repeat(context.rows, (item, index) => item._id || index, (item, index) => block4(item, index, context, tags, suffix)) }${ !context.rows.length ? block5(context, tags, suffix) : undefined }${ context.growsWithButton ? block7(context, tags, suffix) : undefined }${ context.growsOnScroll ? block9(context, tags, suffix) : undefined }</tbody></table><div id="${ifDefined(context._id)}-after" tabindex="0" class="ui5-table-focusarea"></div></div> `;
const block1 = (context, tags, suffix) => suffix ? html`<div tabindex="-1" class="ui5-table-busy-row"><${scopeTag("ui5-busy-indicator", tags, suffix)} delay="${ifDefined(context.busyDelay)}" class="ui5-table-busy-ind" style="${styleMap(context.styles.busy)}" active size="Medium" data-sap-focus-ref></${scopeTag("ui5-busy-indicator", tags, suffix)}></div>` : html`<div tabindex="-1" class="ui5-table-busy-row"><ui5-busy-indicator delay="${ifDefined(context.busyDelay)}" class="ui5-table-busy-ind" style="${styleMap(context.styles.busy)}" active size="Medium" data-sap-focus-ref></ui5-busy-indicator></div>`;
const block2 = (context, tags, suffix) => suffix ? html`<th class="ui5-table-select-all-column" role="presentation" aria-hidden="true"><${scopeTag("ui5-checkbox", tags, suffix)} class="ui5-table-select-all-checkbox" ?checked="${context._allRowsSelected}" @ui5-change="${ifDefined(context._selectAll)}" aria-label="${ifDefined(context.ariaLabelSelectAllText)}" tabindex="-1"></${scopeTag("ui5-checkbox", tags, suffix)}></th>` : html`<th class="ui5-table-select-all-column" role="presentation" aria-hidden="true"><ui5-checkbox class="ui5-table-select-all-checkbox" ?checked="${context._allRowsSelected}" @ui5-change="${ifDefined(context._selectAll)}" aria-label="${ifDefined(context.ariaLabelSelectAllText)}" tabindex="-1"></ui5-checkbox></th>`;
const block3 = (item, index, context, tags, suffix) => html`<slot name="${ifDefined(item._individualSlot)}"></slot>`;
const block4 = (item, index, context, tags, suffix) => html`<slot name="${ifDefined(item._individualSlot)}"></slot>`;
const block5 = (context, tags, suffix) => html`${ !context.hideNoData ? block6(context, tags, suffix) : undefined }`;
const block6 = (context, tags, suffix) => html`<tr class="ui5-table-no-data-row-root" role="row"><td colspan="${ifDefined(context.visibleColumnsCount)}" role="cell"><div class="ui5-table-no-data-row"><span>${ifDefined(context.noDataText)}</span></div></td></tr>`;
const block7 = (context, tags, suffix) => html`<tr><td colspan="${ifDefined(context.visibleColumnsCount)}"><div growing-button><div id="${ifDefined(context._id)}-growingButton" tabindex="0" role="button" aria-labelledby="${ifDefined(context.loadMoreAriaLabelledBy)}" ?active="${context._loadMoreActive}" @click="${context._onLoadMoreClick}" @keydown="${context._onLoadMoreKeydown}" @keyup="${context._onLoadMoreKeyup}" growing-button-inner><span id="${ifDefined(context._id)}-growingButton-text" growing-button-text>${ifDefined(context._growingButtonText)}</span>${ context.growingButtonSubtext ? block8(context, tags, suffix) : undefined }</div></div></td></tr>`;
const block8 = (context, tags, suffix) => html`<span id="${ifDefined(context._id)}-growingButton-subtext" growing-button-subtext>${ifDefined(context.growingButtonSubtext)}</span>`;
const block9 = (context, tags, suffix) => html`<tr tabindex="-1" class="ui5-table-end-row"><td tabindex="-1"><span tabindex="-1" aria-hidden="true" class="ui5-table-end-marker"></span></td></tr>`;


export default block0;