import {LitElement, css, html} from 'https://cdn.jsdelivr.net/gh/lit/dist@3/all/lit-all.min.js'; //import 'https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.esm.js'; class CurioUX extends LitElement { static styles = css` \ .curio-slot { } :host { display: block; margin: 2px 3px; } `; connectedCallback() { super.connectedCallback(); //"https://unpkg.com/@cds/core/global.min.css", //"https://unpkg.com/@cds/city/css/bundles/default.min.css", //"https://unpkg.com/@cds/core/styles/theme.dark.min.css", //"https://unpkg.com/@clr/ui/clr-ui.min.css", document.head.innerHTML += ` ` document.documentElement.lang = 'en'; // how Bootstrap & DataTables expect dark mode declared. document.documentElement.classList.add('dark'); this.messsage = this.getCookieMessage(); } render() { return html`
${this.message? html``: html``}
`; } getCookieMessage() { const name = 'message'; const cookies = document.cookie.split(';'); for (let i = 0; i < cookies.length; i++) { const cookie = cookies[i].trim(); if (cookie.startsWith(name + '=')) { var val = cookie.substring(name.length + 1); document.cookie = name + '=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;'; return val; } } return null; } }; customElements.define('curio-ux', CurioUX);