"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index.cjs38.js"),m=require("react"),l=require("./index.cjs40.js"),e=require("./index.cjs55.js"),p=require("./index.cjs8.js"),o=require("./index.cjs9.js"),i=m.forwardRef(({items:n,activeId:c,title:a="Содержание",className:u,testId:d},x)=>n.length===0?null:s.jsxRuntimeExports.jsxs(p.Root,{ref:x,as:"nav",className:l(e.default.root,u),testId:d,"aria-label":a,children:[a&&s.jsxRuntimeExports.jsx(o.Typography,{variant:"overline",size:"sm",as:"h2",className:e.default.title,children:a}),s.jsxRuntimeExports.jsx("ol",{className:e.default.list,role:"list",children:n.map(t=>{const r=c===t.id,f=t.level??2;return s.jsxRuntimeExports.jsx("li",{className:l(e.default.item,e.default[`item--level${f}`]),children:s.jsxRuntimeExports.jsx("a",{href:t.href,className:l(e.default.link,r&&e.default["link--active"]),"aria-current":r?"location":void 0,children:s.jsxRuntimeExports.jsx(o.Typography,{variant:"body",size:"sm",color:r?"primary":"secondary",as:"span",className:e.default.linkText,children:t.label})})},t.id)})})]}));i.displayName="TableOfContents";exports.TableOfContents=i;
//# sourceMappingURL=index.cjs31.js.map
