"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const tslib_1 = require("tslib");
const jsx_runtime_1 = require("react/jsx-runtime");
const react_1 = require("react");
const utils_1 = require("../../utils/index.js");
const Link_1 = tslib_1.__importDefault(require("../Link/Link.js"));
const b = (0, utils_1.block)('links');
function getLinkSize(size) {
    switch (size) {
        case 's':
            return 'm';
        case 'l':
        default:
            return 'l';
    }
}
const Links = ({ className, titleId, links, size = 's', qa, linkQa }) => links ? ((0, jsx_runtime_1.jsx)("div", { className: b({ size }, className), "data-qa": qa, children: links?.map((link) => ((0, react_1.createElement)(Link_1.default, { className: b('link'), ...link, textSize: getLinkSize(size), key: link.url, qa: linkQa, extraProps: {
            'aria-describedby': link.urlTitle ? undefined : titleId,
            ...link.extraProps,
        } }))) })) : null;
exports.default = Links;
//# sourceMappingURL=Links.js.map
