import{s}from"./chunk-LvLJmgfZ.js";import{u as n}from"./useEvent-D91BmmQi.js";import{t as c}from"./react-Bj1aDYRI.js";import{Or as f,x as d}from"./cells-CJLUCcQg.js";import"./react-dom-CSu739Rf.js";import{t as l}from"./compiler-runtime-B3qBwwSJ.js";import{t as u}from"./jsx-runtime-Blw4afVn.js";import"./fullscreen-CTDqNQr6.js";import"./dist-12S8I4CH.js";import"./cjs-D5tzp-Y6.js";import"./main-BNL5rxQw.js";import"./useNonce-CbdaHKzX.js";import"./dist-DcwTQG1A.js";import"./dist-DnjsPBRJ.js";import"./dist-BJZAIIze.js";import"./dist-aRc_dRed.js";import"./dist-CPjTeT8p.js";import"./session-BmukRjSi.js";import"./purify.es-CWmnYhGI.js";import{i as v,n as x,r as h}from"./floating-outline-DBlzcHYf.js";import{t as j}from"./empty-state-JOk_hLQe.js";var O=l();c();var p=s(u(),1),b=()=>{let t=(0,O.c)(7),{items:r}=n(d),o;t[0]===r?o=t[1]:(o=h(r),t[0]=r,t[1]=o);let{activeHeaderId:m,activeOccurrences:a}=v(o);if(r.length===0){let i;return t[2]===Symbol.for("react.memo_cache_sentinel")?(i=(0,p.jsx)(j,{title:"No outline found",description:"Add markdown headings to your notebook to create an outline.",icon:(0,p.jsx)(f,{})}),t[2]=i):i=t[2],i}let e;return t[3]!==m||t[4]!==a||t[5]!==r?(e=(0,p.jsx)(x,{items:r,activeHeaderId:m,activeOccurrences:a}),t[3]=m,t[4]=a,t[5]=r,t[6]=e):e=t[6],e};export{b as default};
