UNPKG

@kaifronsdal/transcript-viewer

Version:

A web-based viewer for AI conversation transcripts with rollback support

2 lines (1 loc) 2.67 kB
import{b as B,h as T,a as M,E as q,G as H,H as Z,I as $,J as m,K as C,M as D,O as N,c as w,p as L,U as F,d as G,P as K,Q as z,R as y,S as J,T as R,V as E,W as Q,X as V,j as b,Y as W,Z as X,_ as k,k as x,$ as ee,a0 as re,a1 as se,a2 as ie,a3 as ae,a4 as te,a5 as fe,a6 as ne,a7 as U,a8 as I}from"./BcJau-i_.js";import{c as ue}from"./B1dCdCgo.js";function _e(r,i,[s,e]=[0,0]){T&&s===0&&M();var a=r,t=null,o=null,n=F,d=s>0?q:0,v=!1;const _=(u,l=!0)=>{v=!0,h(l,u)},h=(u,l)=>{if(n===(n=u))return;let c=!1;if(T&&e!==-1){if(s===0){const p=H(a);p===Z?e=0:p===$?e=1/0:(e=parseInt(p.substring(1)),e!==e&&(e=n?1/0:-1))}const g=e>s;!!n===g&&(a=m(),C(a),D(!1),c=!0,e=-1)}n?(t?N(t):l&&(t=w(()=>l(a))),o&&L(o,()=>{o=null})):(o?N(o):l&&(o=w(()=>l(a,[s+1,e]))),t&&L(t,()=>{t=null})),c&&D(!0)};B(()=>{v=!1,i(_),v||h(null,null)},d),T&&(a=G)}function Y(r,i){return r===i||(r==null?void 0:r[R])===i}function pe(r={},i,s,e){return K(()=>{var a,t;return z(()=>{a=t,t=[],y(()=>{r!==s(...t)&&(i(r,...t),a&&Y(s(...a),r)&&i(null,...a))})}),()=>{J(()=>{t&&Y(s(...t),r)&&i(null,...t)})}}),r}const le={get(r,i){let s=r.props.length;for(;s--;){let e=r.props[s];if(I(e)&&(e=e()),typeof e=="object"&&e!==null&&i in e)return e[i]}},set(r,i,s){let e=r.props.length;for(;e--;){let a=r.props[e];I(a)&&(a=a());const t=E(a,i);if(t&&t.set)return t.set(s),!0}return!1},getOwnPropertyDescriptor(r,i){let s=r.props.length;for(;s--;){let e=r.props[s];if(I(e)&&(e=e()),typeof e=="object"&&e!==null&&i in e){const a=E(e,i);return a&&!a.configurable&&(a.configurable=!0),a}}},has(r,i){if(i===R||i===U)return!1;for(let s of r.props)if(I(s)&&(s=s()),s!=null&&i in s)return!0;return!1},ownKeys(r){const i=[];for(let s of r.props)if(I(s)&&(s=s()),!!s){for(const e in s)i.includes(e)||i.push(e);for(const e of Object.getOwnPropertySymbols(s))i.includes(e)||i.push(e)}return i}};function ve(...r){return new Proxy({props:r},le)}function de(r,i,s,e){var A;var a=!ae||(s&te)!==0,t=(s&ie)!==0,o=(s&ne)!==0,n=e,d=!0,v=()=>(d&&(d=!1,n=o?y(e):e),n),_;if(t){var h=R in r||U in r;_=((A=E(r,i))==null?void 0:A.set)??(h&&i in r?f=>r[i]=f:void 0)}var u,l=!1;t?[u,l]=ue(()=>r[i]):u=r[i],u===void 0&&e!==void 0&&(u=v(),_&&(a&&Q(),_(u)));var c;if(a?c=()=>{var f=r[i];return f===void 0?v():(d=!0,f)}:c=()=>{var f=r[i];return f!==void 0&&(n=void 0),f===void 0?n:f},a&&(s&V)===0)return c;if(_){var g=r.$$legacy;return function(f,P){return arguments.length>0?((!a||!P||g||l)&&_(P?c():f),f):c()}}var p=!1,S=((s&fe)!==0?W:X)(()=>(p=!1,c()));t&&b(S);var j=re;return function(f,P){if(arguments.length>0){const O=P?b(S):a&&t?k(f):f;return x(S,O),p=!0,n!==void 0&&(n=O),f}return ee&&p||(j.f&se)!==0?S.v:b(S)}}export{pe as b,_e as i,de as p,ve as s};