import { h } from "@stencil/core";
/**
 * Divider 分割线组件
 * 区隔内容的分割线
 */
export class Divider {
    el;
    /** 分割线方向 */
    direction = 'horizontal';
    /** 文字位置 */
    contentPosition = 'center';
    /** 是否虚线 */
    dashed = false;
    render() {
        const hasContent = this.el.childNodes.length > 0;
        return (h("div", { key: '9c92e52f27cf63f9eb08f76204c0380df1f70762', class: {
                'hb-divider': true,
                [`hb-divider--${this.direction}`]: true,
                'hb-divider--dashed': this.dashed,
                'hb-divider--with-text': hasContent,
                [`hb-divider--with-text-${this.contentPosition}`]: hasContent,
            } }, h("div", { key: 'be7ed538cb7c11ecd5228456c70064b7a1134c22', class: "hb-divider__line hb-divider__line--before" }), h("div", { key: '381b60a6d74c9d595d23ba931f4de73a1479d45c', class: "hb-divider__text" }, h("slot", { key: '0bd08b0d41a9d2d4dad651e0c37a7e7fc10eab4c' })), h("div", { key: 'dd0774049f2b68b47f21c7171532f830d766c276', class: "hb-divider__line hb-divider__line--after" })));
    }
    static get is() { return "hb-divider"; }
    static get encapsulation() { return "shadow"; }
    static get originalStyleUrls() {
        return {
            "$": ["divider.css"]
        };
    }
    static get styleUrls() {
        return {
            "$": ["divider.css"]
        };
    }
    static get properties() {
        return {
            "direction": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "'horizontal' | 'vertical'",
                    "resolved": "\"horizontal\" | \"vertical\"",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": "\u5206\u5272\u7EBF\u65B9\u5411"
                },
                "getter": false,
                "setter": false,
                "attribute": "direction",
                "reflect": false,
                "defaultValue": "'horizontal'"
            },
            "contentPosition": {
                "type": "string",
                "mutable": false,
                "complexType": {
                    "original": "'left' | 'center' | 'right'",
                    "resolved": "\"center\" | \"left\" | \"right\"",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": "\u6587\u5B57\u4F4D\u7F6E"
                },
                "getter": false,
                "setter": false,
                "attribute": "content-position",
                "reflect": false,
                "defaultValue": "'center'"
            },
            "dashed": {
                "type": "boolean",
                "mutable": false,
                "complexType": {
                    "original": "boolean",
                    "resolved": "boolean",
                    "references": {}
                },
                "required": false,
                "optional": false,
                "docs": {
                    "tags": [],
                    "text": "\u662F\u5426\u865A\u7EBF"
                },
                "getter": false,
                "setter": false,
                "attribute": "dashed",
                "reflect": false,
                "defaultValue": "false"
            }
        };
    }
    static get elementRef() { return "el"; }
}
//# sourceMappingURL=Divider.js.map
