1import{_ as b}from"./5TdI7TNq.js";import{e as y,r as o,E as k,B as w,af as E,ai as z,k as B,c as p,a as C,m as H,V as R,n as t,N as f,b as T,w as N,o as v,d as S,t as L,aj as M}from"./Bcs_NwEm.js";import{_ as V}from"./DlAUqK2U.js";const q={class:"relative"},I=["innerHTML"],O=y({__name:"RichTextBlock",props:{content:{type:String,required:!0},height:{type:Number,required:!1,default:null},class:{type:String,required:!1,default:""},font:{type:String,required:!1,default:"font-sans"}},setup(m){const e=m,r=o(!1),l=o(!1),n=o(null),a=o(!1),s=o(!1);let i=null;const c=()=>{if(!n.value||!e.height||!a.value){l.value=!1;return}const d=n.value.scrollHeight,h=e.height+30;l.value=d>h,s.value||(s.value=!0)},g=()=>{r.value=!r.value},_=k(()=>e.height==null?{}:a.value?s.value&&(!l.value||r.value||!e.height)?{visibility:"visible",transition:"max-height 0.2s ease-out"}:{visibility:"visible",maxHeight:`${e.height+48}px`,overflow:"hidden",maskImage:"linear-gradient(to bottom, black 75%, transparent 100%)",WebkitMaskImage:"linear-gradient(to bottom, black 75%, transparent 100%)",transition:"max-height 0.2s ease-out"}:{visibility:"hidden",maxHeight:e.height?`${e.height+48}px`:"none",overflow:"hidden"}),u=E(c,100);return w(()=>{a.value=!0,setTimeout(()=>{c(),window.addEventListener("resize",u),typeof ResizeObserver<"u"&&n.value&&(i=new ResizeObserver(u),i.observe(n.value))},20)}),z(()=>{window.removeEventListener("resize",u),i&&(i.disconnect(),i=null)}),B(()=>[e.content,e.height,a.value],()=>{M(c)}),(d,h)=>{const x=b;return v(),p("div",q,[C("div",{ref_key:"contentRef",ref:n,class:f(["prose font-sans max-w-none",e.font,e.class]),style:R(t(_)),innerHTML:e.content},null,14,I),t(a)&&t(l)?(v(),p("div",{key:0,class:f(["text-right mt-2",{"opacity-0":!t(s),"opacity-100 transition-opacity duration-200":t(s)}])},[T(x,{type:"button",class:"ring-primary rounded-full text-xs text-secondary tracking-wide uppercase hover:bg-primary transition-all px-4 py-2",variant:"outline",onClick:g},{default:N(()=>[S(L(t(r)?"Show Less":"Read More"),1)]),_:1})],2)):H("",!0)])}}}),$=Object.assign(V(O,[["__scopeId","data-v-a8d65619"]]),{__name:"RichTextBlock"});export{$ as _};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.