'use strict';

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

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

const styleCss = ".sc-smoothly-notifier-h{display:block}[hidden].sc-smoothly-notifier-h{display:none}.sc-smoothly-notifier-h>aside.sc-smoothly-notifier{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap-reverse;flex-wrap:wrap-reverse;-ms-flex-line-pack:stretch;align-content:stretch;-ms-flex-pack:start;justify-content:flex-start;position:fixed;bottom:3em;left:0;text-align:center;width:100%;z-index:3}";

const Notifier = class {
  constructor(hostRef) {
    index.registerInstance(this, hostRef);
    this.notices = [];
  }
  onNotice(event) {
    this.notices = [...this.notices, event.detail];
  }
  onRemove(event) {
    this.notices = [...this.notices.filter(n => n != event.detail)];
  }
  render() {
    return [
      index.h("slot", null),
      index.h("aside", null, this.notices.map(n => (index.h("smoothly-notification", { notice: n })))),
    ];
  }
};
Notifier.style = styleCss;

exports.smoothly_notifier = Notifier;
