import { r as registerInstance, c as createEvent, h } from './index-cdf8e526.js';
import { m as modifiersToClass } from './utils-f909044c.js';

const buttonInlineCss = ".ibk-button-inline{appearance:none;-webkit-appearance:none;-moz-appearance:none;outline:none;border:none;background-color:transparent;box-sizing:border-box;height:48px;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;transition:background-color var(--fast);padding:0 10px;border-radius:4px;text-decoration:none}.ibk-button-inline:hover{background-color:var(--gray5)}.ibk-button-inline:active{transform:translateY(1px)}.ibk-button-inline *{box-sizing:border-box}.ibk-button-inline__text{color:var(--primaryGreen1);font-size:14px;font-weight:500;font-family:var(--fontGeometria)}.ibk-button-inline__icon{color:var(--primaryGreen1);font-size:18px}.ibk-button-inline--icon-left .ibk-button-inline__icon{margin-right:7px}.ibk-button-inline--icon-right .ibk-button-inline__icon{margin-left:7px;order:2}";

const IbkButtonInline = class {
  constructor(hostRef) {
    registerInstance(this, hostRef);
    this.onclick = createEvent(this, "onclick", 7);
    /** Posición del ícono si existiera */
    this.iconPosition = 'left';
    /** Determina si le botón se encuentra deshabilitado */
    this.disable = false;
    /** Determina si el enlace se abre en una nueva ventana o en la misma */
    this.hrefTarget = '_self';
    /** Configura la clase del componente basado en estados y modificadores */
    this.containerClass = () => {
      return modifiersToClass('ibk-button-inline', [`icon-${this.iconPosition}`]);
    };
  }
  render() {
    if (this.href) {
      return (h("a", { href: this.href, target: this.hrefTarget, class: this.containerClass() }, this.icon && h("i", { class: 'ibk-button-inline__icon ' + this.icon }), this.text && h("span", { class: "ibk-button-inline__text" }, this.text)));
    }
    else {
      return (h("button", { type: "button", class: this.containerClass(), onClick: this.onclick.emit }, this.icon && h("i", { class: 'ibk-button-inline__icon ' + this.icon }), this.text && h("span", { class: "ibk-button-inline__text", innerHTML: this.text })));
    }
  }
};
IbkButtonInline.style = buttonInlineCss;

export { IbkButtonInline as ibk_button_inline };
