import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
import { d as defineCustomElement$8 } from './telia-column.js';
import { d as defineCustomElement$7 } from './telia-grid2.js';
import { d as defineCustomElement$6 } from './telia-link2.js';
import { d as defineCustomElement$5 } from './telia-list2.js';
import { d as defineCustomElement$4 } from './telia-row2.js';
import { d as defineCustomElement$3 } from './telia-style-link2.js';
import { d as defineCustomElement$2 } from './telia-vst2.js';

const teliaFooterLegalCss = ".telia-footer-legal{color:#ffffff;display:flex;flex-direction:column}@media screen and (min-width: 64em){.telia-footer-legal{align-items:center;flex-direction:row;justify-content:space-between}}.telia-footer-legal__container{padding:0}.telia-footer-legal__copyright-notice{font-family:\"TeliaSans\", Helvetica, Arial, \"Lucida Grande\", sans-serif;font-weight:normal;font-size:calc(1.6rem * var(--voca-rem-multiplier));line-height:1.5;margin-bottom:calc(0.8rem * var(--voca-rem-multiplier))}.telia-footer-legal__content{}.telia-footer-legal__content telia-col:first-of-type{display:flex;flex-direction:column;justify-content:flex-end;margin-bottom:calc(1.6rem * var(--voca-rem-multiplier))}@media screen and (min-width: 37.5em){.telia-footer-legal__content telia-col:first-of-type{margin-bottom:0}}.telia-footer-legal__content ::slotted([slot=contacts]){font-family:\"TeliaSans\", Helvetica, Arial, \"Lucida Grande\", sans-serif;font-weight:normal;font-size:calc(1.4rem * var(--voca-rem-multiplier));line-height:1.5;color:rgba(255, 255, 255, 0.6)}.telia-footer-legal__content ::slotted([slot=additional]){margin-bottom:calc(1.6rem * var(--voca-rem-multiplier))}.telia-footer-legal__content telia-col:last-of-type{display:grid}@media screen and (min-width: 37.5em){.telia-footer-legal__content telia-col:last-of-type{justify-content:flex-end}}.telia-footer-legal__links{align-self:flex-end}.telia-footer-legal__link{font-family:\"TeliaSans\", Helvetica, Arial, \"Lucida Grande\", sans-serif;font-weight:normal;font-size:calc(1.6rem * var(--voca-rem-multiplier));line-height:1.5;width:100%;margin-bottom:calc(0.8rem * var(--voca-rem-multiplier))}@media screen and (min-width: 37.5em){.telia-footer-legal__link{width:auto;margin-bottom:0;margin-right:calc(1.2rem * var(--voca-rem-multiplier))}.telia-footer-legal__link:last-of-type{margin-right:0}}.telia-footer-legal__link:last-of-type{margin-bottom:0}";

const TeliaFooterLegal$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
  constructor() {
    super();
    this.__registerHost();
    this.__attachShadow();
    /** Tracking id is used to identify and count Component usage */
    this.dataTrackingId = 'telia-footer-legal';
    this.classname = 'telia-footer-legal';
  }
  getItems() {
    if (!this.items) {
      return;
    }
    let localItems;
    if (typeof this.items === 'object') {
      localItems = this.items;
    }
    else {
      localItems = JSON.parse(this.items);
    }
    return localItems.map(item => {
      return (h("li", { class: `${this.classname}__link` }, h("telia-link", { href: item.href, variant: "text", "dark-background": true, "disable-visited": true }, item.name)));
    });
  }
  renderCopyrightNotice() {
    if (this.copyright) {
      return (h("div", { class: `${this.classname}__copyright-notice` }, this.copyright));
    }
    return;
  }
  render() {
    return (h(Host, { class: `${this.classname}`, "data-testid": this.dataTestid }, h("telia-grid", { class: `${this.classname}__container` }, h("telia-row", { class: `${this.classname}__content` }, h("telia-col", { width: 12, "width-md": 6 }, this.renderCopyrightNotice(), h("slot", { name: "contacts" })), h("telia-col", { width: 12, "width-md": 6 }, h("slot", { name: "additional" }), h("telia-list", { class: `${this.classname}__links`, "list-tag": "ul", variant: "row" }, this.getItems())))), h("telia-vst", { dataTrackingId: this.dataTrackingId })));
  }
  static get style() { return teliaFooterLegalCss; }
}, [1, "telia-footer-legal", {
    "dataTestid": [1, "data-testid"],
    "copyright": [1],
    "items": [1]
  }]);
function defineCustomElement$1() {
  if (typeof customElements === "undefined") {
    return;
  }
  const components = ["telia-footer-legal", "telia-col", "telia-grid", "telia-link", "telia-list", "telia-row", "telia-style-link", "telia-vst"];
  components.forEach(tagName => { switch (tagName) {
    case "telia-footer-legal":
      if (!customElements.get(tagName)) {
        customElements.define(tagName, TeliaFooterLegal$1);
      }
      break;
    case "telia-col":
      if (!customElements.get(tagName)) {
        defineCustomElement$8();
      }
      break;
    case "telia-grid":
      if (!customElements.get(tagName)) {
        defineCustomElement$7();
      }
      break;
    case "telia-link":
      if (!customElements.get(tagName)) {
        defineCustomElement$6();
      }
      break;
    case "telia-list":
      if (!customElements.get(tagName)) {
        defineCustomElement$5();
      }
      break;
    case "telia-row":
      if (!customElements.get(tagName)) {
        defineCustomElement$4();
      }
      break;
    case "telia-style-link":
      if (!customElements.get(tagName)) {
        defineCustomElement$3();
      }
      break;
    case "telia-vst":
      if (!customElements.get(tagName)) {
        defineCustomElement$2();
      }
      break;
  } });
}
defineCustomElement$1();

const TeliaFooterLegal = TeliaFooterLegal$1;
const defineCustomElement = defineCustomElement$1;

export { TeliaFooterLegal, defineCustomElement };
