import { Host, h } from "@stencil/core";
export class SpwCardSubtagItem {
    handleClick() {
        if (this.link) {
            window.location.href = this.link;
        }
    }
    get elementClass() {
        return {
            'spw-card-subtag-item': true,
            'spw-card-subtag-item--has-link': !!this.link,
        };
    }
    render() {
        return (h(Host, { key: 'b9cc69c396246f2312c714f9a92064051a2a7593' }, h("span", { key: '18ceda99d47d27ff2a465fde67d426590445d3d8', class: this.elementClass, onClick: () => this.handleClick() }, h("slot", { key: '332ea40deefbe4b854c4dbeb07eabbf0c964d61b' }))));
    }
    static get is() { return "spw-card-subtag-item"; }
    static get encapsulation() { return "shadow"; }
    static get originalStyleUrls() {
        return {
            "$": ["spw-card-subtag-item.scss"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["spw-card-subtag-item.css"]
        };
    }
    static get properties() {
        return {
            "link": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Lien qui m\u00E8ne vers la cat\u00E9gorie du sous-tag"
                },
                "getter": false,
                "setter": false,
                "reflect": false,
                "attribute": "link"
            }
        };
    }
}
