UNPKG

openclaw

Version:

Multi-channel AI gateway with extensible messaging integrations

1 lines • 2.74 kB
import{n as e}from"./rolldown-runtime-CNOWq4Kh.js";import{C_ as t,GN as n,JN as r,Jw as i,XM as a,Yw as o,by as s,fN as c,pN as l,qN as u,w_ as d,yy as f}from"./_2_____________________________.js";import{C as p,K as m,O as h,Rt as g,U as _,d as v,f as y,g as b,j as x,l as S,m as C,u as w,x as T}from"./_6____________________.js";import{n as E,t as D}from"./chat-attachment-preview-chip-4QygB_YJ.js";function O(){let e=m(i);return f((e,t)=>{for(let n of[`scrollable`,`atStart`,`atEnd`])e.dataset[n]=String(t[n])},{presented:e})}function k(e){let t=O();var n=N(),i=n.firstChild,a=i.firstChild,o=a.nextSibling;return v(a,()=>r(`chat.messages.annotationSelectedText`)),v(o,()=>e.comment.text),v(i,x(h,{get when(){return e.comment.comment},get children(){return[(()=>{var e=j();return v(e,()=>r(`chat.messages.annotationUserComment`)),e})(),(()=>{var n=M();return C(()=>t,n),v(n,()=>e.comment.comment),S(()=>r(`chat.messages.annotationUserComment`),e=>{b(n,`aria-label`,e)}),n})()]}}),null),v(n,()=>e.children,null),n}function A(e){let t=O(),n=()=>r(e.count===1?`chat.messages.annotationCount`:`chat.messages.annotationsCount`,{count:String(e.count)}),i;var a=P(),o=a.firstChild;a.placement=`top`,a.autoSize=!0,a.describe=!1,a.openOnClick=!0;var s=e.previewRef;return typeof s==`function`||Array.isArray(s)?C(()=>s,a):e.previewRef=a,a._$owner=g(),v(a,x(D,{get label(){return x(p,{get each(){return n().split(/(\s+)/u)},children:e=>/^\s+$/u.test(e)?(()=>{var t=F();return v(t,e),t})():e})},get icon(){return x(c,{name:`messageSquare`})},get onReveal(){return e.onReveal},get onClick(){return e.onReveal},get elementRef(){return e.elementRef},get triggerRef(){return[e=>i=e,e.triggerRef]},get removal(){return y(()=>!!e.removal)()?{...e.removal,label:r(`chat.messages.removeAnnotations`)}:void 0}}),o),C(()=>t,o),v(o,()=>e.children),S(()=>({e:!!e.removal,t:e.removal?()=>i??null:void 0,a:e.removal?200:void 0,o:r(`chat.messages.annotations`)}),({e,t,a:n,o:r},i)=>{e!==i?.e&&a.classList.toggle(`chat-comment-preview--editable`,e),t!==i?.t&&(a.descriptionTarget=t),n!==i?.a&&(a.hoverDismissDelay=n),r!==i?.o&&b(o,`aria-label`,r)}),a}var j,M,N,P,F;function I(){return(I=e((()=>{w(),_(),l(),a(),t(),n(),s(),o(),E(),j=T(`<span class=muted>`),M=T(`<div class="chat-comment-preview__text chat-comment-preview__text--comment"tabindex=0 role=region>`),N=T(`<li class=chat-comment-preview__item><div class=chat-comment-preview__body><span class=muted></span><div class="chat-comment-preview__text chat-comment-preview__text--selection">`),P=T(`<openclaw-tooltip class=chat-comment-preview><div slot=content class=chat-comment-preview__scroll tabindex=0 role=region>`,1),F=T(`<span class=chat-comment-count-gap>`),u(d)})))()}export{k as n,I as r,A as t};