// #region Imports
import { html } from '../../../../Dom/Html';
import { when } from '../../../Directives/Directives';
import { setHost } from '../../../Directives/setHost';
// #endregion
/**
 * @public
 */
export function toolbarElementTemplate(e) {
    return html `
        <div part="root">
            <slot name="start"></slot>
            <div part="main"
                 ?hidden="${!setHost(e, 'has-main', e.hasSlotContent('') || e.hasSlotContent('title') || e.hasSlotContent('subTitle'))}">
                <slot></slot>
                <div part="title"
                     ?hidden="${!setHost(e, 'has-title', e.hasSlotContent('title'))}">
                    <slot name="title">
                        ${when(e.title.trim(), () => html `
                        <mosaik-text .text="${e.title}"
                                     .formatter="${e.formatter}"
                                     .truncate="${true}"></mosaik-text>
                        `)}
                    </slot>
                </div>
                <div part="subTitle"
                     ?hidden="${!setHost(e, 'has-sub-title', e.hasSlotContent('subTitle'))}">
                    <slot name="subTitle">
                        ${when(e.subTitle.trim(), () => html `
                        <mosaik-text .text="${e.subTitle}"
                                     .formatter="${e.formatter}"
                                     .truncate="${true}"></mosaik-text>
                        `)}
                    </slot>
                </div>
            </div>
            <slot name="end"></slot>
        </div>
    `;
}
//# sourceMappingURL=ToolbarElementTemplate.js.map