import { faArrowUpRightFromSquare } from "@fortawesome/free-solid-svg-icons";
import { h } from "@stencil/core";
import classNames from "classnames";
export class ExplorerLink {
    constructor() {
        this.hasSlotContent = false;
    }
    componentWillLoad() {
        this.hasSlotContent = !!this.hostElement.querySelector('[slot="content"]');
    }
    render() {
        var _a, _b;
        return (h("a", { key: 'bddd4e6e873db265f696fc655b29cbd673fc1bf2', "data-testid": this.dataTestId, href: this.link, target: "_blank", class: classNames(this.class, 'explorer-link'), rel: "noreferrer" }, this.hasSlotContent ? h("slot", { name: "content" }) : (_a = this.text) !== null && _a !== void 0 ? _a : h("fa-icon", { icon: (_b = this.icon) !== null && _b !== void 0 ? _b : faArrowUpRightFromSquare })));
    }
    static get is() { return "explorer-link"; }
    static get encapsulation() { return "shadow"; }
    static get originalStyleUrls() {
        return {
            "$": ["explorer-link.css"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["explorer-link.css"]
        };
    }
    static get properties() {
        return {
            "class": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false,
                "attribute": "class",
                "reflect": false
            },
            "dataTestId": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false,
                "attribute": "data-test-id",
                "reflect": false
            },
            "icon": {
                "type": "unknown",
                "mutable": false,
                "complexType": {
                    "original": "IconDefinition",
                    "resolved": "IconDefinition",
                    "references": {
                        "IconDefinition": {
                            "location": "import",
                            "path": "@fortawesome/free-solid-svg-icons",
                            "id": "node_modules::IconDefinition"
                        }
                    }
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false
            },
            "link": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false,
                "attribute": "link",
                "reflect": false
            },
            "text": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false,
                "attribute": "text",
                "reflect": false
            }
        };
    }
    static get states() {
        return {
            "hasSlotContent": {}
        };
    }
    static get elementRef() { return "hostElement"; }
}
//# sourceMappingURL=explorer-link.js.map
