"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.RatingBlock = RatingBlock;
const jsx_runtime_1 = require("react/jsx-runtime");
const cn_1 = require("../../../utils/cn.js");
const StarRating_1 = require("../StarRating/index.js");
require("./RatingBlock.css");
const b = (0, cn_1.block)('rating-block');
/**
 * RatingBlock - Universal rating block with title and star rating
 *
 * Can be used for customer satisfaction surveys (CSAT), product reviews,
 * article/video ratings, teacher evaluations, or any feedback collection.
 *
 * @example
 * ```tsx
 * <RatingBlock
 *   title="Rate the assistant response:"
 *   value={rating}
 *   onChange={setRating}
 *   size="l"
 * />
 * ```
 * @returns {JSX.Element} Rating block component
 */
function RatingBlock({ title, value, onChange, size = 'l', className, qa }) {
    return ((0, jsx_runtime_1.jsx)("div", { className: b(null, className), "data-qa": qa, children: (0, jsx_runtime_1.jsxs)("div", { className: b('header'), children: [(0, jsx_runtime_1.jsx)("div", { className: b('left'), children: title && (0, jsx_runtime_1.jsx)("div", { className: b('title'), children: title }) }), (0, jsx_runtime_1.jsx)("div", { className: b('right'), children: (0, jsx_runtime_1.jsx)(StarRating_1.StarRating, { value: value, onChange: onChange, size: size, qa: qa }) })] }) }));
}
//# sourceMappingURL=RatingBlock.js.map
