import { Host, h } from "@stencil/core";
export class CpslSpinner {
    constructor() {
        this.variant = 'pending';
        this.size = 54;
        this.barWidth = undefined;
        this.speed = 1;
    }
    render() {
        return (h(Host, { key: '6f5f4fa9dffa7e6dbc380bcdec5ae211447c4bf4', style: {
                ['--height']: `${this.size}px`,
                ['--width']: `${this.size}px`,
                ['--bar-width']: `${this.barWidth ? this.barWidth : this.size * 0.12}px`,
            } }, h("div", { key: '6035e38d3146fcda2b96181cc53b00b2c6d42c83', class: { loader: true, [this.variant]: true } })));
    }
    static get is() { return "cpsl-spinner"; }
    static get encapsulation() { return "shadow"; }
    static get originalStyleUrls() {
        return {
            "$": ["cpsl-spinner.scss"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["cpsl-spinner.css"]
        };
    }
    static get properties() {
        return {
            "variant": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "'idle' | 'pending' | 'error' | 'success'",
                    "resolved": "\"error\" | \"idle\" | \"pending\" | \"success\"",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Variant of the spinner\nDefault is 'pending'."
                },
                "attribute": "variant",
                "reflect": false,
                "defaultValue": "'pending'"
            },
            "size": {
                "type": "number",
                "mutable": false,
                "complexType": {
                    "original": "number",
                    "resolved": "number",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Size of the spinner in pixels.\nDefault is 50."
                },
                "attribute": "size",
                "reflect": false,
                "defaultValue": "54"
            },
            "barWidth": {
                "type": "number",
                "mutable": false,
                "complexType": {
                    "original": "number",
                    "resolved": "number",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Width of the spinner arc in pixels.\nDefault is 6.5."
                },
                "attribute": "bar-width",
                "reflect": false
            },
            "speed": {
                "type": "number",
                "mutable": false,
                "complexType": {
                    "original": "number",
                    "resolved": "number",
                    "references": {}
                },
                "required": false,
                "optional": true,
                "docs": {
                    "tags": [],
                    "text": "Rotation speed of the spinner in seconds.\nDefault is 1."
                },
                "attribute": "speed",
                "reflect": false,
                "defaultValue": "1"
            }
        };
    }
}
//# sourceMappingURL=cpsl-spinner.js.map
