'use strict';

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

const index = require('./index-609aba38.js');

const CorejamFlash = class {
  constructor(hostRef) {
    index.registerInstance(this, hostRef);
    this.colors = {
      success: "red",
      info: "blue",
      warning: "orange",
      error: "red",
    };
  }
  flashEvent(evt) {
    this.flash = evt.detail;
  }
  render() {
    return (index.h(index.Host, null, this.flash && (index.h("corejam-box", { p: 3, bWidth: 1, rounded: "md", bColor: `${this.colors[this.flash.type]}-700`, bg: `${this.colors[this.flash.type]}-300`, m: 3, w: "12", h: "100%", onClick: () => (this.flash = null) }, this.flash.msg))));
  }
};

exports.corejam_flash = CorejamFlash;
