import { Host, h } from "@stencil/core";
export class CpslAvatar {
    constructor() {
        this.alt = undefined;
        this.src = undefined;
        this.size = undefined;
        this.variant = 'square';
    }
    render() {
        var _a;
        return (h(Host, { key: '58a67ffe4a40ece11edde2c8e20bbca8b3d16976' }, h("span", { key: '910593a08ccaa4cc45148e75b8e9368e82ddbbd1', class: { round: this.variant === 'round' }, style: this.size
                ? {
                    width: this.size,
                    height: this.size,
                }
                : {} }, h("img", { key: '8e0bed38daf1e45c30c83461cd68412efcd27083', src: this.src, alt: (_a = this.alt) !== null && _a !== void 0 ? _a : 'avatar' }))));
    }
    static get is() { return "cpsl-avatar"; }
    static get encapsulation() { return "shadow"; }
    static get originalStyleUrls() {
        return {
            "$": ["cpsl-avatar.scss"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["cpsl-avatar.css"]
        };
    }
    static get properties() {
        return {
            "alt": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "The alternate text for the avatar image."
                },
                "attribute": "alt",
                "reflect": false
            },
            "src": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": "The source of the avatar image."
                },
                "attribute": "src",
                "reflect": false
            },
            "size": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "The CSS width and height of the icon."
                },
                "attribute": "size",
                "reflect": false
            },
            "variant": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "'round' | 'square'",
                    "resolved": "\"round\" | \"square\"",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "The variant of the avatar.\nOptions are: `\"round\"`, `\"square\".\nDefault is: `\"square\"`."
                },
                "attribute": "variant",
                "reflect": false,
                "defaultValue": "'square'"
            }
        };
    }
}
//# sourceMappingURL=cpsl-avatar.js.map
