@scania/tegel
Version:
Tegel Design System
20 lines (16 loc) • 1.34 kB
JavaScript
import { r as registerInstance, h, H as Host, a as getElement } from './index-9xxNGlso.js';
import { i as inheritAriaAttributes } from './inheritAriaAttributes-DyLhgCIg.js';
import './inheritAttributes-CF8bH08v.js';
const headerHamburgerCss = () => `:host{color:var(--tds-white)}:host tds-header-item{display:block}:host .icon{position:relative;margin-left:-6px;left:3px;transition:background 0.2s ease-in-out, color 0.2s ease-in-out}@media screen and (min-width: 992px){:host tds-header-item{display:none}:host([persistent]) tds-header-item{display:block}}`;
const TdsHeaderHamburger = class {
constructor(hostRef) {
registerInstance(this, hostRef);
}
render() {
const inheritedButtonProps = Object.assign({}, inheritAriaAttributes(this.host));
return (h(Host, { key: 'eaac9c93fdbdc332c51c3dd0888eab60d95275d0' }, h("tds-header-item", { key: '6826512a3fec5c06de3acf983eea5af605beaf18' }, h("button", Object.assign({ key: 'f8b782c514f26198f19b67da4cfe2875554416ef' }, inheritedButtonProps, { "aria-label": this.tdsAriaLabel }), h("tds-icon", { key: '013f54329f729aec325b219e66b95fd4d537a68e', class: "icon", name: "burger", size: "20px" })))));
}
get host() { return getElement(this); }
};
TdsHeaderHamburger.style = headerHamburgerCss();
export { TdsHeaderHamburger as tds_header_hamburger };