import { Host, h } from "@stencil/core";
import { cls } from "../../utils/helpers";
export class XMedia {
    constructor() {
        this.src = undefined;
        this.width = undefined;
        this.height = undefined;
        this.description = undefined;
        this.align = undefined;
        this.rounded = false;
    }
    /**
     * Render component
     */
    render() {
        return h(Host, { key: '104c39dc8c0a019e06a42328421268c9dc4dd767', class: cls({ 'media-rounded': this.rounded, 'media-right': this.align === 'right' }) }, this.src && h("img", { key: '0be5bda62dff3e1943e6d3f0b6be98e654db8827', style: {
                width: this.width,
                height: this.height
            }, src: this.src, alt: this.description, "aria-label": this.description }), h("div", { key: '993c1095867a52c6a6c73ec2bccd8d153f806a5e', class: "media-body" }, h("slot", { key: '5dc0a6a4f2c981e48aaa04468cecc1237a5661a0' })));
    }
    static get is() { return "x-media"; }
    static get originalStyleUrls() {
        return {
            "$": ["./style.scss"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["style.css"]
        };
    }
    static get properties() {
        return {
            "src": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": "Element media src url/path"
                },
                "attribute": "src",
                "reflect": false
            },
            "width": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Element CSS media width"
                },
                "attribute": "width",
                "reflect": false
            },
            "height": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Element CSS media height"
                },
                "attribute": "height",
                "reflect": false
            },
            "description": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "string",
                    "resolved": "string",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Element media description to aria/alt label"
                },
                "attribute": "description",
                "reflect": false
            },
            "align": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "MediaAlignType",
                    "resolved": "\"left\" | \"right\"",
                    "references": {
                        "MediaAlignType": {
                            "location": "local",
                            "path": "/opt/atlassian/pipelines/agent/build/src/components/x-media/component.tsx",
                            "id": "src/components/x-media/component.tsx::MediaAlignType"
                        }
                    }
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Element media align"
                },
                "attribute": "align",
                "reflect": false
            },
            "rounded": {
                "type": "boolean",
                "mutable": false,
                "complexType": {
                    "original": "boolean",
                    "resolved": "boolean",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Element media rounded style"
                },
                "attribute": "rounded",
                "reflect": false,
                "defaultValue": "false"
            }
        };
    }
}
