"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.LineDecorator = void 0;
var react_1 = __importDefault(require("react"));
var classnames_1 = __importDefault(require("classnames"));
var Divider_1 = __importDefault(require("@mui/material/Divider"));
var styles_1 = require("./styles");
var LineDecorator = function (_a) {
    var _b, _c, _d;
    var className = _a.className, children = _a.children, plain = _a.plain, first = _a.first, last = _a.last, transparent = _a.transparent, divider = _a.divider;
    var styles = (0, styles_1.useStyles)();
    return (react_1.default.createElement("div", { className: (0, classnames_1.default)(className, styles.decorator) },
        react_1.default.createElement("div", { className: (0, classnames_1.default)(styles.lineBlock, (_b = {}, _b[styles.withLinePadding] = first, _b)) }, !transparent && (react_1.default.createElement(react_1.default.Fragment, null,
            react_1.default.createElement("div", { className: styles.noLine }),
            react_1.default.createElement("div", { className: (0, classnames_1.default)(styles.line, (_c = {}, _c[styles.plain] = plain, _c), (_d = {}, _d[styles.last] = last, _d)) })))),
        react_1.default.createElement("div", { className: styles.content },
            children,
            divider && react_1.default.createElement(Divider_1.default, { className: styles.rowDivider, light: true, variant: "inset" }))));
};
exports.LineDecorator = LineDecorator;
