import { p as proxyCustomElement, H, c as createEvent, h, d as Host } from './p-a53686b3.js';
import { d as defineCustomElement$2 } from './p-6aa77536.js';
import { d as defineCustomElement$1 } from './p-9b37e59c.js';

const linkExternalCss = ".sc-digi-link-external-h{--digi--link-external--gap:var(--digi--gutter--medium);--digi--link-external--color--default:var(--digi--color--text--interactive--primary);--digi--link-external--color--hover:var(--digi--color--text--interactive--primary);--digi--link-external--color--visited:var(--digi--color--text--interactive--visited);--digi--link-external--font-size:var(--digi--typography--link--font-size--desktop);--digi--link-external--font-family:var(--digi--global--typography--font-family--default);--digi--link-external--font-weight:var(--digi--typography--link-bold--font-weight--desktop);--digi--link-external--text-decoration--default:var(--digi--global--typography--text-decoration--default);--digi--link-external--text-decoration--hover:var(--digi--typography--link--text-decoration--desktop);--digi--link-external--text-decoration--icon--default:var(--digi--global--typography--text-decoration--default);--digi--link-external--text-decoration--icon--hover:var(--digi--typography--link--text-decoration--desktop);--digi--link-external--text-decoration-thickness:0.156em;--digi--link-external--text-underline-offset:3px}.sc-digi-link-external-h .digi-link-external.sc-digi-link-external{--digi--link--gap:var(--digi--link-external--gap);--digi--link--color--default:var(--digi--link-external--color--default);--digi--link--color--hover:var(--digi--link-external--color--hover);--digi--link--color--visited:var(--digi--link-external--color--visited);--digi--link--font-size:var(--digi--link-external--font-size);--digi--link--font-family:var(--digi--link-external--font-family);--digi--link--font-weight:var(--digi--link-external--font-weight);--digi--link--text-decoration--default:var(--digi--link-external--text-decoration--default);--digi--link--text-decoration--hover:var(--digi--link-external--text-decoration--hover);--digi--link--text-decoration--icon--default:var(--digi--link-external--text-decoration--icon--default);--digi--link--text-decoration--icon--hover:var(--digi--link-external--text-decoration--icon--hover)}";
const DigiLinkExternalStyle0 = linkExternalCss;

const LinkExternal = /*@__PURE__*/ proxyCustomElement(class LinkExternal extends H {
    constructor() {
        super();
        this.__registerHost();
        this.afOnClick = createEvent(this, "afOnClick", 7);
        this.afHref = undefined;
        this.afDescribedby = undefined;
        this.afAriaLabel = undefined;
        this.afTarget = undefined;
        this.hideVisitedColor = undefined;
    }
    clickLinkHandler(e) {
        e.stopImmediatePropagation();
        this.afOnClick.emit(e.detail);
    }
    get cssModifiers() {
        return {
            'digi-link--hide-visited': this.hideVisitedColor
        };
    }
    render() {
        return (h(Host, { key: '6c080c10809f59a44ba7b6ddb3422097edc8ac4f' }, h("digi-link", { key: 'bb6e809911b5d664d86a24879f3911d4ce7fd69d', class: Object.assign({ 'digi-link-external': true }, this.cssModifiers), afHref: this.afHref, onAfOnClick: (e) => this.clickLinkHandler(e), afTarget: this.afTarget, afDescribedby: this.afDescribedby, afAriaLabel: this.afAriaLabel }, h("digi-icon-external-link-alt", { key: '43a515d70adc78ec4b67d4916f1aadeb4f2279a7', class: "digi-link-external__icon", "aria-hidden": "true", slot: "icon" }), h("slot", { key: 'f31becb5e56a50b3d578093a9388d3ffef21e889' }))));
    }
    get hostElement() { return this; }
    static get style() { return DigiLinkExternalStyle0; }
}, [6, "digi-link-external", {
        "afHref": [1, "af-href"],
        "afDescribedby": [1, "af-describedby"],
        "afAriaLabel": [1, "af-aria-label"],
        "afTarget": [1, "af-target"],
        "hideVisitedColor": [4, "hide-visited-color"]
    }]);
function defineCustomElement() {
    if (typeof customElements === "undefined") {
        return;
    }
    const components = ["digi-link-external", "digi-icon-external-link-alt", "digi-link"];
    components.forEach(tagName => { switch (tagName) {
        case "digi-link-external":
            if (!customElements.get(tagName)) {
                customElements.define(tagName, LinkExternal);
            }
            break;
        case "digi-icon-external-link-alt":
            if (!customElements.get(tagName)) {
                defineCustomElement$2();
            }
            break;
        case "digi-link":
            if (!customElements.get(tagName)) {
                defineCustomElement$1();
            }
            break;
    } });
}

export { LinkExternal as L, defineCustomElement as d };
