"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Disclaimer = Disclaimer;
const jsx_runtime_1 = require("react/jsx-runtime");
const uikit_1 = require("@gravity-ui/uikit");
const cn_1 = require("../../../utils/cn.js");
require("./Disclaimer.css");
const b = (0, cn_1.block)('disclaimer');
/**
 * Disclaimer component displays informational or warning messages
 *
 * @param props - Component props
 * @returns React component
 */
function Disclaimer(props) {
    const { className, qa, children, text, variant } = props;
    let textContent = null;
    if (text) {
        if (typeof text === 'string') {
            textContent = ((0, jsx_runtime_1.jsx)(uikit_1.Text, { color: "secondary", variant: variant, children: text }));
        }
        else {
            textContent = text;
        }
    }
    else {
        textContent = null;
    }
    return ((0, jsx_runtime_1.jsxs)("div", { className: b('container', className), "data-qa": qa, children: [textContent, children] }));
}
//# sourceMappingURL=Disclaimer.js.map
