'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

const index = require('./index-6377956f.js');

const eclCardEcCss = ".ecl-card.sc-ecl-card-ec{background-color:#f5f5f5;border:1px solid #cfcfcf;border-radius:0;box-shadow:none;box-sizing:border-box;height:100%;margin:0;overflow:hidden;overflow-wrap:break-word;width:100%}.ecl-card__image.sc-ecl-card-ec{background-position:center;background-repeat:no-repeat;background-size:cover;border:1px solid #cfcfcf;display:block;height:auto;-webkit-margin-start:1rem;margin-inline-start:1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;margin-top:1rem;width:calc(100% - (2 * 1rem) - (2 * 1px))}.ecl-card__image.sc-ecl-card-ec::before{content:\"\";display:block;padding-top:66.6666666667%;width:100%}.ecl-card__body.sc-ecl-card-ec{padding:1rem;position:relative}";

const eclCardEuCss = ".ecl-card.sc-ecl-card-eu{background-color:#fff;border:0;border-radius:8px;box-shadow:0 2px 4px rgba(9, 49, 142, 0.08), 0 0 10px rgba(9, 49, 142, 0.04), 0 4px 5px rgba(9, 49, 142, 0.04), 0 -4px 4px rgba(9, 49, 142, 0.04);box-sizing:border-box;height:100%;margin:0;overflow:hidden;overflow-wrap:break-word;width:100%}.ecl-card__image.sc-ecl-card-eu{background-position:center;background-repeat:no-repeat;background-size:cover;border:0px solid #cfdaf5;display:block;height:auto;-webkit-margin-start:0px;margin-inline-start:0px;-webkit-margin-end:0px;margin-inline-end:0px;margin-top:0px;width:calc(100% - (2 * 0px) - (2 * 0px))}.ecl-card__image.sc-ecl-card-eu::before{content:\"\";display:block;padding-top:66.6666666667%;width:100%}.ecl-card__body.sc-ecl-card-eu{padding:1.5rem;position:relative}.ecl-card__body.sc-ecl-card-eu::before{background-color:#fc0;border-bottom-left-radius:2px;border-bottom-right-radius:2px;content:\"\";height:4px;left:1.5rem;position:absolute;top:0;width:32px}";

const EclCard = class {
  constructor(hostRef) {
    index.registerInstance(this, hostRef);
    this.styleClass = '';
    this.theme = 'ec';
    this.image = undefined;
    this.imageAlt = undefined;
  }
  getClass() {
    return [
      `ecl-card`,
      this.styleClass
    ].join(' ');
  }
  getImgAttr() {
    const attrs = {
      class: 'ecl-card__image',
      role: 'img',
    };
    if (this.imageAlt) {
      attrs['alt'] = this.imageAlt;
    }
    return attrs;
  }
  render() {
    return (index.h("article", { class: this.getClass() }, index.h("div", Object.assign({ style: { backgroundImage: "url(" + this.image + ")" } }, this.getImgAttr())), index.h("div", { class: "ecl-card__body" }, index.h("slot", null))));
  }
};
EclCard.style = {
  ec: eclCardEcCss,
  eu: eclCardEuCss
};

exports.ecl_card = EclCard;

//# sourceMappingURL=ecl-card.cjs.entry.js.map