import { Fragment, h } from "@stencil/core";
import { ProviderLabelsEnum, ProviderTypeEnum } from "../../../../../types/provider.types";
const providerButtonInfo = {
    [ProviderTypeEnum.extension]: {
        icon: h("mvx-extension-provider-icon", null),
        label: ProviderLabelsEnum.extension,
    },
    [ProviderTypeEnum.metamask]: {
        icon: h("mvx-metamask-provider-icon", null),
        label: ProviderLabelsEnum.metamask,
    },
    [ProviderTypeEnum.passkey]: {
        icon: h("mvx-passkey-provider-icon", null),
        label: ProviderLabelsEnum.passkey,
    },
    [ProviderTypeEnum.walletConnect]: {
        icon: h("mvx-multiversx-logo-icon", null),
        label: ProviderLabelsEnum.walletConnect,
    },
    [ProviderTypeEnum.ledger]: {
        icon: h("mvx-ledger-provider-icon", null),
        label: ProviderLabelsEnum.ledger,
    },
    [ProviderTypeEnum.crossWindow]: {
        icon: h("mvx-wallet-provider-icon", null),
        label: ProviderLabelsEnum.crossWindow,
    },
    [ProviderTypeEnum.xalias]: {
        icon: h("mvx-xalias-provider-icon", null),
        label: ProviderLabelsEnum.xalias,
    },
};
export class UnlockProviderButton {
    render() {
        const walletInfo = this.type ? providerButtonInfo[this.type] : null;
        if (!walletInfo) {
            return h(Fragment, null);
        }
        return h("mvx-unlock-button", { icon: walletInfo.icon, label: walletInfo.label, type: this.type, class: this.class });
    }
    static get is() { return "mvx-unlock-provider-button"; }
    static get encapsulation() { return "shadow"; }
    static get properties() {
        return {
            "type": {
                "type": "string",
                "attribute": "type",
                "mutable": false,
                "complexType": {
                    "original": "ProviderTypeEnum",
                    "resolved": "ProviderTypeEnum.crossWindow | ProviderTypeEnum.extension | ProviderTypeEnum.ledger | ProviderTypeEnum.metamask | ProviderTypeEnum.passkey | ProviderTypeEnum.walletConnect | ProviderTypeEnum.xalias",
                    "references": {
                        "ProviderTypeEnum": {
                            "location": "import",
                            "path": "types/provider.types",
                            "id": "src/types/provider.types.ts::ProviderTypeEnum"
                        }
                    }
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false,
                "reflect": false
            },
            "providers": {
                "type": "unknown",
                "attribute": "providers",
                "mutable": false,
                "complexType": {
                    "original": "string[]",
                    "resolved": "string[]",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false
            },
            "class": {
                "type": "string",
                "attribute": "class",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": ""
                },
                "getter": false,
                "setter": false,
                "reflect": false
            }
        };
    }
}
//# sourceMappingURL=unlock-provider-button.js.map
