'use strict';

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

const __chunk_1 = require('./chunk-2755df65.js');

class RouteLink {
    constructor(hostRef) {
        __chunk_1.registerInstance(this, hostRef);
        this.registerRouteLink = __chunk_1.createEvent(this, "registerRouteLink", 7);
        this.routeLinkChange = __chunk_1.createEvent(this, "routeLinkChange", 7);
    }
    componentDidLoad() {
        this.postRender();
    }
    componentDidUpdate() {
        this.routeLinkChange.emit({ url: this.url, action: this.action, actionParams: this.actionParams });
        this.postRender();
    }
    postRender() {
        this.registerRouteLink.emit({ url: this.url, action: this.action, actionParams: this.actionParams });
    }
    render() {
        return (__chunk_1.h("div", null, __chunk_1.h("a", { href: '' + this.url }, __chunk_1.h("slot", null))));
    }
    get el() { return __chunk_1.getElement(this); }
}

exports.ema_route_link = RouteLink;
