(function (factory) {
    if (typeof module === "object" && typeof module.exports === "object") {
        var v = factory(require, exports);
        if (v !== undefined) module.exports = v;
    }
    else if (typeof define === "function" && define.amd) {
        define(["require", "exports", "tslib", "styled-components", "../utils/theme/getTheme", "../Pallette/themes", "./theme"], factory);
    }
})(function (require, exports) {
    "use strict";
    Object.defineProperty(exports, "__esModule", { value: true });
    exports.DividerComponent = void 0;
    var tslib_1 = require("tslib");
    var styled_components_1 = (0, tslib_1.__importStar)(require("styled-components"));
    var getTheme_1 = require("../utils/theme/getTheme");
    var themes_1 = require("../Pallette/themes");
    var theme_1 = require("./theme");
    var COMPONENT_NAME = "divider";
    exports.DividerComponent = styled_components_1.default.div.attrs(function (props) { return ({
        theme: (0, getTheme_1.getTheme)({
            theme: props.theme,
            componentName: COMPONENT_NAME,
            defaultTheme: theme_1.defaultThemeDivider
        })
    }); })(templateObject_9 || (templateObject_9 = (0, tslib_1.__makeTemplateObject)(["\n  display: flex;\n  align-items: center;\n  ", "\n  ", "\n\n  & > * {\n    width: max-content;\n    color: ", ";\n  }\n\n  &::before,\n  &::after {\n    content: \"\";\n    background: ", ";\n  }\n\n  ", "\n\n  ", "\n"], ["\n  display: flex;\n  align-items: center;\n  ", "\n  ", "\n\n  & > * {\n    width: max-content;\n    color: ", ";\n  }\n\n  &::before,\n  &::after {\n    content: \"\";\n    background: ", ";\n  }\n\n  ", "\n\n  ", "\n"])), function (_a) {
        var direction = _a.direction, width = _a.width, height = _a.height;
        return direction === "row"
            ? (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = (0, tslib_1.__makeTemplateObject)(["\n          width: ", ";\n          flex-direction: row;\n          gap: 8px;\n          &::before,\n          &::after {\n            height: 1px;\n          }\n        "], ["\n          width: ", ";\n          flex-direction: row;\n          gap: 8px;\n          &::before,\n          &::after {\n            height: 1px;\n          }\n        "])), width ? width : "100%") : (0, styled_components_1.css)(templateObject_2 || (templateObject_2 = (0, tslib_1.__makeTemplateObject)(["\n          height: ", ";\n          flex-direction: column;\n          gap: 2.4px;\n          &::before,\n          &::after {\n            width: 1px;\n          }\n        "], ["\n          height: ", ";\n          flex-direction: column;\n          gap: 2.4px;\n          &::before,\n          &::after {\n            width: 1px;\n          }\n        "])), height ? height : "100%");
    }, function (_a) {
        var isHasChildren = _a.isHasChildren;
        return !isHasChildren && (0, styled_components_1.css)(templateObject_3 || (templateObject_3 = (0, tslib_1.__makeTemplateObject)(["\n      gap: 0;\n    "], ["\n      gap: 0;\n    "])));
    }, function (_a) {
        var theme = _a.theme;
        return theme.components.divider.colorContent;
    }, function (_a) {
        var theme = _a.theme, status = _a.status;
        return theme.components.divider[status + "Background"];
    }, function (_a) {
        var direction = _a.direction;
        if (direction === "row") {
            return (0, styled_components_1.css)(templateObject_4 || (templateObject_4 = (0, tslib_1.__makeTemplateObject)(["\n        &::after {\n          border-radius: 0 4px 4px 0;\n        }\n        &::before {\n          border-radius: 4px 0 0 4px;\n        }\n      "], ["\n        &::after {\n          border-radius: 0 4px 4px 0;\n        }\n        &::before {\n          border-radius: 4px 0 0 4px;\n        }\n      "])));
        }
        return (0, styled_components_1.css)(templateObject_5 || (templateObject_5 = (0, tslib_1.__makeTemplateObject)(["\n      &::after {\n        border-radius: 0 0 4px 4px;\n      }\n      &::before {\n        border-radius: 4px 4px 0 0;\n      }\n    "], ["\n      &::after {\n        border-radius: 0 0 4px 4px;\n      }\n      &::before {\n        border-radius: 4px 4px 0 0;\n      }\n    "])));
    }, function (_a) {
        var align = _a.align, direction = _a.direction;
        switch (align) {
            case "left":
                return (0, styled_components_1.css)(templateObject_6 || (templateObject_6 = (0, tslib_1.__makeTemplateObject)(["\n          &::before {\n            ", "\n          }\n          &::after {\n            flex-grow: 1;\n          }\n        "], ["\n          &::before {\n            ", "\n          }\n          &::after {\n            flex-grow: 1;\n          }\n        "])), direction === "row" ? "width: 8px;" : "height: 8px;");
            case "right":
                return (0, styled_components_1.css)(templateObject_7 || (templateObject_7 = (0, tslib_1.__makeTemplateObject)(["\n          &::before {\n            flex-grow: 1;\n          }\n          &::after {\n            ", "\n          }\n        "], ["\n          &::before {\n            flex-grow: 1;\n          }\n          &::after {\n            ", "\n          }\n        "])), direction === "row" ? "width: 8px;" : "height: 8px;");
            default:
                return (0, styled_components_1.css)(templateObject_8 || (templateObject_8 = (0, tslib_1.__makeTemplateObject)(["\n          &::before,\n          &::after {\n            flex-grow: 1;\n          }\n        "], ["\n          &::before,\n          &::after {\n            flex-grow: 1;\n          }\n        "])));
        }
    });
    exports.DividerComponent.defaultProps = {
        theme: themes_1.LIGHT_THEME
    };
    var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9;
});
