pi-roundtable-web 0.25.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/README.md +145 -8
- package/dist/account-zk4efb87.css +102 -0
- package/dist/chunk-account-hw49gd0d.js +1 -0
- package/dist/chunk-action-menu-rm5cyqkj.js +1 -0
- package/dist/{chunk-agent-0pm9p3nn.js → chunk-agent-b017vswv.js} +1 -1
- package/dist/chunk-arranged-rooms-q5v3dm1r.js +1 -0
- package/dist/chunk-character-creator-5dxcvd16.js +1 -0
- package/dist/chunk-codeeditor-pyt09fwg.js +2 -0
- package/dist/chunk-confirm-521yqmta.js +1 -0
- package/dist/{chunk-connectors-anhghy3k.js → chunk-connectors-hrm06nx8.js} +1 -1
- package/dist/chunk-conversations-e26rrf01.js +1 -0
- package/dist/{chunk-drag-q4fx9b22.js → chunk-drag-v41gx2mc.js} +1 -1
- package/dist/{chunk-entry-he1embgp.js → chunk-entry-jxxb3ath.js} +1 -1
- package/dist/{chunk-folder-list-5cp8stna.js → chunk-folder-list-b97xk12b.js} +1 -1
- package/dist/chunk-folds-b8q7eags.js +1 -0
- package/dist/chunk-gate-8k61stsc.js +1 -0
- package/dist/chunk-group-scene-dx6wt19m.js +1 -0
- package/dist/chunk-group-table-e4jr8r3a.js +1 -0
- package/dist/chunk-host-state-g7e7c0k5.js +1 -0
- package/dist/chunk-host-ui-x7k6n07v.js +939 -0
- package/dist/{chunk-index-bvfqjh77.js → chunk-index-014rjv9k.js} +2 -2
- package/dist/{chunk-index-d5abvq7v.js → chunk-index-2d0kg096.js} +2 -2
- package/dist/chunk-index-2qd81wbx.js +2 -0
- package/dist/{chunk-index-9b1kt7qw.css → chunk-index-2stynxw6.css} +1 -1
- package/dist/{chunk-index-gpkzhq1g.js → chunk-index-459drsft.js} +2 -2
- package/dist/chunk-index-4mfj596y.js +2 -0
- package/dist/{chunk-index-18gxy79n.js → chunk-index-66nskrdj.js} +2 -2
- package/dist/chunk-index-awx6nnta.js +2 -0
- package/dist/chunk-index-bbsytycb.js +2 -0
- package/dist/chunk-index-c07p8k0x.js +4 -0
- package/dist/chunk-index-cq1e9xdz.js +2 -0
- package/dist/chunk-index-d1prgfbp.js +2 -0
- package/dist/chunk-index-dhpt8qr9.js +2 -0
- package/dist/chunk-index-e5sd30xy.js +2 -0
- package/dist/chunk-index-g351921r.js +1 -0
- package/dist/chunk-index-hby0ap91.js +2 -0
- package/dist/chunk-index-hssjbr1k.js +2 -0
- package/dist/chunk-index-k2qq1gdj.js +2 -0
- package/dist/chunk-index-ke9ynm0n.js +2 -0
- package/dist/{chunk-index-s681nny9.js → chunk-index-km40bhsz.js} +2 -2
- package/dist/chunk-index-kpscvg85.js +2 -0
- package/dist/chunk-index-m0d100mg.js +2 -0
- package/dist/chunk-index-mb72snk9.js +2 -0
- package/dist/chunk-index-mjqqver5.js +4 -0
- package/dist/{chunk-index-zfd00hwb.js → chunk-index-nqfkwkfp.js} +2 -2
- package/dist/chunk-index-nwqk447w.js +2 -0
- package/dist/{chunk-index-wmbmmrd4.js → chunk-index-pcfhpm8v.js} +4 -4
- package/dist/chunk-index-q8h8xzbm.js +2 -0
- package/dist/chunk-index-r5vszgfs.js +2 -0
- package/dist/{chunk-index-27qca4mr.js → chunk-index-rhtvcbsq.js} +2 -2
- package/dist/chunk-index-rjv7vrwd.js +13 -0
- package/dist/chunk-index-v23m38p6.js +50 -0
- package/dist/chunk-index-va0g7d88.js +1 -0
- package/dist/{chunk-index-krtk6nn2.js → chunk-index-wnjp6wv0.js} +2 -2
- package/dist/chunk-index-xgkd15n3.js +2 -0
- package/dist/{chunk-index-9jqcskb4.js → chunk-index-y8rnq8zf.js} +5 -5
- package/dist/chunk-index-z3k18atc.js +2 -0
- package/dist/chunk-lang-css-6bepqpnx.js +1 -0
- package/dist/{chunk-lang-dockerfile-d5mzxs60.js → chunk-lang-dockerfile-hrav55t7.js} +1 -1
- package/dist/{chunk-lang-go-830fmhba.js → chunk-lang-go-x9ahv6e5.js} +3 -3
- package/dist/chunk-lang-html-8jc72zt4.js +1 -0
- package/dist/chunk-lang-javascript-2p2qtbnf.js +1 -0
- package/dist/{chunk-lang-json-5eaarz7j.js → chunk-lang-json-hsemyd0r.js} +1 -1
- package/dist/chunk-lang-markdown-zkwb4c9n.js +6 -0
- package/dist/{chunk-lang-python-fjw84w10.js → chunk-lang-python-tewx7006.js} +2 -2
- package/dist/{chunk-lang-rust-5rbp2zdk.js → chunk-lang-rust-0ydx84s1.js} +1 -1
- package/dist/{chunk-lang-shell-vzagpym3.js → chunk-lang-shell-gq1tmdz4.js} +1 -1
- package/dist/{chunk-lang-sql-0c2w9c2y.js → chunk-lang-sql-xt1qyycg.js} +2 -2
- package/dist/{chunk-lang-toml-yr9fv6eb.js → chunk-lang-toml-0hamc5fc.js} +1 -1
- package/dist/chunk-lang-typescript-82xf7z2e.js +1 -0
- package/dist/{chunk-lang-xml-eze08p42.js → chunk-lang-xml-wf6h5pt2.js} +1 -1
- package/dist/{chunk-lang-yaml-c4b6ft3y.js → chunk-lang-yaml-7vk521h1.js} +1 -1
- package/dist/chunk-layout-actions-zh7bezk7.js +1 -0
- package/dist/{chunk-menu-items-jrwxycr1.js → chunk-menu-items-1n9qargb.js} +2 -2
- package/dist/chunk-notes-t15bh04m.js +1 -0
- package/dist/chunk-notice-bell-w3y0h0sr.js +1 -0
- package/dist/chunk-notices-fa3g7qze.js +1 -0
- package/dist/chunk-onboarding-34v3nr17.js +1 -0
- package/dist/chunk-overview-km5vq375.js +1 -0
- package/dist/chunk-palette-a8txdgd0.js +1 -0
- package/dist/chunk-placement-items-wgaxsbvs.js +1 -0
- package/dist/chunk-profile-ypxdbsk1.js +1 -0
- package/dist/chunk-prompt-history-wm9dsy6s.js +1 -0
- package/dist/chunk-prompts-7mhhq7zs.js +1 -0
- package/dist/chunk-room-confirms-t11a1gsw.js +1 -0
- package/dist/chunk-room-menu-2tm2xtfx.js +1 -0
- package/dist/chunk-rooms-menu-button-wxnsxjwc.js +1 -0
- package/dist/chunk-schedules-2ft6xxyw.js +1 -0
- package/dist/{chunk-seat-menu-jv4s7hmj.js → chunk-seat-menu-d3npdtx1.js} +1 -1
- package/dist/chunk-sheet-hosts-vngvp7wv.js +1 -0
- package/dist/chunk-skill-editor-65n2hsq4.js +8 -0
- package/dist/chunk-skills-shkdwes8.js +1 -0
- package/dist/chunk-switcher-list-g6hhmr1t.js +1 -0
- package/dist/chunk-table-1b6bsq2y.js +1 -0
- package/dist/chunk-table-seats-vy1qhdks.js +1 -0
- package/dist/{chunk-table2d-4sje1fr0.js → chunk-table2d-n26b7gd0.js} +1 -1
- package/dist/{chunk-table3d-h64skazp.js → chunk-table3d-8aysyf56.js} +12 -12
- package/dist/chunk-transcript-355faceq.js +1 -0
- package/dist/chunk-where-j5qdt8a4.js +1 -0
- package/dist/chunk-workspace-vrbs6zx1.js +1 -0
- package/dist/chunk-zh-tw-zeg600bk.js +1 -0
- package/dist/index.html +1 -1
- package/dist/sw.js +1 -1
- package/package.json +5 -4
- package/src/api-types.ts +301 -4
- package/src/app/app.ts +196 -32
- package/src/app/desk.ts +47 -22
- package/src/app/files.ts +73 -7
- package/src/app/presence.ts +2 -2
- package/src/app/protocol.ts +63 -1
- package/src/app/room-log.ts +141 -14
- package/src/app/routes.ts +124 -26
- package/src/app/socket.ts +309 -77
- package/src/app/sockets.ts +108 -20
- package/src/app/surface.ts +72 -36
- package/src/app/uploads.ts +33 -7
- package/src/auth/authenticator.ts +71 -8
- package/src/auth/next.ts +52 -0
- package/src/auth/oidc-pages.ts +60 -0
- package/src/auth/oidc.ts +611 -0
- package/src/auth/sessions.ts +193 -0
- package/src/authz.ts +172 -0
- package/src/console-api.ts +122 -25
- package/src/console-server.ts +70 -6
- package/src/gate.ts +90 -0
- package/src/host/access.ts +161 -0
- package/src/host/cards.ts +99 -0
- package/src/host/context.ts +141 -0
- package/src/host/forms.ts +237 -0
- package/src/host/frames.ts +342 -0
- package/src/host/host-app.ts +176 -0
- package/src/host/host-context.ts +49 -0
- package/src/host/host-routes.ts +363 -0
- package/src/host/pages.ts +266 -0
- package/src/host/reads.ts +155 -0
- package/src/host/retention.ts +41 -0
- package/src/host/room-views.ts +137 -0
- package/src/host/rooms-service.ts +414 -0
- package/src/host/stored-json.ts +13 -0
- package/src/host/views.ts +103 -0
- package/src/i18n/zh-tw.ts +132 -0
- package/src/notices/api.ts +43 -0
- package/src/notices/mount.ts +292 -0
- package/src/notices/service.ts +294 -0
- package/src/notices/store.ts +298 -0
- package/src/notices/urls.ts +38 -0
- package/src/onboarding/api.ts +32 -0
- package/src/onboarding/service.ts +149 -0
- package/src/onboarding/steps.ts +75 -0
- package/src/onboarding/waivers.ts +40 -0
- package/src/options.ts +498 -34
- package/src/profile/api.ts +175 -0
- package/src/profile/links.ts +162 -0
- package/src/push/api.ts +189 -52
- package/src/push/dispatch.ts +156 -0
- package/src/push/drain.ts +139 -0
- package/src/push/outbox.ts +218 -0
- package/src/push/prefs.ts +118 -0
- package/src/push/sender.ts +7 -2
- package/src/push/triggers.ts +56 -5
- package/src/push/vapid.ts +19 -0
- package/src/push/web-push-transport.ts +106 -0
- package/src/push-sender/index.ts +14 -0
- package/src/push-sender/run.ts +118 -0
- package/src/push-sender/session.ts +54 -0
- package/src/visitors.ts +94 -6
- package/src/web-app.ts +674 -0
- package/src/web-plugin.ts +268 -26
- package/dist/chunk-action-menu-qe839g4b.js +0 -1
- package/dist/chunk-arranged-rooms-enpfswmg.js +0 -1
- package/dist/chunk-character-creator-6yf29xwx.js +0 -1
- package/dist/chunk-codeeditor-gdbdg7rp.js +0 -2
- package/dist/chunk-confirm-xrw7d732.js +0 -1
- package/dist/chunk-conversations-ry228aes.js +0 -1
- package/dist/chunk-folds-hff104tk.js +0 -1
- package/dist/chunk-group-scene-h228jdat.js +0 -1
- package/dist/chunk-index-0p5h2kdz.js +0 -2
- package/dist/chunk-index-0pt08yd9.js +0 -1
- package/dist/chunk-index-12bw9yj8.js +0 -2
- package/dist/chunk-index-2ad17eh4.js +0 -2
- package/dist/chunk-index-31wh5twj.js +0 -52
- package/dist/chunk-index-4dy94pbz.js +0 -2
- package/dist/chunk-index-4ecjtdy8.js +0 -13
- package/dist/chunk-index-4v1b7ks9.js +0 -2
- package/dist/chunk-index-5d8yjj4m.js +0 -2
- package/dist/chunk-index-89ajmxh7.js +0 -2
- package/dist/chunk-index-b9ny4623.js +0 -2
- package/dist/chunk-index-e1dr6g10.js +0 -2
- package/dist/chunk-index-hk3xyy20.js +0 -2
- package/dist/chunk-index-jm23vn03.js +0 -4
- package/dist/chunk-index-k7gh0jvz.js +0 -2
- package/dist/chunk-index-ky42ev0b.js +0 -2
- package/dist/chunk-index-pa2yyqh0.js +0 -2
- package/dist/chunk-index-pcvt668q.js +0 -2
- package/dist/chunk-index-pqw27eye.js +0 -1
- package/dist/chunk-index-ymbjrsp6.js +0 -2
- package/dist/chunk-lang-css-t85r8rz0.js +0 -1
- package/dist/chunk-lang-html-n6jparge.js +0 -1
- package/dist/chunk-lang-javascript-xj00cp97.js +0 -1
- package/dist/chunk-lang-markdown-zxx8eke8.js +0 -6
- package/dist/chunk-lang-typescript-8f6yywt3.js +0 -1
- package/dist/chunk-layout-actions-bv0chj41.js +0 -1
- package/dist/chunk-notes-9b7pgqfe.js +0 -1
- package/dist/chunk-overview-8yw71esz.js +0 -1
- package/dist/chunk-palette-frms7axe.js +0 -1
- package/dist/chunk-placement-items-fvfy9m0y.js +0 -1
- package/dist/chunk-prompt-history-yrqehads.js +0 -1
- package/dist/chunk-prompts-g6609tqx.js +0 -1
- package/dist/chunk-room-confirms-0a2y0925.js +0 -1
- package/dist/chunk-room-menu-g11q97br.js +0 -1
- package/dist/chunk-rooms-menu-button-h9qge48n.js +0 -1
- package/dist/chunk-schedules-ezmacrbj.js +0 -1
- package/dist/chunk-sheet-hosts-b0azyfhb.js +0 -1
- package/dist/chunk-skill-editor-h6k6whwg.js +0 -8
- package/dist/chunk-skills-gqcfhq56.js +0 -1
- package/dist/chunk-switcher-list-mcpamqnj.js +0 -1
- package/dist/chunk-table-s8cde1xz.js +0 -1
- package/dist/chunk-table-seats-wqkjn8bc.js +0 -1
- package/dist/chunk-transcript-c59c6mpm.js +0 -1
- package/dist/chunk-workspace-0cyspkk4.js +0 -1
- package/dist/chunk-zh-tw-nc93jm10.js +0 -1
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{s,l,r,t,p,e,n,a,nr,H,M,d,h,b,m,It,lr,cr}from"./chunk-index-31wh5twj.js";import{re}from"./chunk-index-ky42ev0b.js";import{Se,bn,er}from"./chunk-index-12bw9yj8.js";import{Rt,ti,Ei,Ci,Ai}from"./chunk-index-ymbjrsp6.js";import{pe}from"./chunk-index-b9ny4623.js";import{Ar,Ne,Li}from"./chunk-index-0p5h2kdz.js";import{Et,Ot,gt}from"./chunk-index-gpkzhq1g.js";var f=(o,i,u)=>b(o,{method:i,...u===void 0?{}:{body:JSON.stringify(u)}}),g=(o)=>encodeURIComponent(o),ye={createAgent:(o)=>f("agents","POST",o),archiveAgent:(o)=>f(`agents/${g(o)}/archive`,"POST"),restoreAgent:(o)=>f(`agents/${g(o)}/restore`,"POST"),deleteAgent:(o)=>f(`agents/${g(o)}`,"DELETE"),skills:(o)=>b(`agents/${g(o)}/skills`),setSkills:(o,i)=>f(`agents/${g(o)}/skills`,"PUT",i),archive:()=>b("archive"),createGroup:(o)=>f("groups","POST",o),group:(o)=>b(`groups/${g(o)}`),updateGroup:(o,i)=>f(`groups/${g(o)}`,"PATCH",i),archiveGroup:(o)=>f(`groups/${g(o)}/archive`,"POST"),restoreGroup:(o)=>f(`groups/${g(o)}/restore`,"POST"),deleteGroup:(o)=>f(`groups/${g(o)}`,"DELETE")};async function rt(){let o=await m.rooms();M.dispatch({type:"rooms_loaded",rooms:o.rooms})}function T(o){let{room:i}=o,u=d((c)=>{let N=Et(c,(y)=>gt(c,y)),k=Ot(N,i),A=k.kind==="rest"?[]:k.siblings;return{name:c.rooms[i]?.view?.displayName??i,folder:k.kind==="folder"?k.folder:"",pinned:k.kind==="pinned",canUp:Ne(A,i,"up")!==void 0,canDown:Ne(A,i,"down")!==void 0}},i),v=d((c)=>c.folders),C=(c)=>{o.onClose(),Rt(i,c)},w=u.folder===""&&!u.pinned;return n("div",{className:"stack",children:[e("p",{className:"meta",children:u.name}),n("fieldset",{children:[e("legend",{className:"visually-hidden",children:t("Move to folder…")}),n("ul",{className:"menu",children:[e("li",{children:n("label",{className:"menu-item menu-link",children:[e("input",{type:"radio",name:"move-folder",checked:w,onChange:()=>C(null)}),e("span",{className:"menu-icon",children:e(a,{name:"rooms",size:18})}),e("span",{className:"menu-text",children:e("strong",{children:t("Ungrouped")})})]})}),v.map((c)=>e("li",{children:n("label",{className:"menu-item menu-link",children:[e("input",{type:"radio",name:"move-folder",checked:u.folder===c.id,onChange:()=>C(c.id)}),e("span",{className:"menu-icon",children:e(a,{name:"folder",size:18})}),e("span",{className:"menu-text",children:e("strong",{children:c.name})})]})},c.id)),e("li",{children:n("button",{type:"button",className:"menu-item menu-link",onClick:()=>Se({kind:"new",room:i}),children:[e("span",{className:"menu-icon",children:e(a,{name:"plus",size:18})}),e("span",{className:"menu-text",children:e("strong",{children:t("New folder…")})})]})})]})]}),u.canUp||u.canDown?n("ul",{className:"menu",children:[u.canUp?e("li",{children:n("button",{type:"button",className:"menu-item menu-link",onClick:()=>{o.onClose(),ti(i,"up")},children:[e("span",{className:"menu-icon",children:e(a,{name:"up",size:18})}),e("span",{className:"menu-text",children:e("strong",{children:t("Move up")})})]})}):null,u.canDown?e("li",{children:n("button",{type:"button",className:"menu-item menu-link",onClick:()=>{o.onClose(),ti(i,"down")},children:[e("span",{className:"menu-icon",children:e(a,{name:"down",size:18})}),e("span",{className:"menu-text",children:e("strong",{children:t("Move down")})})]})}):null]}):null]})}function D(o){return e(pe,{open:o.open,title:t("Move to folder…"),onClose:o.onClose,children:e(T,{room:o.room,onClose:o.onClose})})}function E(o){let{ask:i}=o,[u,v]=r(i.kind==="rename"?i.name:""),[C,w]=r(),[c,N]=r(!1),k=l(null);return s(()=>k.current?.focus(),[]),n("form",{className:"stack",onSubmit:async(y)=>{y.preventDefault();let F;try{F=Li(u)}catch{w(t("Give the folder a name of 1 to 40 characters."));return}N(!0),w(void 0);let S;if(i.kind==="rename")S=await Ci(i.id,F,w)!==void 0;else{let P=await Ei(F,w);if(S=P!==void 0,P&&i.room)await Rt(i.room,P)}if(N(!1),S)o.onClose()},children:[n("div",{className:"field",children:[e("label",{className:"field-label",htmlFor:"folder-name",children:t("Folder name")}),e("input",{id:"folder-name",type:"text",ref:k,value:u,autoComplete:"off",enterKeyHint:"done",maxLength:Ar*2,"aria-invalid":C?!0:void 0,onChange:(y)=>v(y.target.value)}),C?e("p",{className:"field-error",role:"alert",children:C}):null]}),n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",disabled:c,onClick:o.onClose,children:t("Cancel")}),e("button",{type:"submit",disabled:c,children:i.kind==="rename"?t("Rename"):t("Create")})]})]})}function R(){let o=er(),i=l(void 0);if(o)i.current=o;let u=i.current;if(!u)return null;let v=u.kind==="new"||u.kind==="rename";return n(p,{children:[v?e(pe,{open:o?.kind==="new"||o?.kind==="rename",title:u.kind==="rename"?t("Rename folder"):t("Add a folder"),onClose:bn,children:e(E,{ask:u,onClose:bn})}):null,u.kind==="delete"?e(re,{open:o?.kind==="delete",title:t("Delete folder"),confirmLabel:t("Delete folder"),tone:"danger",onClose:bn,onConfirm:async()=>{let C="";if(!await Ai(u.id,(c)=>{C=c}))throw Error(C)},children:e("p",{children:t("Delete the folder {name}? Its rooms move to Ungrouped; no room is deleted.",{name:u.name})})}):null,u.kind==="move"?e(D,{open:o?.kind==="move",room:u.room,onClose:bn}):null]})}function G(o){return n(re,{open:o.open,title:t("Turn on yolo mode?"),confirmLabel:t("Turn on yolo mode"),tone:"yolo",...o.restoreFocus?{restoreFocus:o.restoreFocus}:{},onClose:o.onClose,onConfirm:async()=>{await m.setMode(o.room,{yolo:!0})},children:[e("p",{children:t("In this room, the agent's held actions are approved for you, without a card, as soon as they come up.")}),e("p",{children:t("Risky classes still ask: running as another user, deleting files, force pushes, disk, service and firewall changes, and anything that names its own approvers. The host can add more.")}),e("p",{children:t("Every approval it makes is written into the conversation, and a banner stays up while yolo mode is on.")})]})}function x(o){return e(re,{open:o.open,title:t("Start over {name}?",{name:o.name}),confirmLabel:t("Start over"),tone:"danger",...o.restoreFocus?{restoreFocus:o.restoreFocus}:{},onClose:o.onClose,onConfirm:async()=>{await m.startRoomOver(o.room)},children:e("p",{children:t("The current conversation is archived and the next message begins a new one. Long-term memory is kept. A turn that is running finishes first.")})})}function O(o){return e(re,{open:o.open,title:t("Archive {name}?",{name:o.name}),confirmLabel:t("Archive"),tone:"danger",...o.restoreFocus?{restoreFocus:o.restoreFocus}:{},onClose:o.onClose,onConfirm:async()=>{let i=o.room.indexOf("."),u=o.room.slice(i+1);if(o.room.slice(0,i).endsWith(":group"))await ye.archiveGroup(u);else await ye.archiveAgent(u);if(It(),await rt(),h(t("Archived {name}.",{name:o.name})),nr().key===o.room)H("rooms")},children:e("p",{children:t("{name} stops answering and its schedules are cancelled. A group loses it as a member. The history is kept, and Archived in the room list restores it.",{name:o.name})})})}function oi(){return n(p,{children:[e(V,{}),e(R,{})]})}function V(){let o=cr(),i=l(void 0);if(o)i.current=o;let u=i.current;if(!u)return null;let v={room:u.room,name:u.name,restoreFocus:u.restoreFocus,onClose:lr};return n(p,{children:[e(G,{open:o?.kind==="yolo",...v}),e(x,{open:o?.kind==="start-over",...v}),e(O,{open:o?.kind==="archive",...v})]})}
|
|
2
|
-
export{ye,rt,oi};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{Y,s,l,t,e,n,a,He}from"./chunk-index-31wh5twj.js";var C=96,S=0.6,T=220,w=()=>typeof matchMedia==="function"&&matchMedia("(max-width: 719px)").matches;function N(o){let u=l(null),g=l(void 0),{open:h,onClose:P}=o,E=l(o.restoreFocus);E.current=o.restoreFocus;let m=l(!1),p=l(!1),M=Y(()=>{let r=u.current;if(r?.open)r.close();if(E.current?.()?.focus(),m.current=!1,p.current)p.current=!1;else P()},[P]),d=Y(()=>{let r=u.current;if(!r||m.current)return;if(m.current=!0,He()){M();return}r.dataset.state="closing",r.style.removeProperty("transform"),setTimeout(M,T)},[M]);s(()=>{let r=u.current;if(!r)return;if(h&&!r.open)r.dataset.state="opening",r.showModal(),requestAnimationFrame(()=>requestAnimationFrame(()=>{r.dataset.state="open"}));if(!h&&r.open&&!m.current)p.current=!0,d()},[h,d]);let b=(r)=>{if(!w())return;if(r.target instanceof Element&&r.target.closest("button, a"))return;g.current={y:r.clientY,at:r.timeStamp,dy:0},r.currentTarget.setPointerCapture(r.pointerId);let i=u.current;if(i)i.dataset.dragging="true"},v=(r)=>{let i=g.current,c=u.current;if(!i||!c)return;let f=Math.max(0,r.clientY-i.y);i.dy=f,c.style.transform=`translate3d(0, ${f}px, 0)`,c.style.setProperty("--sheet-progress",String(1-Math.min(1,f/400)))},y=(r)=>{let i=g.current,c=u.current;if(g.current=void 0,!i||!c)return;delete c.dataset.dragging;let f=i.dy/Math.max(1,r.timeStamp-i.at);if(i.dy>C||f>S){d();return}c.style.removeProperty("transform"),c.style.removeProperty("--sheet-progress")};return n("dialog",{ref:u,className:o.variant==="palette"?"sheet palette":o.size==="wide"?"sheet wide":o.size==="full"?"sheet full":"sheet","aria-label":o.title,onCancel:(r)=>{if(r.target!==r.currentTarget)return;r.preventDefault(),d()},onClick:(r)=>{if(r.target===r.currentTarget)d()},onClose:(r)=>{if(r.target!==r.currentTarget)return;if(!m.current)P()},children:[e("div",{className:"sheet-grab",onPointerDown:b,onPointerMove:v,onPointerUp:y,onPointerCancel:y,children:e("span",{className:"sheet-handle"})}),o.variant==="palette"?null:n("div",{className:"sheet-head",onPointerDown:b,onPointerMove:v,onPointerUp:y,onPointerCancel:y,children:[e("h2",{title:o.title,children:o.title}),e("button",{type:"button",className:"icon-button","aria-label":t("Close"),onClick:d,children:e(a,{name:"close"})})]}),e("div",{className:"sheet-body",children:h?o.children:null})]})}
|
|
2
|
-
export{N};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{Se}from"./chunk-index-12bw9yj8.js";import{t,Oe,hr,Pn}from"./chunk-index-31wh5twj.js";function yn(e){let n=e.getBoundingClientRect(),o=hr();Oe({title:t("Rooms"),items:[{id:"new-folder",label:t("Add a folder"),icon:"plus",run:()=>Se({kind:"new"})},{id:"arrange",label:o?t("Done"):t("Arrange"),icon:o?"check":"list",run:()=>Pn(!o)}],at:{x:n.left,y:n.bottom},via:"key",source:e})}
|
|
2
|
-
export{yn};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{rn}from"./chunk-index-0p5h2kdz.js";var f=12;function m(r,e){let t=r.find((u)=>e>=u.top&&e<=u.bottom);if(t)return t;let n,o=f+1;for(let u of r){let i=e<u.top?u.top-e:e-u.bottom;if(i<o)n=u,o=i}return n}function d(r,e,t){for(let n of r)if(n.key!==e&&n.top+n.height/2>t)return n.key;return null}function Qr(r,e,t){let n=m(r,t);return n?{zone:n,before:d(n.items,e,t)}:void 0}function Mr(r,e,t){let{zone:n,before:o}=t;if(n.kind==="rest")return r.kind==="rest"?void 0:{kind:"unplace"};if(n.kind==="pinned"&&r.kind==="pinned"||n.kind==="folder"&&r.kind==="folder"&&r.folder===n.folder){let i=r.siblings;if(rn(i,e,o).every((s,l)=>s===i[l]))return}return n.kind==="pinned"?{kind:"pin",before:o}:{kind:"folder",folder:n.folder,before:o}}function Rr(r,e,t,n){if(n<e.top-f*3||n>e.bottom+f*3)return;return{before:d(r,t,n)}}function $i(r,e,t,n=0){let o=(r[e]?.height??0)+n;return r.map((u,i)=>{if(i===e)return 0;if(e<t&&i>e&&i<=t)return-o;if(e>t&&i>=t&&i<e)return o;return 0})}function Ni(r,e,t){return rn(r,e,t).indexOf(e)}function Er(r,e,t,n=64,o=18){if(r<e+n)return-Math.min(1,(e+n-r)/n)*o;if(r>t-n)return Math.min(1,(r-(t-n))/n)*o;return 0}var Cr=600;
|
|
2
|
-
export{Qr,Mr,Rr,$i,Ni,Er,Cr};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{s,r,f,se}from"./chunk-index-31wh5twj.js";function fe(o,e){let{version:u}=se(),[t,a]=r({data:void 0,error:void 0,subject:e});return s(()=>{let n=!0;return o().then((d)=>{if(n)a({data:d,error:void 0,subject:e})},(d)=>{if(n)a((i)=>({data:i.subject===e?i.data:void 0,error:f(d),subject:e}))}),()=>{n=!1}},[e,u]),t.subject===e?{data:t.data,error:t.error}:{data:void 0,error:void 0}}
|
|
2
|
-
export{fe};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import{X,t,e,n,b}from"./chunk-index-31wh5twj.js";var k=(i,s,r)=>b(i,{method:s,...r===void 0?{}:{body:JSON.stringify(r)}}),c=(i)=>encodeURIComponent(i),ke={agentPromptHistory:(i)=>b(`agents/${c(i)}/prompt-history`),prompts:()=>b("prompts"),prompt:(i)=>b(`prompts/${c(i)}`),savePrompt:(i,s)=>k(`prompts/${c(i)}`,"PUT",s),revertPrompt:(i,s)=>k(`prompts/${c(i)}/revert`,"POST",s),promptHistory:(i)=>b(`prompts/${c(i)}/history`),skillDocument:(i)=>b(`skill-docs/${c(i)}`),saveSkillDocument:(i,s)=>k(`skill-docs/${c(i)}`,"PUT",s),createSkillDocument:(i)=>k("skill-docs","POST",i),skillHistory:(i)=>b(`skill-docs/${c(i)}/history`)};function u(i,s){let r=i.split(`
|
|
2
|
-
`),m=s.split(`
|
|
3
|
-
`),o=0;while(o<r.length&&o<m.length&&r[o]===m[o])o++;let d=0;while(d<r.length-o&&d<m.length-o&&r[r.length-1-d]===m[m.length-1-d])d++;let g=r.slice(o,r.length-d),p=m.slice(o,m.length-d),a=r.slice(0,o).map((l)=>({kind:"same",text:l}));return a.push(...D(g,p)),a.push(...r.slice(r.length-d).map((l)=>({kind:"same",text:l}))),a}function D(i,s){let r=(l)=>l.map((f)=>({kind:"del",text:f})),m=(l)=>l.map((f)=>({kind:"add",text:f}));if(i.length===0)return m(s);if(s.length===0)return r(i);if(i.length*s.length>4000000)return[...r(i),...m(s)];let o=s.length+1,d=new Uint32Array((i.length+1)*o);for(let l=i.length-1;l>=0;l--)for(let f=s.length-1;f>=0;f--)d[l*o+f]=i[l]===s[f]?(d[(l+1)*o+f+1]??0)+1:Math.max(d[(l+1)*o+f]??0,d[l*o+f+1]??0);let g=[],p=0,a=0;while(p<i.length&&a<s.length)if(i[p]===s[a])g.push({kind:"same",text:i[p]}),p++,a++;else if((d[(p+1)*o+a]??0)>=(d[p*o+a+1]??0))g.push({kind:"del",text:i[p]}),p++;else g.push({kind:"add",text:s[a]}),a++;return g.push(...r(i.slice(p)),...m(s.slice(a))),g}function h(i){return{added:i.filter((s)=>s.kind==="add").length,removed:i.filter((s)=>s.kind==="del").length}}var v={same:" ",add:"+",del:"−"};function y({lines:i}){return e("pre",{className:"diff",children:i.map((s,r)=>n("span",{className:"diff-line","data-kind":s.kind,children:[e("span",{className:"diff-mark","aria-hidden":"true",children:v[s.kind]}),s.kind==="add"||s.kind==="del"?n("span",{className:"visually-hidden",children:[s.kind==="add"?t("Added"):t("Removed"),":"," "]}):null,s.text||" "]},r))})}function We(i){let s=X(()=>u(i.before,i.after),[i.before,i.after]),r=h(s);return n("div",{className:"field",children:[n("span",{className:"field-label",children:[i.label," ·"," ",t("Lines: {added} added, {removed} removed",{added:r.added,removed:r.removed})]}),e(y,{lines:s})]})}
|
|
4
|
-
export{ke,We};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{O,t,M}from"./chunk-index-31wh5twj.js";import{Se}from"./chunk-index-12bw9yj8.js";import{Ne}from"./chunk-index-0p5h2kdz.js";import{Ot,En,Gt}from"./chunk-index-gpkzhq1g.js";var s=(e)=>e(),d=()=>(O("bv0chj41"),import("./chunk-layout-actions-bv0chj41.js"));function pi(e,u=s){let o=Ot(Gt(),e),l=o.kind==="pinned",i=[{id:"pin",label:l?t("Unpin"):t("Pin"),icon:"pin",run:()=>{d().then((r)=>r.pinRoom(e,!l))}},{id:"move",label:t("Move to folder…"),icon:"folder",run:()=>u(()=>Se({kind:"move",room:e}))}];if(o.kind==="rest")return i;if(Ne(o.siblings,e,"up"))i.push({id:"up",label:t("Move up"),icon:"up",run:()=>{d().then((r)=>r.nudgeRoom(e,"up"))}});if(Ne(o.siblings,e,"down"))i.push({id:"down",label:t("Move down"),icon:"down",run:()=>{d().then((r)=>r.nudgeRoom(e,"down"))}});return i}function Gr(e){let u=M.getState(),o=u.folders.find((n)=>n.id===e);if(!o)return;let l=Gt().folders.find((n)=>n.id===e)?.rooms??[],i=En(l,(n)=>u.rooms[n]?.view?.muted===!0)==="all",r=u.folders.map((n)=>n.id),m=[{id:"rename",label:t("Rename"),icon:"edit",run:()=>Se({kind:"rename",id:e,name:o.name})}];if(l.length>0)m.push({id:"mute",label:i?t("Unmute the whole folder"):t("Mute the whole folder"),icon:i?"bell":"bell-off",run:()=>{d().then((n)=>n.muteFolder(e,!i))}});if(Ne(r,e,"up"))m.push({id:"up",label:t("Move up"),icon:"up",run:()=>{d().then((n)=>n.nudgeFolder(e,"up"))}});if(Ne(r,e,"down"))m.push({id:"down",label:t("Move down"),icon:"down",run:()=>{d().then((n)=>n.nudgeFolder(e,"down"))}});return m.push({id:"delete",label:t("Delete folder"),icon:"trash",tone:"danger",run:()=>Se({kind:"delete",id:e,name:o.name})}),{title:o.name,items:m}}
|
|
2
|
-
export{pi,Gr};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r,t,e,n,y,f}from"./chunk-index-31wh5twj.js";import{N}from"./chunk-index-5d8yjj4m.js";function re(o){let[a,l]=r(!1),[s,i]=r(),c=()=>{if(a)return;i(void 0),o.onClose()};return e(N,{open:o.open,title:o.title,onClose:c,...o.restoreFocus?{restoreFocus:o.restoreFocus}:{},children:n("div",{className:"stack",children:[e("div",{className:"prose",children:o.children}),s?e(y,{message:s}):null,n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",disabled:a,onClick:c,children:o.cancelLabel??t("Cancel")}),e("button",{type:"button",className:o.tone==="danger"?"danger":o.tone==="yolo"?"yolo-action":"",disabled:a,onClick:async()=>{l(!0),i(void 0);try{await o.onConfirm(),o.onClose()}catch(d){i(f(d))}finally{l(!1)}},children:o.confirmLabel})]})]})})}
|
|
2
|
-
export{re};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{z,be,o,g,ve,Pe,Qe,U,te,Ge,vt,k,u,ot,T,Xe}from"./chunk-index-4ecjtdy8.js";class ai{constructor(t,e,i,n){this.state=t,this.pos=e,this.explicit=i,this.view=n,this.abortListeners=[],this.abortOnDocChange=!1}tokenBefore(t){let e=T(this.state).resolveInner(this.pos,-1);while(e&&t.indexOf(e.name)<0)e=e.parent;return e?{from:e.from,to:this.pos,text:this.state.sliceDoc(e.from,this.pos),type:e.type}:null}matchBefore(t){let e=this.state.doc.lineAt(this.pos),i=Math.max(e.from,this.pos-250),n=e.text.slice(i-e.from,this.pos-e.from),s=n.search(D(t,!1));return s<0?null:{from:i+s,to:this.pos,text:n.slice(s)}}get aborted(){return this.abortListeners==null}addEventListener(t,e,i){if(t=="abort"&&this.abortListeners){if(this.abortListeners.push(e),i&&i.onDocChange)this.abortOnDocChange=!0}}}function v(t){let e=Object.keys(t).join(""),i=/\w/.test(e);if(i)e=e.replace(/\w/g,"");return`[${i?"\\w":""}${e.replace(/[^\w\s]/g,"\\$&")}]`}function E(t){let e=Object.create(null),i=Object.create(null);for(let{label:s}of t){e[s[0]]=!0;for(let l=1;l<s.length;l++)i[s[l]]=!0}let n=v(e)+v(i)+"*$";return[new RegExp("^"+n),new RegExp(n)]}function Ve(t){let e=t.map((s)=>typeof s=="string"?{label:s}:s),[i,n]=e.every((s)=>/^\w+$/.test(s.label))?[/\w*$/,/\w+$/]:E(e);return(s)=>{let l=s.matchBefore(n);return l||s.explicit?{from:l?l.from:s.pos,options:e,validFor:i}:null}}function Be(t,e){return(i)=>{for(let n=T(i.state).resolveInner(i.pos,-1);n;n=n.parent){if(t.indexOf(n.name)>-1)return null;if(n.type.isTop)break}return e(i)}}function D(t,e){var i;let{source:n}=t,s=e&&n[0]!="^",l=n[n.length-1]!="$";if(!s&&!l)return t;return new RegExp(`${s?"^":""}(?:${n})${l?"$":""}`,(i=t.flags)!==null&&i!==void 0?i:t.ignoreCase?"i":"")}var P=Qe.define();var re=typeof navigator=="object"&&/Win/.test(navigator.platform);var L=u.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:0.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"···"',opacity:0.5,display:"block",textAlign:"center",cursor:"pointer"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'ƒ'"}},".cm-completionIcon-class":{"&:after":{content:"'○'"}},".cm-completionIcon-interface":{"&:after":{content:"'◌'"}},".cm-completionIcon-variable":{"&:after":{content:"'\uD835\uDC65'"}},".cm-completionIcon-constant":{"&:after":{content:"'\uD835\uDC36'"}},".cm-completionIcon-type":{"&:after":{content:"'\uD835\uDC61'"}},".cm-completionIcon-enum":{"&:after":{content:"'∪'"}},".cm-completionIcon-property":{"&:after":{content:"'□'"}},".cm-completionIcon-keyword":{"&:after":{content:"'\uD83D\uDD11︎'"}},".cm-completionIcon-namespace":{"&:after":{content:"'▢'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}});class I{constructor(t,e,i,n){this.field=t,this.line=e,this.from=i,this.to=n}}class b{constructor(t,e,i){this.field=t,this.from=e,this.to=i}map(t){let e=t.mapPos(this.from,-1,be.TrackDel),i=t.mapPos(this.to,1,be.TrackDel);return e==null||i==null?null:new b(this.field,e,i)}}class x{constructor(t,e){this.lines=t,this.fieldPositions=e}instantiate(t,e){let i=[],n=[e],s=t.doc.lineAt(e),l=/^\s*/.exec(s.text)[0];for(let a of this.lines){if(i.length){let h=l,c=/^\t*/.exec(a)[0].length;for(let r=0;r<c;r++)h+=t.facet(Xe);n.push(e+h.length-c),a=h+a.slice(c)}i.push(a),e+=a.length+1}let f=this.fieldPositions.map((a)=>new b(a.field,n[a.line]+a.from,n[a.line]+a.to));return{text:i,ranges:f}}static parse(t){let e=[],i=[],n=[],s;for(let l of t.split(/\r\n?|\n/)){while(s=/[#$]\{(?:(\d+)(?::([^{}]*))?|((?:\\[{}]|[^{}])*))\}/.exec(l)){let f=s[1]?+s[1]:null,a=s[2]||s[3]||"",h=-1;if(f===0)f=1e9;let c=a.replace(/\\[{}]/g,(r)=>r[1]);for(let r=0;r<e.length;r++)if(f!=null?e[r].seq==f:c?e[r].name==c:!1)h=r;if(h<0){let r=0;while(r<e.length&&(f==null||e[r].seq!=null&&e[r].seq<f))r++;e.splice(r,0,{seq:f,name:c}),h=r;for(let p of n)if(p.field>=h)p.field++}for(let r of n)if(r.line==i.length&&r.from>s.index){let p=s[2]?3+(s[1]||"").length:2;r.from-=p,r.to-=p}n.push(new I(h,i.length,s.index,s.index+c.length)),l=l.slice(0,s.index)+a+l.slice(s.index+s[0].length)}l=l.replace(/\\([{}])/g,(f,a,h)=>{for(let c of n)if(c.line==i.length&&c.from>h)c.from--,c.to--;return a}),i.push(l)}return new x(i,n)}}var M=k.widget({widget:new class extends vt{toDOM(){let t=document.createElement("span");return t.className="cm-snippetFieldPosition",t}ignoreEvent(){return!1}}}),A=k.mark({class:"cm-snippetField"});class d{constructor(t,e){this.ranges=t,this.active=e,this.deco=k.set(t.map((i)=>(i.from==i.to?M:A).range(i.from,i.to)),!0)}map(t){let e=[];for(let i of this.ranges){let n=i.map(t);if(!n)return null;e.push(n)}return new d(e,this.active)}selectionInsideField(t){return t.ranges.every((e)=>this.ranges.some((i)=>i.field==this.active&&i.from<=e.from&&i.to>=e.to))}}var y=U.define({map(t,e){return t&&t.map(e)}}),B=U.define(),m=ve.define({create(){return null},update(t,e){for(let i of e.effects){if(i.is(y))return i.value;if(i.is(B)&&t)return new d(t.ranges,i.value)}if(t&&e.docChanged)t=t.map(e.changes);if(t&&e.selection&&!t.selectionInsideField(e.selection))t=null;return t},provide:(t)=>u.decorations.from(t,(e)=>e?e.deco:k.none)});function w(t,e){return o.create(t.filter((i)=>i.field==e).map((i)=>o.range(i.from,i.to)))}function F(t){let e=x.parse(t);return(i,n,s,l)=>{let{text:f,ranges:a}=e.instantiate(i.state,s),{main:h}=i.state.selection,c={changes:{from:s,to:l==h.from?h.to:l,insert:z.of(f)},scrollIntoView:!0,annotations:n?[P.of(n),te.userEvent.of("input.complete")]:void 0};if(a.length)c.selection=w(a,0);if(a.some((r)=>r.field>0)){let r=new d(a,0),p=c.effects=[y.of(r)];if(i.state.field(m,!1)===void 0)p.push(U.appendConfig.of([m,H,V,L]))}i.dispatch(i.state.update(c))}}function S(t){return({state:e,dispatch:i})=>{let n=e.field(m,!1);if(!n||t<0&&n.active==0)return!1;let s=n.active+t,l=t>0&&!n.ranges.some((f)=>f.field==s+t);return i(e.update({selection:w(n.ranges,s),effects:y.of(l?null:new d(n.ranges,s)),scrollIntoView:!0})),!0}}var W=({state:t,dispatch:e})=>{if(!t.field(m,!1))return!1;return e(t.update({effects:y.of(null)})),!0},N=S(1),j=S(-1);var _=[{key:"Tab",run:N,shift:j},{key:"Escape",run:W}],C=g.define({combine(t){return t.length?t[0]:_}}),H=Pe.highest(ot.compute([C],(t)=>t.facet(C)));function R(t,e){return{...e,apply:F(t)}}var V=u.domEventHandlers({mousedown(t,e){let i=e.state.field(m,!1),n;if(!i||(n=e.posAtCoords({x:t.clientX,y:t.clientY}))==null)return!1;let s=i.ranges.find((l)=>l.from<=n&&l.to>=n);if(!s||s.field==i.active)return!1;return e.dispatch({selection:w(i.ranges,s.field),effects:y.of(i.ranges.some((l)=>l.field>s.field)?new d(i.ranges,s.field):null),scrollIntoView:!0}),!0}});var O=new class extends Ge{};O.startSide=1;O.endSide=-1;var ae=typeof navigator=="object"&&/Android\b/.test(navigator.userAgent);
|
|
2
|
-
export{ai,Ve,Be,R};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Ce,Si,Tt,wi,V,ee,Mn,_i,Dr,Ur,ki,Vr,Br,qr,Vt}from"./chunk-index-18gxy79n.js";export{Tt as AVATAR_STATES,V as CATALOG,Ce as CLASS_IDS,ee as CharacterError,Ur as EAST_ASIAN_SKINS,Si as EXPRESSIONS,wi as STATE_EXPRESSION,Br as accentOf,qr as characterCss,ki as checkSkins,Vr as composeSvg,_i as parseCharacter,Dr as readCharacter,Mn as resolveCharacter,Vt as suggestCharacter};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{M,h,b,f}from"./chunk-index-31wh5twj.js";import{Mr}from"./chunk-index-e1dr6g10.js";import{Ne,$r,Nr,Lr,Xr,zr}from"./chunk-index-0p5h2kdz.js";import{Ot,Xi,Gt}from"./chunk-index-gpkzhq1g.js";var n={createFolder:(e)=>b("folders",{method:"POST",body:JSON.stringify({name:e})}),changeFolder:(e,t)=>b(`folders/${encodeURIComponent(e)}`,{method:"PATCH",body:JSON.stringify(t)}),deleteFolder:(e)=>b(`folders/${encodeURIComponent(e)}`,{method:"DELETE"}),muteFolder:(e,t)=>b(`folders/${encodeURIComponent(e)}/mute`,{method:"PUT",body:JSON.stringify({muted:t})}),placeRoom:(e,t,o)=>b(`rooms/${encodeURIComponent(e)}/folder`,{method:"PUT",body:JSON.stringify({folder:t,before:o})}),pinRoom:(e,t,o)=>b(`rooms/${encodeURIComponent(e)}/pin`,{method:"PUT",body:JSON.stringify({pinned:t,before:o})})};var l=(e)=>h(e,"danger"),d=(e)=>M.dispatch({type:"layout_loaded",pins:e.pins,folders:e.folders});async function i(e,t,o=l){let r=Xi();try{d(e(r))}catch{}try{let s=await t();return d(s),s}catch(s){d(r),M.dispatch({type:"changed"}),o(f(s));return}}var Pr=(e,t,o=null)=>i((r)=>zr(r,e,t,o),()=>n.pinRoom(e,t,o)),Rt=(e,t,o=null)=>i((r)=>Xr(r,e,t,o),()=>n.placeRoom(e,t,o));function ti(e,t){let o=Ot(Gt(),e);if(o.kind==="rest")return;let r=Ne(o.siblings,e,t);if(!r)return;return o.kind==="pinned"?Pr(e,!0,r.before):Rt(e,o.folder,r.before)}async function Ei(e,t=l){try{let o=await n.createFolder(e);return d(o),o.folders.at(-1)?.id}catch(o){t(f(o));return}}var Ci=(e,t,o)=>i((r)=>$r(r,e,t),()=>n.changeFolder(e,{name:t}),o),Fr=(e,t)=>i((o)=>Nr(o,e,t),()=>n.changeFolder(e,{before:t}));function Zr(e,t){let o=Ne(Xi().folders.map((r)=>r.id),e,t);return o?Fr(e,o.before):void 0}var Ai=(e,t)=>i((o)=>Lr(o,e),()=>n.deleteFolder(e),t);async function Wr(e,t){try{let o=await n.muteFolder(e,t);for(let r of o.rooms)M.dispatch({type:"room_muted",room:r,muted:o.muted});return!0}catch(o){return l(f(o)),!1}}function Yr(e,t){let o=Mr(Ot(Gt(),e),e,t);if(!o)return;if(o.kind==="pin")return Pr(e,!0,o.before);if(o.kind==="folder")return Rt(e,o.folder,o.before);return Rt(e,null)}
|
|
2
|
-
export{Pr,Rt,ti,Ei,Ci,Fr,Zr,Ai,Wr,Yr};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./chunk-index-4ecjtdy8.js";import"./chunk-index-zfd00hwb.js";import{on}from"./chunk-index-s681nny9.js";var r=()=>on();export{r as language};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./chunk-index-4ecjtdy8.js";import"./chunk-index-zfd00hwb.js";import{an}from"./chunk-index-krtk6nn2.js";import"./chunk-index-s681nny9.js";import"./chunk-index-9jqcskb4.js";import"./chunk-index-pcvt668q.js";var t=()=>an();export{t as language};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./chunk-index-4ecjtdy8.js";import"./chunk-index-zfd00hwb.js";import{yt}from"./chunk-index-9jqcskb4.js";import"./chunk-index-pcvt668q.js";var t=()=>yt({jsx:!0});export{t as language};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import{o,Pe,A,Me,u,ot,v,ie,nt,S,E,lt,cn,Re,I,i,ct,Ct,_e,T,xt,q,un,Xe,F,Wi,Z}from"./chunk-index-4ecjtdy8.js";import"./chunk-index-zfd00hwb.js";import{zi,an}from"./chunk-index-krtk6nn2.js";import"./chunk-index-s681nny9.js";import"./chunk-index-9jqcskb4.js";import{ai}from"./chunk-index-pcvt668q.js";class Y{static create(e,t,r,n,s){let a=n+(n<<8)+e+(t<<4)|0;return new Y(e,t,r,a,s,[],[])}constructor(e,t,r,n,s,a,l){this.type=e,this.value=t,this.from=r,this.hash=n,this.end=s,this.children=a,this.positions=l,this.blankFirstLine=!1,this.hashProp=[[v.contextHash,n]]}addChild(e,t){if(e.prop(v.contextHash)!=this.hash)e=new E(e.type,e.children,e.positions,e.length,this.hashProp);this.children.push(e),this.positions.push(t)}toTree(e,t=this.end){let r=this.children.length-1;if(r>=0)t=Math.max(t,this.positions[r]+this.children[r].length+this.from);return new E(e.types[this.type],this.children,this.positions,t-this.from).balance({makeTree:(n,s,a)=>new E(ie.none,n,s,a,this.hashProp)})}}var c;(function(e){e[e.Document=1]="Document",e[e.CodeBlock=2]="CodeBlock",e[e.FencedCode=3]="FencedCode",e[e.Blockquote=4]="Blockquote",e[e.HorizontalRule=5]="HorizontalRule",e[e.BulletList=6]="BulletList",e[e.OrderedList=7]="OrderedList",e[e.ListItem=8]="ListItem",e[e.ATXHeading1=9]="ATXHeading1",e[e.ATXHeading2=10]="ATXHeading2",e[e.ATXHeading3=11]="ATXHeading3",e[e.ATXHeading4=12]="ATXHeading4",e[e.ATXHeading5=13]="ATXHeading5",e[e.ATXHeading6=14]="ATXHeading6",e[e.SetextHeading1=15]="SetextHeading1",e[e.SetextHeading2=16]="SetextHeading2",e[e.HTMLBlock=17]="HTMLBlock",e[e.LinkReference=18]="LinkReference",e[e.Paragraph=19]="Paragraph",e[e.CommentBlock=20]="CommentBlock",e[e.ProcessingInstructionBlock=21]="ProcessingInstructionBlock",e[e.Escape=22]="Escape",e[e.Entity=23]="Entity",e[e.HardBreak=24]="HardBreak",e[e.Emphasis=25]="Emphasis",e[e.StrongEmphasis=26]="StrongEmphasis",e[e.Link=27]="Link",e[e.Image=28]="Image",e[e.InlineCode=29]="InlineCode",e[e.HTMLTag=30]="HTMLTag",e[e.Comment=31]="Comment",e[e.ProcessingInstruction=32]="ProcessingInstruction",e[e.Autolink=33]="Autolink",e[e.HeaderMark=34]="HeaderMark",e[e.QuoteMark=35]="QuoteMark",e[e.ListMark=36]="ListMark",e[e.LinkMark=37]="LinkMark",e[e.EmphasisMark=38]="EmphasisMark",e[e.CodeMark=39]="CodeMark",e[e.CodeText=40]="CodeText",e[e.CodeInfo=41]="CodeInfo",e[e.LinkTitle=42]="LinkTitle",e[e.LinkLabel=43]="LinkLabel",e[e.URL=44]="URL"})(c||(c={}));class ze{constructor(e,t){this.start=e,this.content=t,this.marks=[],this.parsers=[]}}class Te{constructor(){this.text="",this.baseIndent=0,this.basePos=0,this.depth=0,this.markers=[],this.pos=0,this.indent=0,this.next=-1}forward(){if(this.basePos>this.pos)this.forwardInner()}forwardInner(){let e=this.skipSpace(this.basePos);this.indent=this.countIndent(e,this.pos,this.indent),this.pos=e,this.next=e==this.text.length?-1:this.text.charCodeAt(e)}skipSpace(e){return j(this.text,e)}reset(e){this.text=e,this.baseIndent=this.basePos=this.pos=this.indent=0,this.forwardInner(),this.depth=1;while(this.markers.length)this.markers.pop()}moveBase(e){this.basePos=e,this.baseIndent=this.countIndent(e,this.pos,this.indent)}moveBaseColumn(e){this.baseIndent=e,this.basePos=this.findColumn(e)}addMarker(e){this.markers.push(e)}countIndent(e,t=0,r=0){for(let n=t;n<e;n++)r+=this.text.charCodeAt(n)==9?4-r%4:1;return r}findColumn(e){let t=0;for(let r=0;t<this.text.length&&r<e;t++)r+=this.text.charCodeAt(t)==9?4-r%4:1;return t}scrub(){if(!this.baseIndent)return this.text;let e="";for(let t=0;t<this.basePos;t++)e+=" ";return e+this.text.slice(this.basePos)}}function Ce(e,t,r){if(r.pos==r.text.length||e!=t.block&&r.indent>=t.stack[r.depth+1].value+r.baseIndent)return!0;if(r.indent>=r.baseIndent+4)return!1;let n=(e.type==c.OrderedList?de:ue)(r,t,!1);return n>0&&(e.type!=c.BulletList||fe(r,t,!1)<0)&&r.text.charCodeAt(r.pos+n-1)==e.value}var Fe={[c.Blockquote](e,t,r){if(r.next!=62)return!1;return r.markers.push(k(c.QuoteMark,t.lineStart+r.pos,t.lineStart+r.pos+1)),r.moveBase(r.pos+(M(r.text.charCodeAt(r.pos+1))?2:1)),e.end=t.lineStart+r.text.length,!0},[c.ListItem](e,t,r){if(r.next<0?e.blankFirstLine&&e.children.length==1:r.indent<r.baseIndent+e.value)return!1;return r.moveBaseColumn(r.baseIndent+e.value),!0},[c.OrderedList]:Ce,[c.BulletList]:Ce,[c.Document](){return!0}};function M(e){return e==32||e==9||e==10||e==13}function j(e,t=0){while(t<e.length&&M(e.charCodeAt(t)))t++;return t}function Ae(e,t,r){while(t>r&&M(e.charCodeAt(t-1)))t--;return t}function $e(e){if(e.next!=96&&e.next!=126)return-1;let t=e.pos+1;while(t<e.text.length&&e.text.charCodeAt(t)==e.next)t++;if(t<e.pos+3)return-1;if(e.next==96){for(let r=t;r<e.text.length;r++)if(e.text.charCodeAt(r)==96)return-1}return t}function De(e){return e.next!=62?-1:e.text.charCodeAt(e.pos+1)==32?2:1}function fe(e,t,r){if(e.next!=42&&e.next!=45&&e.next!=95)return-1;let n=1;for(let s=e.pos+1;s<e.text.length;s++){let a=e.text.charCodeAt(s);if(a==e.next)n++;else if(!M(a))return-1}if(r&&e.next==45&&qe(e)>-1&&e.depth==t.stack.length&&t.parser.leafBlockParsers.indexOf(Je.SetextHeading)>-1)return-1;return n<3?-1:1}function Ue(e,t){for(let r=e.stack.length-1;r>=0;r--)if(e.stack[r].type==t)return!0;return!1}function ue(e,t,r){return(e.next==45||e.next==43||e.next==42)&&(e.pos==e.text.length-1||M(e.text.charCodeAt(e.pos+1)))&&(!r||Ue(t,c.BulletList)||e.skipSpace(e.pos+2)<e.text.length)?1:-1}function de(e,t,r){let{pos:n,next:s}=e;for(;;){if(s>=48&&s<=57)n++;else break;if(n==e.text.length)return-1;s=e.text.charCodeAt(n)}if(n==e.pos||n>e.pos+9||s!=46&&s!=41||n<e.text.length-1&&!M(e.text.charCodeAt(n+1))||r&&!Ue(t,c.OrderedList)&&(e.skipSpace(n+1)==e.text.length||n>e.pos+1||e.next!=49))return-1;return n+1-e.pos}function je(e){if(e.next!=35)return-1;let t=e.pos+1;while(t<e.text.length&&e.text.charCodeAt(t)==35)t++;if(t<e.text.length&&!M(e.text.charCodeAt(t)))return-1;let r=t-e.pos;return r>6?-1:r}function qe(e){if(e.next!=45&&e.next!=61||e.indent>=e.baseIndent+4)return-1;let t=e.pos+1;while(t<e.text.length&&e.text.charCodeAt(t)==e.next)t++;let r=t;while(t<e.text.length&&M(e.text.charCodeAt(t)))t++;return t==e.text.length?r:-1}var se=/^[ \t]*$/,Qe=/-->/,Ze=/\?>/,oe=[[/^<(?:script|pre|style|textarea)(?:\s|>|$)/i,/<\/(?:script|pre|style|textarea)>/i],[/^\s*<!--/,Qe],[/^\s*<\?/,Ze],[/^\s*<![A-Z]/,/>/],[/^\s*<!\[CDATA\[/,/\]\]>/],[/^\s*<\/?(?:address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h1|h2|h3|h4|h5|h6|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul)(?:\s|\/?>|$)/i,se],[/^\s*(?:<\/[a-z][\w-]*\s*>|<[a-z][\w-]*(\s+[a-z:_][\w-.]*(?:\s*=\s*(?:[^\s"'=<>`]+|'[^']*'|"[^"]*"))?)*\s*>)\s*$/i,se]];function Ge(e,t,r){if(e.next!=60)return-1;let n=e.text.slice(e.pos);for(let s=0,a=oe.length-(r?1:0);s<a;s++)if(oe[s][0].test(n))return s;return-1}function xe(e,t){let r=e.countIndent(t,e.pos,e.indent),n=e.skipSpace(t),s=e.countIndent(n,t,r);return s>=r+5||n==e.text.length?r+1:s}function N(e,t,r){let n=e.length-1;if(n>=0&&e[n].to==t&&e[n].type==c.CodeText)e[n].to=r;else e.push(k(c.CodeText,t,r))}var K={LinkReference:void 0,IndentedCode(e,t){let r=t.baseIndent+4;if(t.indent<r)return!1;let n=t.findColumn(r),s=e.lineStart+n,a=e.lineStart+t.text.length,l=[],h=[];N(l,s,a);while(e.nextLine()&&t.depth>=e.stack.length)if(t.pos==t.text.length){N(h,e.lineStart-1,e.lineStart);for(let f of t.markers)h.push(f)}else if(t.indent<r)break;else{if(h.length){for(let d of h)if(d.type==c.CodeText)N(l,d.from,d.to);else l.push(d);h=[]}N(l,e.lineStart-1,e.lineStart);for(let d of t.markers)l.push(d);a=e.lineStart+t.text.length;let f=e.lineStart+t.findColumn(t.baseIndent+4);if(f<a)N(l,f,a)}if(h.length){if(h=h.filter((f)=>f.type!=c.CodeText),h.length)t.markers=h.concat(t.markers)}return e.addNode(e.buffer.writeElements(l,-s).finish(c.CodeBlock,a-s),s),!0},FencedCode(e,t){let r=$e(t);if(r<0)return!1;let n=e.lineStart+t.pos,s=t.next,a=r-t.pos,l=t.skipSpace(r),h=Ae(t.text,t.text.length,l),f=[k(c.CodeMark,n,n+a)];if(l<h)f.push(k(c.CodeInfo,e.lineStart+l,e.lineStart+h));for(let d=!0,m=!0,p=!1;e.nextLine()&&t.depth>=e.stack.length;d=!1){let g=t.pos;if(t.indent-t.baseIndent<4)while(g<t.text.length&&t.text.charCodeAt(g)==s)g++;if(g-t.pos>=a&&t.skipSpace(g)==t.text.length){for(let L of t.markers)f.push(L);if(m&&p)N(f,e.lineStart-1,e.lineStart);f.push(k(c.CodeMark,e.lineStart+t.pos,e.lineStart+g)),e.nextLine();break}else{if(p=!0,!d)N(f,e.lineStart-1,e.lineStart),m=!1;for(let H of t.markers)f.push(H);let L=e.lineStart+t.basePos,b=e.lineStart+t.text.length;if(L<b)N(f,L,b),m=!1}}return e.addNode(e.buffer.writeElements(f,-n).finish(c.FencedCode,e.prevLineEnd()-n),n),!0},Blockquote(e,t){let r=De(t);if(r<0)return!1;return e.startContext(c.Blockquote,t.pos),e.addNode(c.QuoteMark,e.lineStart+t.pos,e.lineStart+t.pos+1),t.moveBase(t.pos+r),null},HorizontalRule(e,t){if(fe(t,e,!1)<0)return!1;let r=e.lineStart+t.pos;return e.nextLine(),e.addNode(c.HorizontalRule,r),!0},BulletList(e,t){let r=ue(t,e,!1);if(r<0)return!1;if(e.block.type!=c.BulletList)e.startContext(c.BulletList,t.basePos,t.next);let n=xe(t,t.pos+1);return e.startContext(c.ListItem,t.basePos,n-t.baseIndent),e.addNode(c.ListMark,e.lineStart+t.pos,e.lineStart+t.pos+r),t.moveBaseColumn(n),e.block.blankFirstLine=n>=t.text.length,null},OrderedList(e,t){let r=de(t,e,!1);if(r<0)return!1;if(e.block.type!=c.OrderedList)e.startContext(c.OrderedList,t.basePos,t.text.charCodeAt(t.pos+r-1));let n=xe(t,t.pos+r);return e.startContext(c.ListItem,t.basePos,n-t.baseIndent),e.addNode(c.ListMark,e.lineStart+t.pos,e.lineStart+t.pos+r),t.moveBaseColumn(n),e.block.blankFirstLine=n==t.text.length,null},ATXHeading(e,t){let r=je(t);if(r<0)return!1;let n=t.pos,s=e.lineStart+n,a=Ae(t.text,t.text.length,n),l=a;while(l>n&&t.text.charCodeAt(l-1)==t.next)l--;if(l==a||l==n||!M(t.text.charCodeAt(l-1)))l=t.text.length;let h=e.buffer.write(c.HeaderMark,0,r).writeElements(e.parser.parseInline(t.text.slice(n+r+1,l),s+r+1),-s);if(l<t.text.length)h.write(c.HeaderMark,l-n,a-n);let f=h.finish(c.ATXHeading1-1+r,t.text.length-n);return e.nextLine(),e.addNode(f,s),!0},HTMLBlock(e,t){let r=Ge(t,e,!1);if(r<0)return!1;let n=e.lineStart+t.pos,s=oe[r][1],a=[],l=s!=se;while(!s.test(t.text)&&e.nextLine()){if(t.depth<e.stack.length){l=!1;break}for(let d of t.markers)a.push(d)}if(l)e.nextLine();let h=s==Qe?c.CommentBlock:s==Ze?c.ProcessingInstructionBlock:c.HTMLBlock,f=e.prevLineEnd();return e.addNode(e.buffer.writeElements(a,-n).finish(h,f-n),n),!0},SetextHeading:void 0};class Ve{constructor(e){this.stage=0,this.elts=[],this.pos=0,this.start=e.start,this.advance(e.content)}nextLine(e,t,r){if(this.stage==-1)return!1;let n=r.content+`
|
|
2
|
-
`+t.scrub(),s=this.advance(n);if(s>-1&&s<n.length)return this.complete(e,r,s);return!1}finish(e,t){if((this.stage==2||this.stage==3)&&j(t.content,this.pos)==t.content.length)return this.complete(e,t,t.content.length);return!1}complete(e,t,r){return e.addLeafElement(t,k(c.LinkReference,this.start,this.start+r,this.elts)),!0}nextStage(e){if(e)return this.pos=e.to-this.start,this.elts.push(e),this.stage++,!0;if(e===!1)this.stage=-1;return!1}advance(e){for(;;)if(this.stage==-1)return-1;else if(this.stage==0){if(!this.nextStage(st(e,this.pos,this.start,!0)))return-1;if(e.charCodeAt(this.pos)!=58)return this.stage=-1;this.elts.push(k(c.LinkMark,this.pos+this.start,this.pos+this.start+1)),this.pos++}else if(this.stage==1){if(!this.nextStage(tt(e,j(e,this.pos),this.start)))return-1}else if(this.stage==2){let t=j(e,this.pos),r=0;if(t>this.pos){let n=rt(e,t,this.start);if(n){let s=re(e,n.to-this.start);if(s>0)this.nextStage(n),r=s}}if(!r)r=re(e,this.pos);return r>0&&r<e.length?r:-1}else return re(e,this.pos)}}function re(e,t){for(;t<e.length;t++){let r=e.charCodeAt(t);if(r==10)break;if(!M(r))return-1}return t}class Ke{nextLine(e,t,r){let n=t.depth<e.stack.length?-1:qe(t),s=t.next;if(n<0)return!1;let a=k(c.HeaderMark,e.lineStart+t.pos,e.lineStart+n);return e.nextLine(),e.addLeafElement(r,k(s==61?c.SetextHeading1:c.SetextHeading2,r.start,e.prevLineEnd(),[...e.parser.parseInline(r.content,r.start),a])),!0}finish(){return!1}}var Je={LinkReference(e,t){return t.content.charCodeAt(0)==91?new Ve(t):null},SetextHeading(){return new Ke}},Pt=[(e,t)=>je(t)>=0,(e,t)=>$e(t)>=0,(e,t)=>De(t)>=0,(e,t)=>ue(t,e,!0)>=0,(e,t)=>de(t,e,!0)>=0,(e,t)=>fe(t,e,!0)>=0,(e,t)=>Ge(t,e,!0)>=0],yt={text:"",end:0};class Ye{constructor(e,t,r,n){this.parser=e,this.input=t,this.ranges=n,this.line=new Te,this.atEnd=!1,this.reusePlaceholders=new Map,this.stoppedAt=null,this.rangeI=0,this.to=n[n.length-1].to,this.lineStart=this.absoluteLineStart=this.absoluteLineEnd=n[0].from,this.block=Y.create(c.Document,0,this.lineStart,0,0),this.stack=[this.block],this.fragments=r.length?new at(r,t):null,this.readLine()}get parsedPos(){return this.absoluteLineStart}advance(){if(this.stoppedAt!=null&&this.absoluteLineStart>this.stoppedAt)return this.finish();let{line:e}=this;for(;;){for(let r=0;;){let n=e.depth<this.stack.length?this.stack[this.stack.length-1]:null;while(r<e.markers.length&&(!n||e.markers[r].from<n.end)){let s=e.markers[r++];this.addNode(s.type,s.from,s.to)}if(!n)break;this.finishContext()}if(e.pos<e.text.length)break;if(!this.nextLine())return this.finish()}if(this.fragments&&this.reuseFragment(e.basePos))return null;e:for(;;){for(let r of this.parser.blockParsers)if(r){let n=r(this,e);if(n!=!1){if(n==!0)return null;e.forward();continue e}}break}if(e.pos==e.text.length)return this.nextLine()?null:this.finish();let t=new ze(this.lineStart+e.pos,e.text.slice(e.pos));for(let r of this.parser.leafBlockParsers)if(r){let n=r(this,t);if(n)t.parsers.push(n)}e:while(this.nextLine()){if(e.pos==e.text.length)break;if(e.indent<e.baseIndent+4){for(let r of this.parser.endLeafBlock)if(r(this,e,t))break e}for(let r of t.parsers)if(r.nextLine(this,e,t))return null;t.content+=`
|
|
3
|
-
`+e.scrub();for(let r of e.markers)t.marks.push(r)}return this.finishLeaf(t),null}stopAt(e){if(this.stoppedAt!=null&&this.stoppedAt<e)throw RangeError("Can't move stoppedAt forward");this.stoppedAt=e}reuseFragment(e){if(!this.fragments.moveTo(this.absoluteLineStart+e,this.absoluteLineStart)||!this.fragments.matches(this.block.hash))return!1;let t=this.fragments.takeNodes(this);if(!t)return!1;if(this.absoluteLineStart+=t,this.lineStart=ht(this.absoluteLineStart,this.ranges),this.moveRangeI(),this.absoluteLineStart<this.to)this.lineStart++,this.absoluteLineStart++,this.readLine();else this.atEnd=!0,this.readLine();return!0}get depth(){return this.stack.length}parentType(e=this.depth-1){return this.parser.nodeSet.types[this.stack[e].type]}nextLine(){if(this.lineStart+=this.line.text.length,this.absoluteLineEnd>=this.to)return this.absoluteLineStart=this.absoluteLineEnd,this.atEnd=!0,this.readLine(),!1;else return this.lineStart++,this.absoluteLineStart=this.absoluteLineEnd+1,this.moveRangeI(),this.readLine(),!0}peekLine(){return this.scanLine(this.absoluteLineEnd+1).text}moveRangeI(){while(this.rangeI<this.ranges.length-1&&this.absoluteLineStart>=this.ranges[this.rangeI].to)this.rangeI++,this.absoluteLineStart=Math.max(this.absoluteLineStart,this.ranges[this.rangeI].from)}scanLine(e){let t=yt;if(t.end=e,e>=this.to)t.text="";else if(t.text=this.lineChunkAt(e),t.end+=t.text.length,this.ranges.length>1){let r=this.absoluteLineStart,n=this.rangeI;while(this.ranges[n].to<t.end){n++;let s=this.ranges[n].from,a=this.lineChunkAt(s);t.end=s+a.length,t.text=t.text.slice(0,this.ranges[n-1].to-r)+a,r=t.end-t.text.length}}return t}readLine(){let{line:e}=this,{text:t,end:r}=this.scanLine(this.absoluteLineStart);this.absoluteLineEnd=r,e.reset(t);for(;e.depth<this.stack.length;e.depth++){let n=this.stack[e.depth],s=this.parser.skipContextMarkup[n.type];if(!s)throw Error("Unhandled block context "+c[n.type]);let a=this.line.markers.length;if(!s(n,this,e)){if(this.line.markers.length>a)n.end=this.line.markers[this.line.markers.length-1].to;e.forward();break}e.forward()}}lineChunkAt(e){let t=this.input.chunk(e),r;if(!this.input.lineChunks){let n=t.indexOf(`
|
|
4
|
-
`);r=n<0?t:t.slice(0,n)}else r=t==`
|
|
5
|
-
`?"":t;return e+r.length>this.to?r.slice(0,this.to-e):r}prevLineEnd(){return this.atEnd?this.lineStart:this.lineStart-1}startContext(e,t,r=0){this.block=Y.create(e,r,this.lineStart+t,this.block.hash,this.lineStart+this.line.text.length),this.stack.push(this.block)}startComposite(e,t,r=0){this.startContext(this.parser.getNodeType(e),t,r)}addNode(e,t,r){if(typeof e=="number")e=new E(this.parser.nodeSet.types[e],R,R,(r!==null&&r!==void 0?r:this.prevLineEnd())-t);this.block.addChild(e,t-this.block.from)}addElement(e){this.block.addChild(e.toTree(this.parser.nodeSet),e.from-this.block.from)}addLeafElement(e,t){this.addNode(this.buffer.writeElements(le(t.children,e.marks),-t.from).finish(t.type,t.to-t.from),t.from)}finishContext(){let e=this.stack.pop(),t=this.stack[this.stack.length-1];t.addChild(e.toTree(this.parser.nodeSet),e.from-t.from),this.block=t}finish(){while(this.stack.length>1)this.finishContext();return this.addGaps(this.block.toTree(this.parser.nodeSet,this.lineStart))}addGaps(e){return this.ranges.length>1?We(this.ranges,0,e.topNode,this.ranges[0].from,this.reusePlaceholders):e}finishLeaf(e){for(let r of e.parsers)if(r.finish(this,e))return;let t=le(this.parser.parseInline(e.content,e.start),e.marks);this.addNode(this.buffer.writeElements(t,-e.start).finish(c.Paragraph,e.content.length),e.start)}elt(e,t,r,n){if(typeof e=="string")return k(this.parser.getNodeType(e),t,r,n);return new ce(e,t)}get buffer(){return new pe(this.parser.nodeSet)}}function We(e,t,r,n,s){let a=e[t].to,l=[],h=[],f=r.from+n;function d(m,p){while(p?m>=a:m>a){let g=e[t+1].from-a;n+=g,m+=g,t++,a=e[t].to}}for(let m=r.firstChild;m;m=m.nextSibling){d(m.from+n,!0);let p=m.from+n,g,L=s.get(m.tree);if(L)g=L;else if(m.to+n>a)g=We(e,t,m,n,s),d(m.to+n,!1);else g=m.toTree();l.push(g),h.push(p-f)}return d(r.to+n,!1),new E(r.type,l,h,r.to+n-f,r.tree?r.tree.propValues:void 0)}class V extends lt{constructor(e,t,r,n,s,a,l,h,f){super();this.nodeSet=e,this.blockParsers=t,this.leafBlockParsers=r,this.blockNames=n,this.endLeafBlock=s,this.skipContextMarkup=a,this.inlineParsers=l,this.inlineNames=h,this.wrappers=f,this.nodeTypes=Object.create(null);for(let d of e.types)this.nodeTypes[d.name]=d.id}createParse(e,t,r){let n=new Ye(this,e,t,r);for(let s of this.wrappers)n=s(n,e,t,r);return n}configure(e){let t=ae(e);if(!t)return this;let{nodeSet:r,skipContextMarkup:n}=this,s=this.blockParsers.slice(),a=this.leafBlockParsers.slice(),l=this.blockNames.slice(),h=this.inlineParsers.slice(),f=this.inlineNames.slice(),d=this.endLeafBlock.slice(),m=this.wrappers;if(U(t.defineNodes)){n=Object.assign({},n);let p=r.types.slice(),g;for(let L of t.defineNodes){let{name:b,block:H,composite:P,style:w}=typeof L=="string"?{name:L}:L;if(p.some((y)=>y.name==b))continue;if(P)n[p.length]=(y,D,_)=>P(D,_,y.value);let x=p.length,C=P?["Block","BlockContext"]:!H?void 0:x>=c.ATXHeading1&&x<=c.SetextHeading2?["Block","LeafBlock","Heading"]:["Block","LeafBlock"];if(p.push(ie.define({id:x,name:b,props:C&&[[v.group,C]]})),w){if(!g)g={};if(Array.isArray(w)||w instanceof Re)g[b]=w;else Object.assign(g,w)}}if(r=new nt(p),g)r=r.extend(I(g))}if(U(t.props))r=r.extend(...t.props);if(U(t.remove))for(let p of t.remove){let g=this.blockNames.indexOf(p),L=this.inlineNames.indexOf(p);if(g>-1)s[g]=a[g]=void 0;if(L>-1)h[L]=void 0}if(U(t.parseBlock))for(let p of t.parseBlock){let g=l.indexOf(p.name);if(g>-1)s[g]=p.parse,a[g]=p.leaf;else{let L=p.before?J(l,p.before):p.after?J(l,p.after)+1:l.length-1;s.splice(L,0,p.parse),a.splice(L,0,p.leaf),l.splice(L,0,p.name)}if(p.endLeaf)d.push(p.endLeaf)}if(U(t.parseInline))for(let p of t.parseInline){let g=f.indexOf(p.name);if(g>-1)h[g]=p.parse;else{let L=p.before?J(f,p.before):p.after?J(f,p.after)+1:f.length-1;h.splice(L,0,p.parse),f.splice(L,0,p.name)}}if(t.wrap)m=m.concat(t.wrap);return new V(r,s,a,l,d,n,h,f,m)}getNodeType(e){let t=this.nodeTypes[e];if(t==null)throw RangeError(`Unknown node type '${e}'`);return t}parseInline(e,t){let r=new X(this,e,t);e:for(let n=t;n<r.end;){let s=r.char(n);for(let a of this.inlineParsers)if(a){let l=a(r,s,n);if(l>=0){n=l;continue e}}n++}return r.resolveMarkers(0)}}function U(e){return e!=null&&e.length>0}function ae(e){if(!Array.isArray(e))return e;if(e.length==0)return null;let t=ae(e[0]);if(e.length==1)return t;let r=ae(e.slice(1));if(!r||!t)return t||r;let n=(l,h)=>(l||R).concat(h||R),s=t.wrap,a=r.wrap;return{props:n(t.props,r.props),defineNodes:n(t.defineNodes,r.defineNodes),parseBlock:n(t.parseBlock,r.parseBlock),parseInline:n(t.parseInline,r.parseInline),remove:n(t.remove,r.remove),wrap:!s?a:!a?s:(l,h,f,d)=>s(a(l,h,f,d),h,f,d)}}function J(e,t){let r=e.indexOf(t);if(r<0)throw RangeError(`Position specified relative to unknown parser ${t}`);return r}var et=[ie.none];for(let e=1,t;t=c[e];e++)et[e]=ie.define({id:e,name:t,props:e>=c.Escape?[]:[[v.group,e in Fe?["Block","BlockContext"]:["Block","LeafBlock"]]],top:t=="Document"});var R=[];class pe{constructor(e){this.nodeSet=e,this.content=[],this.nodes=[]}write(e,t,r,n=0){return this.content.push(e,t,r,4+n*4),this}writeElements(e,t=0){for(let r of e)r.writeTo(this,t);return this}finish(e,t){return E.build({buffer:this.content,nodeSet:this.nodeSet,reused:this.nodes,topID:e,length:t})}}class z{constructor(e,t,r,n=R){this.type=e,this.from=t,this.to=r,this.children=n}writeTo(e,t){let r=e.content.length;e.writeElements(this.children,t),e.content.push(this.type,this.from+t,this.to+t,e.content.length+4-r)}toTree(e){return new pe(e).writeElements(this.children,-this.from).finish(this.type,this.to-this.from)}}class ce{constructor(e,t){this.tree=e,this.from=t}get to(){return this.from+this.tree.length}get type(){return this.tree.type.id}get children(){return R}writeTo(e,t){e.nodes.push(this.tree),e.content.push(e.nodes.length-1,this.from+t,this.to+t,-1)}toTree(){return this.tree}}function k(e,t,r,n){return new z(e,t,r,n)}var me={resolve:"Emphasis",mark:"EmphasisMark"},ge={resolve:"Emphasis",mark:"EmphasisMark"},O={},W={};class B{constructor(e,t,r,n,s=r-t){this.type=e,this.from=t,this.to=r,this.side=n,this.size=s}}var Be="!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~",G=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\xA1\u2010-\u2027]/;try{G=new RegExp("[\\p{S}|\\p{P}]","u")}catch(e){}var ne={Escape(e,t,r){if(t!=92||r==e.end-1)return-1;let n=e.char(r+1);for(let s=0;s<Be.length;s++)if(Be.charCodeAt(s)==n)return e.append(k(c.Escape,r,r+2));return-1},Entity(e,t,r){if(t!=38)return-1;let n=/^(?:#\d+|#x[a-f\d]+|\w+);/i.exec(e.slice(r+1,r+31));return n?e.append(k(c.Entity,r,r+1+n[0].length)):-1},InlineCode(e,t,r){if(t!=96||r&&e.char(r-1)==96)return-1;let n=r+1;while(n<e.end&&e.char(n)==96)n++;let s=n-r,a=0;for(;n<e.end;n++)if(e.char(n)==96){if(a++,a==s&&e.char(n+1)!=96)return e.append(k(c.InlineCode,r,n+1,[k(c.CodeMark,r,r+s),k(c.CodeMark,n+1-s,n+1)]))}else a=0;return-1},HTMLTag(e,t,r){if(t!=60||r==e.end-1)return-1;let n=e.slice(r+1,e.end),s=/^(?:[a-z][-\w+.]+:[^\s>]+|[a-z\d.!#$%&'*+/=?^_`{|}~-]+@[a-z\d](?:[a-z\d-]{0,61}[a-z\d])?(?:\.[a-z\d](?:[a-z\d-]{0,61}[a-z\d])?)*)>/i.exec(n);if(s)return e.append(k(c.Autolink,r,r+1+s[0].length,[k(c.LinkMark,r,r+1),k(c.URL,r+1,r+s[0].length),k(c.LinkMark,r+s[0].length,r+1+s[0].length)]));let a=/^!--(?:-?>|[^]*?-->)/.exec(n);if(a)return e.append(k(c.Comment,r,r+1+a[0].length));let l=/^\?[^]*?\?>/.exec(n);if(l)return e.append(k(c.ProcessingInstruction,r,r+1+l[0].length));let h=/^(?:![A-Z][^]*?>|!\[CDATA\[[^]*?\]\]>|\/[a-zA-Z][\w-]*\s*>|[a-zA-Z][\w-]*(\s+[a-zA-Z:_][\w-.:]*(?:\s*=\s*(?:[^\s"'=<>`]+|'[^']*'|"[^"]*"))?)*\s*\/?>)/.exec(n);if(!h)return-1;return e.append(k(c.HTMLTag,r,r+1+h[0].length))},Emphasis(e,t,r){if(t!=95&&t!=42)return-1;let n=r+1;while(e.char(n)==t)n++;let s=e.slice(r-1,r),a=e.slice(n,n+1),l=G.test(s),h=G.test(a),f=/\s|^$/.test(s),d=/\s|^$/.test(a),m=!d&&(!h||f||l),p=!f&&(!l||d||h),g=m&&(t==42||!p||l),L=p&&(t==42||!m||h);return e.append(new B(t==95?me:ge,r,n,(g?1:0)|(L?2:0)))},HardBreak(e,t,r){if(t==92&&e.char(r+1)==10)return e.append(k(c.HardBreak,r,r+2));if(t==32){let n=r+1;while(e.char(n)==32)n++;if(e.char(n)==10&&n>=r+2)return e.append(k(c.HardBreak,r,n+1))}return-1},Link(e,t,r){return t==91?e.append(new B(O,r,r+1,1)):-1},Image(e,t,r){return t==33&&e.char(r+1)==91?e.append(new B(W,r,r+2,1)):-1},LinkEnd(e,t,r){if(t!=93)return-1;for(let n=e.parts.length-1;n>=0;n--){let s=e.parts[n];if(s instanceof B&&(s.type==O||s.type==W)){if(!s.side||e.skipSpace(s.to)==r&&!/[(\[]/.test(e.slice(r+1,r+2)))return e.parts[n]=null,-1;let a=e.takeContent(n),l=e.parts[n]=Nt(e,a,s.type==O?c.Link:c.Image,s.from,r+1);if(s.type==O)for(let h=0;h<n;h++){let f=e.parts[h];if(f instanceof B&&f.type==O)f.side=0}return l.to}}return-1}};function Nt(e,t,r,n,s){let{text:a}=e,l=e.char(s),h=s;if(t.unshift(k(c.LinkMark,n,n+(r==c.Image?2:1))),t.push(k(c.LinkMark,s-1,s)),l==40){let f=e.skipSpace(s+1),d=tt(a,f-e.offset,e.offset),m;if(d){if(f=e.skipSpace(d.to),f!=d.to){if(m=rt(a,f-e.offset,e.offset),m)f=e.skipSpace(m.to)}}if(e.char(f)==41){if(t.push(k(c.LinkMark,s,s+1)),h=f+1,d)t.push(d);if(m)t.push(m);t.push(k(c.LinkMark,f,h))}}else if(l==91){let f=st(a,s-e.offset,e.offset,!1);if(f)t.push(f),h=f.to}return k(r,n,h,t)}function tt(e,t,r){if(e.charCodeAt(t)==60){for(let s=t+1,a=!1;s<e.length;s++){let l=e.charCodeAt(s);if(l==62&&!a)return k(c.URL,t+r,s+1+r);if(l==60&&!a||l==10)return!1;a=l==92}return null}else{let s=0,a=t;for(let l=!1;a<e.length;a++){let h=e.charCodeAt(a);if(M(h))break;else if(l)l=!1;else if(h==40)s++;else if(h==41){if(!s)break;s--}else if(h==92)l=!0}return a>t?k(c.URL,t+r,a+r):a==e.length?null:!1}}function rt(e,t,r){let n=e.charCodeAt(t);if(n!=39&&n!=34&&n!=40)return!1;let s=n==40?41:n;for(let a=t+1,l=!1;a<e.length;a++){let h=e.charCodeAt(a);if(l)l=!1;else if(h==s)return k(c.LinkTitle,t+r,a+1+r);else if(h==92)l=!0}return null}function st(e,t,r,n){for(let s=!1,a=t+1,l=Math.min(e.length,a+999);a<l;a++){let h=e.charCodeAt(a);if(s)s=!1;else if(h==93)return n?!1:k(c.LinkLabel,t+r,a+1+r);else{if(n&&!M(h))n=!1;if(h==91)return!1;else if(h==92)s=!0}}return null}class X{constructor(e,t,r){this.parser=e,this.text=t,this.offset=r,this.parts=[]}char(e){return e>=this.end?-1:this.text.charCodeAt(e-this.offset)}get end(){return this.offset+this.text.length}slice(e,t){return this.text.slice(e-this.offset,t-this.offset)}append(e){return this.parts.push(e),e.to}addDelimiter(e,t,r,n,s){return this.append(new B(e,t,r,(n?1:0)|(s?2:0)))}get hasOpenLink(){for(let e=this.parts.length-1;e>=0;e--){let t=this.parts[e];if(t instanceof B&&(t.type==O||t.type==W))return!0}return!1}addElement(e){return this.append(e)}resolveMarkers(e){for(let r=e;r<this.parts.length;r++){let n=this.parts[r];if(!(n instanceof B&&n.type.resolve&&n.side&2))continue;let s=n.type==me||n.type==ge,a=n.to-n.from,l,h=r-1;for(;h>=e;h--){let b=this.parts[h];if(b instanceof B&&b.side&1&&b.type==n.type&&!(s&&(n.side&1||b.side&2)&&(b.size+n.size)%3==0&&(b.size%3||n.size%3))){l=b;break}}if(!l)continue;let f=n.type.resolve,d=[],m=l.from,p=n.to;if(s){let b=Math.min(2,l.to-l.from,a);m=l.to-b,p=n.from+b,f=b==1?"Emphasis":"StrongEmphasis"}if(l.type.mark)d.push(this.elt(l.type.mark,m,l.to));for(let b=h+1;b<r;b++){if(this.parts[b]instanceof z)d.push(this.parts[b]);this.parts[b]=null}if(n.type.mark)d.push(this.elt(n.type.mark,n.from,p));let g=this.elt(f,m,p,d);if(this.parts[h]=s&&l.from!=m?new B(l.type,l.from,m,l.side,l.size):null,this.parts[r]=s&&n.to!=p?new B(n.type,p,n.to,n.side,n.size):null)this.parts.splice(r,0,g);else this.parts[r]=g}let t=[];for(let r=e;r<this.parts.length;r++){let n=this.parts[r];if(n instanceof z)t.push(n)}return t}findOpeningDelimiter(e){for(let t=this.parts.length-1;t>=0;t--){let r=this.parts[t];if(r instanceof B&&r.type==e&&r.side&1)return t}return null}takeContent(e){let t=this.resolveMarkers(e);return this.parts.length=e,t}getDelimiterAt(e){let t=this.parts[e];return t instanceof B?t:null}skipSpace(e){return j(this.text,e-this.offset)+this.offset}elt(e,t,r,n){if(typeof e=="string")return k(this.parser.getNodeType(e),t,r,n);return new ce(e,t)}}X.linkStart=O;X.imageStart=W;X.emphasisAsterisk=ge;X.emphasisUnderscore=me;function le(e,t){if(!t.length)return e;if(!e.length)return t;let r=e.slice(),n=0;for(let s of t){while(n<r.length&&r[n].to<s.to)n++;if(n<r.length&&r[n].from<s.from){let a=r[n];if(a instanceof z)r[n]=new z(a.type,a.from,a.to,le(a.children,[s]))}else r.splice(n++,0,s)}return r}var it=[c.CodeBlock,c.ListItem,c.OrderedList,c.BulletList];class at{constructor(e,t){if(this.fragments=e,this.input=t,this.i=0,this.fragment=null,this.fragmentEnd=-1,this.cursor=null,e.length)this.fragment=e[this.i++]}nextFragment(){this.fragment=this.i<this.fragments.length?this.fragments[this.i++]:null,this.cursor=null,this.fragmentEnd=-1}moveTo(e,t){while(this.fragment&&this.fragment.to<=e)this.nextFragment();if(!this.fragment||this.fragment.from>(e?e-1:0))return!1;if(this.fragmentEnd<0){let s=this.fragment.to;while(s>0&&this.input.read(s-1,s)!=`
|
|
6
|
-
`)s--;this.fragmentEnd=s?s-1:0}let r=this.cursor;if(!r)r=this.cursor=this.fragment.tree.cursor(S.IncludeAnonymous|S.IgnoreMounts),r.firstChild();let n=e+this.fragment.offset;while(r.to<=n)if(!r.parent())return!1;for(;;){if(r.from>=n)return this.fragment.from<=t;if(!r.childAfter(n))return!1}}matches(e){let t=this.cursor.tree;while(t&&t.type.isAnonymous&&t.children[0]instanceof E)t=t.children[0];return t&&t.prop(v.contextHash)==e}takeNodes(e){let t=this.cursor,r=this.fragment.offset,n=this.fragmentEnd-(this.fragment.openEnd?1:0),s=e.absoluteLineStart,a=s,l=e.block.children.length,h=e.lineStart-e.block.from>>2,f=a,d=l;e:for(;;){if(t.to-r>Math.min(n,e.to)||t.type.isAnonymous&&t.tree&&(t.to-t.from>h||!Ot(t.tree))){if(t.type.isAnonymous&&t.firstChild())continue;break}let m=ht(t.from-r,e.ranges);if(t.to-r<=e.ranges[e.rangeI].to)e.addNode(t.tree,m);else{let p=new E(e.parser.nodeSet.types[c.Paragraph],[],[],0,e.block.hashProp);e.reusePlaceholders.set(p,t.tree),e.addNode(p,m)}if(t.type.isAnonymous||t.type.is("Block")){if(t.type.isAnonymous||it.indexOf(t.type.id)<0)a=t.to-r,l=e.block.children.length;else a=f,l=d;f=t.to-r,d=e.block.children.length}for(;;){if(t.nextSibling())continue e;if(!t.parent()||!t.type.isAnonymous)break e}}while(e.block.children.length>l)e.block.children.pop(),e.block.positions.pop();return a-s}}function Ot(e){while(e.type.isAnonymous){let t=e.children[e.children.length-1];if(t instanceof E)e=t;else return!1}return e.type.is("Block")&&it.indexOf(e.type.id)<0}function ht(e,t){let r=e;for(let n=1;n<t.length;n++){let s=t[n-1].to,a=t[n].from;if(s<e)r-=a-s}return r}var Rt=I({"Blockquote/...":i.quote,HorizontalRule:i.contentSeparator,"ATXHeading1/... SetextHeading1/...":i.heading1,"ATXHeading2/... SetextHeading2/...":i.heading2,"ATXHeading3/...":i.heading3,"ATXHeading4/...":i.heading4,"ATXHeading5/...":i.heading5,"ATXHeading6/...":i.heading6,"Comment CommentBlock":i.comment,Escape:i.escape,Entity:i.character,"Emphasis/...":i.emphasis,"StrongEmphasis/...":i.strong,"Link/... Image/...":i.link,"OrderedList/... BulletList/...":i.list,"BlockQuote/...":i.quote,"InlineCode CodeText":i.monospace,"URL Autolink":i.url,"HeaderMark HardBreak QuoteMark ListMark LinkMark EmphasisMark CodeMark":i.processingInstruction,"CodeInfo LinkLabel":i.labelName,LinkTitle:i.string,Paragraph:i.content}),ft=new V(new nt(et).extend(Rt),Object.keys(K).map((e)=>K[e]),Object.keys(K).map((e)=>Je[e]),Object.keys(K),Pt,Fe,Object.keys(ne).map((e)=>ne[e]),Object.keys(ne),[]);function zt(e,t,r){let n=[];for(let s=e.firstChild,a=t;;s=s.nextSibling){let l=s?s.from:r;if(l>a)n.push({from:a,to:l});if(!s)break;a=s.to}return n}function ut(e){let{codeParser:t,htmlParser:r}=e;return{wrap:cn((s,a)=>{let l=s.type.id;if(t&&(l==c.CodeBlock||l==c.FencedCode)){let h="";if(l==c.FencedCode){let d=s.node.getChild(c.CodeInfo);if(d)h=a.read(d.from,d.to)}let f=t(h);if(f)return{parser:f,overlay:(d)=>d.type.id==c.CodeText,bracketed:l==c.FencedCode}}else if(r&&(l==c.HTMLBlock||l==c.HTMLTag||l==c.CommentBlock))return{parser:r,overlay:zt(s.node,s.from,s.to)};return null})}}var Tt={resolve:"Strikethrough",mark:"StrikethroughMark"},Ft={defineNodes:[{name:"Strikethrough",style:{"Strikethrough/...":i.strikethrough}},{name:"StrikethroughMark",style:i.processingInstruction}],parseInline:[{name:"Strikethrough",parse(e,t,r){if(t!=126||e.char(r+1)!=126||e.char(r+2)==126)return-1;let n=e.slice(r-1,r),s=e.slice(r+2,r+3),a=/\s|^$/.test(n),l=/\s|^$/.test(s),h=G.test(n),f=G.test(s);return e.addDelimiter(Tt,r,r+2,!l&&(!f||a||h),!a&&(!h||l||f))},after:"Emphasis"}]};function Q(e,t,r=0,n,s=0){let a=0,l=!0,h=-1,f=-1,d=!1,m=()=>{n.push(e.elt("TableCell",s+h,s+f,e.parser.parseInline(t.slice(h,f),s+h)))};for(let p=r;p<t.length;p++){let g=t.charCodeAt(p);if(g==124&&!d){if(!l||h>-1)a++;if(l=!1,n){if(h>-1)m();n.push(e.elt("TableDelimiter",p+s,p+s+1))}h=f=-1}else if(d||g!=32&&g!=9){if(h<0)h=p;f=p+1}d=!d&&g==92}if(h>-1){if(a++,n)m()}return a}function Ee(e,t){for(let r=t;r<e.length;r++){let n=e.charCodeAt(r);if(n==124)return!0;if(n==92)r++}return!1}var dt=/^[>\s]*\|?(\s*:?-+:?\s*\|)+(\s*:?-+:?\s*)?$/;class he{constructor(){this.rows=null}nextLine(e,t,r){if(this.rows==null){this.rows=!1;let n;if((t.next==45||t.next==58||t.next==124)&&dt.test(n=t.text.slice(t.pos))){let s=[];if(Q(e,r.content,0,s,r.start)==Q(e,n,0))this.rows=[e.elt("TableHeader",r.start,r.start+r.content.length,s),e.elt("TableDelimiter",e.lineStart+t.pos,e.lineStart+t.text.length)]}}else if(this.rows){let n=[];Q(e,t.text,t.pos,n,e.lineStart),this.rows.push(e.elt("TableRow",e.lineStart+t.pos,e.lineStart+t.text.length,n))}return!1}finish(e,t){if(!this.rows)return!1;return e.addLeafElement(t,e.elt("Table",t.start,t.start+t.content.length,this.rows)),!0}}var Xt={defineNodes:[{name:"Table",block:!0},{name:"TableHeader",style:{"TableHeader/...":i.heading}},"TableRow",{name:"TableCell",style:i.content},{name:"TableDelimiter",style:i.processingInstruction}],parseBlock:[{name:"Table",leaf(e,t){return Ee(t.content,0)?new he:null},endLeaf(e,t,r){if(r.parsers.some((s)=>s instanceof he)||!Ee(t.text,t.basePos))return!1;let n=e.peekLine();return dt.test(n)&&Q(e,t.text,t.basePos)==Q(e,n,t.basePos)},before:"SetextHeading"}]};class pt{nextLine(){return!1}finish(e,t){return e.addLeafElement(t,e.elt("Task",t.start,t.start+t.content.length,[e.elt("TaskMarker",t.start,t.start+3),...e.parser.parseInline(t.content.slice(3),t.start+3)])),!0}}var $t={defineNodes:[{name:"Task",block:!0,style:i.list},{name:"TaskMarker",style:i.atom}],parseBlock:[{name:"TaskList",leaf(e,t){return/^\[[ xX]\][ \t]/.test(t.content)&&e.parentType().name=="ListItem"?new pt:null},after:"SetextHeading"}]},Ie=/(www\.)|(https?:\/\/)|([\w.+-]{1,100}@)|(mailto:|xmpp:)/gy,He=/[\w-]+(\.[\w-]+)+(:\d+)?(\/[^\s<]*)?/gy,Dt=/[\w-]+\.[\w-]+($|[/:])/,ve=/[\w.+-]+@[\w-]+(\.[\w.-]+)+/gy,ye=/\/[a-zA-Z\d@.]+/gy;function Ne(e,t,r,n){let s=0;for(let a=t;a<r;a++)if(e[a]==n)s++;return s}function _t(e,t){He.lastIndex=t;let r=He.exec(e);if(!r||Dt.exec(r[0])[0].indexOf("_")>-1)return-1;let n=t+r[0].length;for(;;){let s=e[n-1],a;if(/[?!.,:*_~]/.test(s)||s==")"&&Ne(e,t,n,")")>Ne(e,t,n,"("))n--;else if(s==";"&&(a=/&(?:#\d+|#x[a-f\d]+|\w+);$/.exec(e.slice(t,n))))n=t+a.index;else break}return n}function Oe(e,t){ve.lastIndex=t;let r=ve.exec(e);if(!r)return-1;let n=r[0][r[0].length-1];return n=="_"||n=="-"?-1:t+r[0].length-(n=="."?1:0)}var Ut={parseInline:[{name:"Autolink",parse(e,t,r){let n=r-e.offset;if(n&&/\w/.test(e.text[n-1]))return-1;Ie.lastIndex=n;let s=Ie.exec(e.text),a=-1;if(!s)return-1;if(s[1]||s[2]){if(a=_t(e.text,n+s[0].length),a>-1&&e.hasOpenLink){let l=/([^\[\]]|\[[^\]]*\])*/.exec(e.text.slice(n,a));a=n+l[0].length}}else if(s[3])a=Oe(e.text,n);else if(a=Oe(e.text,n+s[0].length),a>-1&&s[0]=="xmpp:"){if(ye.lastIndex=a,s=ye.exec(e.text),s)a=s.index+s[0].length}if(a<0)return-1;return e.addElement(e.elt("URL",r,a+e.offset)),a+e.offset}}]},mt=[Xt,$t,Ft,Ut];function gt(e,t,r){return(n,s,a)=>{if(s!=e||n.char(a+1)==e)return-1;let l=[n.elt(r,a,a+1)];for(let h=a+1;h<n.end;h++){let f=n.char(h);if(f==e)return n.addElement(n.elt(t,a,h+1,l.concat(n.elt(r,h,h+1))));if(f==92)l.push(n.elt("Escape",h,h+++2));if(M(f))break}return-1}}var kt={defineNodes:[{name:"Superscript",style:i.special(i.content)},{name:"SuperscriptMark",style:i.processingInstruction}],parseInline:[{name:"Superscript",parse:gt(94,"Superscript","SuperscriptMark")}]},Lt={defineNodes:[{name:"Subscript",style:i.special(i.content)},{name:"SubscriptMark",style:i.processingInstruction}],parseInline:[{name:"Subscript",parse:gt(126,"Subscript","SubscriptMark")}]},bt={defineNodes:[{name:"Emoji",style:i.character}],parseInline:[{name:"Emoji",parse(e,t,r){let n;if(t!=58||!(n=/^[a-zA-Z_0-9]+:/.exec(e.slice(r+1,e.end))))return-1;return e.addElement(e.elt("Emoji",r,r+1+n[0].length))}}]};var At=Ct({commentTokens:{block:{open:"<!--",close:"-->"}}}),Bt=new v,Et=ft.configure({props:[Z.add((e)=>!e.is("Block")||e.is("Document")||be(e)!=null||jt(e)?void 0:(t,r)=>({from:r.doc.lineAt(t.from).to,to:t.to})),Bt.add(be),F.add({Document:()=>null}),ct.add({Document:At})]});function be(e){let t=/^(?:ATX|Setext)Heading(\d)$/.exec(e.name);return t?+t[1]:void 0}function jt(e){return e.name=="OrderedList"||e.name=="BulletList"}function qt(e,t){let r=e;for(;;){let n=r.nextSibling,s;if(!n||(s=be(n.type))!=null&&s<=t)break;r=n}return r.to}var Qt=Wi.of((e,t,r)=>{for(let n=T(e).resolveInner(r,-1);n;n=n.parent){if(n.from<t)break;let s=n.type.prop(Bt);if(s==null)continue;let a=qt(n,s);if(a>r)return{from:r,to:a}}return null});function we(e){return new _e(At,e,[],"markdown")}var Zt=we(Et),Gt=Et.configure([mt,Lt,kt,bt,{props:[Z.add({Table:(e,t)=>({from:t.doc.lineAt(e.from).to,to:e.to})})]}]),te=we(Gt);function Vt(e,t){return(r)=>{if(r&&e){let n=null;if(r=/\S*/.exec(r)[0],typeof e=="function")n=e(r);else n=un.matchLanguageName(e,r,!0);if(n instanceof un)return n.support?n.support.language.parser:xt.getSkippingParser(n.load());else if(n)return n.parser}return t?t.parser:null}}class ee{constructor(e,t,r,n,s,a,l){this.node=e,this.from=t,this.to=r,this.spaceBefore=n,this.spaceAfter=s,this.type=a,this.item=l}blank(e,t=!0){let r=this.spaceBefore+(this.node.name=="Blockquote"?">":"");if(e!=null){while(r.length<e)r+=" ";return r}else{for(let n=this.to-this.from-r.length-this.spaceAfter.length;n>0;n--)r+=" ";return r+(t?this.spaceAfter:"")}}marker(e,t){let r=this.node.name=="OrderedList"?String(+Mt(this.item,e)[2]+t):"";return this.spaceBefore+r+this.type+this.spaceAfter}}function It(e,t){let r=[],n=[];for(let s=e;s;s=s.parent){if(s.name=="FencedCode")return n;if(s.name=="ListItem"||s.name=="Blockquote")r.push(s)}for(let s=r.length-1;s>=0;s--){let a=r[s],l,h=t.lineAt(a.from),f=a.from-h.from;if(a.name=="Blockquote"&&(l=/^ *>( ?)/.exec(h.text.slice(f))))n.push(new ee(a,f,f+l[0].length,"",l[1],">",null));else if(a.name=="ListItem"&&a.parent.name=="OrderedList"&&(l=/^( *)\d+([.)])( *)/.exec(h.text.slice(f)))){let d=l[3],m=l[0].length;if(d.length>=4)d=d.slice(0,d.length-4),m-=4;n.push(new ee(a.parent,f,f+m,l[1],d,l[2],a))}else if(a.name=="ListItem"&&a.parent.name=="BulletList"&&(l=/^( *)([-+*])( {1,4}\[[ xX]\])?( +)/.exec(h.text.slice(f)))){let d=l[4],m=l[0].length;if(d.length>4)d=d.slice(0,d.length-4),m-=4;let p=l[2];if(l[3])p+=l[3].replace(/[xX]/," ");n.push(new ee(a.parent,f,f+m,l[1],d,p,a))}}return n}function Mt(e,t){return/^(\s*)(\d+)(?=[.)])/.exec(t.sliceString(e.from,e.from+10))}function ke(e,t,r,n=0){for(let s=-1,a=e;;){if(a.name=="ListItem"){let h=Mt(a,t),f=+h[2];if(s>=0){if(f!=s+1)return;r.push({from:a.from+h[1].length,to:a.from+h[0].length,insert:String(s+2+n)})}s=f}let l=a.nextSibling;if(!l)break;a=l}}function Se(e,t){let r=/^[ \t]*/.exec(e)[0].length;if(!r||t.facet(Xe)!="\t")return e;let n=Me(e,4,r),s="";for(let a=n;a>0;)if(a>=4)s+="\t",a-=4;else s+=" ",a--;return s+e.slice(r)}var Kt=(e={})=>({state:t,dispatch:r})=>{let n=T(t),{doc:s}=t,a=null,l=t.changeByRange((h)=>{if(!h.empty||!te.isActiveAt(t,h.from,-1)&&!te.isActiveAt(t,h.from,1))return a={range:h};let f=h.from,d=s.lineAt(f),m=It(n.resolveInner(f,-1),s);while(m.length&&m[m.length-1].from>f-d.from)m.pop();if(!m.length)return a={range:h};let p=m[m.length-1];if(p.to-p.spaceAfter.length>f-d.from)return a={range:h};let g=f>=p.to-p.spaceAfter.length&&!/\S/.test(d.text.slice(p.to));if(p.item&&g){if(p.item.from<d.from&&!/^[\s>]*$/.test(d.text.slice(0,p.to)))return a={range:h};let w=p.node.firstChild,x=p.node.getChild("ListItem","ListItem");if(w.to>=f||x&&x.to<f||d.from>0&&!/[^\s>]/.test(s.lineAt(d.from-1).text)||e.nonTightLists===!1){let C=m.length>1?m[m.length-2]:null,y,D="";if(C&&C.item)y=d.from+C.from,D=C.marker(s,1);else y=d.from+(C?C.to:0);let _=[{from:y,to:f,insert:D}];if(p.node.name=="OrderedList")ke(p.item,s,_,-2);if(C&&C.node.name=="OrderedList")ke(C.item,s,_);return{range:o.cursor(y+D.length),changes:_}}else{let C=St(m,t,d);return{range:o.cursor(f+C.length+1),changes:{from:d.from,insert:C+t.lineBreak}}}}if(p.node.name=="Blockquote"&&g&&d.from){let w=s.lineAt(d.from-1),x=/>\s*$/.exec(w.text);if(x&&x.index==p.from){let C=t.changes([{from:w.from+x.index,to:w.to},{from:d.from+p.from,to:d.to}]);return{range:h.map(C),changes:C}}}let L=[];if(p.node.name=="OrderedList")ke(p.item,s,L);let b=p.item&&p.item.from<d.from,H="";if(!b||/^[\s\d.)\-+*>]*/.exec(d.text)[0].length>=p.to)for(let w=0,x=m.length-1;w<=x;w++)H+=w==x&&!b?m[w].marker(s,1):m[w].blank(w<x?Me(d.text,4,m[w+1].from)-H.length:null);let P=f;while(P>d.from&&/\s/.test(d.text.charAt(P-d.from-1)))P--;if(H=Se(H,t),Yt(p.node,t.doc))H=St(m,t,d)+t.lineBreak+H;return L.push({from:P,to:f,insert:t.lineBreak+H}),{range:o.cursor(P+H.length+1),changes:L}});if(a)return!1;return r(t.update(l,{scrollIntoView:!0,userEvent:"input"})),!0},Jt=Kt();function wt(e){return e.name=="QuoteMark"||e.name=="ListMark"}function Yt(e,t){if(e.name!="OrderedList"&&e.name!="BulletList")return!1;let r=e.firstChild,n=e.getChild("ListItem","ListItem");if(!n)return!1;let s=t.lineAt(r.to),a=t.lineAt(n.from),l=/^[\s>]*$/.test(s.text);return s.number+(l?0:1)<a.number}function St(e,t,r){let n="";for(let s=0,a=e.length-2;s<=a;s++)n+=e[s].blank(s<a?Me(r.text,4,e[s+1].from)-n.length:null,s<a);return Se(n,t)}function Wt(e,t){let r=e.resolveInner(t,-1),n=t;if(wt(r))n=r.from,r=r.parent;for(let s;s=r.childBefore(n);)if(wt(s))n=s.from;else if(s.name=="OrderedList"||s.name=="BulletList")r=s.lastChild,n=r.to;else break;return r}var er=({state:e,dispatch:t})=>{let r=T(e),n=null,s=e.changeByRange((a)=>{let l=a.from,{doc:h}=e;if(a.empty&&te.isActiveAt(e,a.from)){let f=h.lineAt(l),d=It(Wt(r,l),h);if(d.length){let m=d[d.length-1],p=m.to-m.spaceAfter.length+(m.spaceAfter?1:0);if(l-f.from>p&&!/\S/.test(f.text.slice(p,l-f.from)))return{range:o.cursor(f.from+p),changes:{from:f.from+p,to:l}};if(l-f.from==p&&(m.item&&f.from<=m.item.from||/^[\s>]*$/.test(f.text.slice(0,m.to)))){let g=f.from+m.from;if(m.item&&m.node.from<m.item.from&&/\S/.test(f.text.slice(m.from,m.to))){let L=m.blank(Me(f.text,4,m.to)-Me(f.text,4,m.from));if(g==f.from)L=Se(L,e);return{range:o.cursor(g+L.length),changes:{from:g,to:f.from+m.to,insert:L}}}if(g<l)return{range:o.cursor(g),changes:{from:g,to:l}}}}}return n={range:a}});if(n)return!1;return t(e.update(s,{scrollIntoView:!0,userEvent:"delete"})),!0},tr=[{key:"Enter",run:Jt},{key:"Backspace",run:er}],Ht=an({matchClosingTags:!1});function vt(e={}){let{codeLanguages:t,defaultCodeLanguage:r,addKeymap:n=!0,base:{parser:s}=Zt,completeHTMLTags:a=!0,pasteURLAsLink:l=!0,htmlTagLanguage:h=Ht}=e;if(!(s instanceof V))throw RangeError("Base parser provided to `markdown` should be a Markdown parser");let f=e.extensions?[e.extensions]:[],d=[h.support,Qt],m;if(l)d.push(ir);if(r instanceof q)d.push(r.support),m=r.language;else if(r)m=r;let p=t||m?Vt(t,m):void 0;if(f.push(ut({codeParser:p,htmlParser:h.language.parser})),n)d.push(Pe.high(ot.of(tr)));let g=we(s.configure(f));if(a)d.push(g.data.of({autocomplete:rr}));return new q(g,d)}function rr(e){let{state:t,pos:r}=e,n=/<[:\-\.\w\u00b7-\uffff]*$/.exec(t.sliceDoc(r-25,r));if(!n)return null;let s=T(t).resolveInner(r,-1);while(s&&!s.type.isTop){if(s.name=="CodeBlock"||s.name=="FencedCode"||s.name=="ProcessingInstructionBlock"||s.name=="CommentBlock"||s.name=="Link"||s.name=="Image")return null;s=s.parent}return{from:r-n[0].length,to:r,options:nr(),validFor:/^<[:\-\.\w\u00b7-\uffff]*$/}}var Le=null;function nr(){if(Le)return Le;let e=zi(new ai(A.create({extensions:Ht}),0,!0));return Le=e?e.options:[]}var sr=/code|horizontalrule|html|link|comment|processing|escape|entity|image|mark|url/i,ir=u.domEventHandlers({paste:(e,t)=>{var r;let{main:n}=t.state.selection;if(n.empty)return!1;let s=(r=e.clipboardData)===null||r===void 0?void 0:r.getData("text/plain");if(!s||!/^(https?:\/\/|mailto:|xmpp:|www\.)/.test(s))return!1;if(/^www\./.test(s))s="https://"+s;if(!te.isActiveAt(t.state,n.from,1))return!1;let a=T(t.state),l=!1;if(a.iterate({from:n.from,to:n.to,enter:(h)=>{if(h.from>n.from||sr.test(h.name))l=!0},leave:(h)=>{if(h.to<n.to)l=!0}}),l)return!1;return t.dispatch({changes:[{from:n.from,insert:"["},{from:n.to,insert:`](${s})`}],userEvent:"input.paste",scrollIntoView:!0}),!0}});var Lr=()=>vt();export{Lr as language};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./chunk-index-4ecjtdy8.js";import"./chunk-index-zfd00hwb.js";import{yt}from"./chunk-index-9jqcskb4.js";import"./chunk-index-pcvt668q.js";var r=()=>yt({typescript:!0,jsx:!0});export{r as language};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Pr,Rt,ti,Ei,Ci,Fr,Zr,Ai,Wr,Yr}from"./chunk-index-ymbjrsp6.js";import"./chunk-index-gpkzhq1g.js";export{Ei as createFolder,Ai as deleteFolder,Yr as dropRoom,Rt as moveRoom,Wr as muteFolder,Zr as nudgeFolder,ti as nudgeRoom,Pr as pinRoom,Fr as placeFolderBefore,Ci as renameFolderTo};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Y,s,l,r,t,c,e,n,x,y,_,L,m,f,Q,se,rr}from"./chunk-index-31wh5twj.js";import{fe}from"./chunk-index-hk3xyy20.js";import{pe}from"./chunk-index-b9ny4623.js";import"./chunk-index-5d8yjj4m.js";var A=[{kind:"core",label:c("Core"),hint:c("Carried into every turn.")},{kind:"note",label:c("Note"),hint:c("Searched when the assistant needs them.")},{kind:"event",label:c("Events"),hint:c("Carried into every turn until their date.")}],q=300;function ee(){let{timeZone:u}=Q(),{version:o}=se(),[i,g]=r("core"),[v,N]=r(""),[b,w]=r(),[d,I]=r(),[h,D]=r(),[C,E]=r(),[k,T]=r(),K=fe(()=>m.principals(),"principals").data,P=l(0),S=Y(async(a)=>{let p=++P.current;try{let V=await m.notes(a.trim(),k);if(p!==P.current)return;w(V),I(void 0)}catch(V){if(p===P.current)I(f(V))}},[k]);s(()=>{let a=setTimeout(()=>void S(v),q);return()=>clearTimeout(a)},[v,S,o]);let R=(b??[]).filter((a)=>a.kind===i).sort((a,p)=>i==="event"?(a.eventDate??"").localeCompare(p.eventDate??""):a.id-p.id),W=rr(u);return n("section",{className:"stack",children:[n("div",{className:"card-head",children:[n("div",{children:[e("h2",{children:t("Notes")}),e("p",{className:"hint",children:t("What the assistant remembers. A change applies from the next turn.")})]}),e("button",{type:"button",onClick:()=>D({draft:{kind:i,fact:"",eventDate:""}}),children:t("Add")})]}),K&&K.principals.length>1?e(B,{people:K,shown:k,choose:(a)=>{w(void 0),T(a)}}):null,n("div",{className:"toolbar",children:[e("div",{className:"tabs",role:"tablist",children:A.map((a)=>n("button",{type:"button",role:"tab","aria-selected":i===a.kind,onClick:()=>g(a.kind),children:[t(a.label),b?` ${b.filter((p)=>p.kind===a.kind).length}`:""]},a.kind))}),e("input",{type:"search",placeholder:t("Search (words separated by spaces)"),"aria-label":t("Search notes"),value:v,onChange:(a)=>N(a.target.value)})]}),e("p",{className:"hint",children:t(A.find((a)=>a.kind===i)?.hint??"")}),d?e(y,{message:d}):null,!b?e(x,{}):R.length===0?e(_,{children:v?t("No matching notes."):t("Nothing of this kind yet.")}):R.map((a)=>e("article",{className:"card",children:n("div",{className:"card-head",children:[n("div",{children:[a.eventDate?n("p",{className:"meta",children:[a.eventDate," ",a.eventDate<W?e(L,{children:t("past")}):null]}):null,e("p",{className:"text",children:a.fact})]}),n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",onClick:()=>D({note:a,draft:{kind:a.kind,fact:a.fact,eventDate:a.eventDate??""}}),children:t("Edit")}),e("button",{type:"button",className:"danger",onClick:()=>E(a),children:t("Delete")})]})]})},a.id)),e(pe,{open:h!==void 0,title:h?.note?t("Edit note"):t("Add note"),onClose:()=>D(void 0),children:h?e(F,{initial:h.draft,save:async(a)=>{if(h.note)await m.updateNote(h.note.id,a,k);else await m.addNote(a,k);D((p)=>p===h?void 0:p),await S(v)},cancel:()=>D(void 0)}):null}),e(pe,{open:C!==void 0,title:t("Delete this note?"),onClose:()=>E(void 0),children:C?e(H,{text:C.fact,run:async()=>{await m.deleteNote(C.id,k),E((a)=>a===C?void 0:a),await S(v)},cancel:()=>E(void 0)}):null})]})}function B(u){let{people:o}=u;return n("label",{className:"inline",children:[t("Whose notes")," ",e("select",{value:u.shown??o.self,onChange:(i)=>u.choose(i.target.value===o.self?void 0:i.target.value),children:o.principals.map((i)=>e("option",{value:i.id,children:i.id===o.self?t("{name} (you)",{name:i.name}):i.disabled?t("{name} (disabled)",{name:i.name}):i.name},i.id))})]})}function F(u){let[o,i]=r(u.initial),[g,v]=r(!1),[N,b]=r(),w=async()=>{v(!0),b(void 0);try{await u.save({kind:o.kind,fact:o.fact,...o.kind==="event"&&o.eventDate?{eventDate:o.eventDate}:{}})}catch(d){b(f(d)),v(!1)}};return n("form",{className:"stack",onSubmit:(d)=>{d.preventDefault(),w()},children:[n("fieldset",{children:[e("legend",{children:t("Kind")}),e("div",{className:"tabs",children:A.map((d)=>e("button",{type:"button","aria-pressed":o.kind===d.kind,onClick:()=>i({...o,kind:d.kind}),children:t(d.label)},d.kind))})]}),o.kind==="event"?n("label",{children:[t("Date"),e("input",{type:"date",value:o.eventDate,onChange:(d)=>i({...o,eventDate:d.target.value})})]}):null,n("label",{children:[t("Text"),e("textarea",{rows:4,value:o.fact,onChange:(d)=>i({...o,fact:d.target.value})})]}),N?e(y,{message:N}):null,n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",onClick:u.cancel,children:t("Cancel")}),e("button",{type:"submit",disabled:g,children:g?t("Saving…"):t("Save")})]})]})}function H(u){let[o,i]=r(!1),[g,v]=r();return n("div",{className:"stack",children:[e("p",{className:"text",children:u.text}),g?e(y,{message:g}):null,n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",onClick:u.cancel,children:t("Cancel")}),e("button",{type:"button",className:"danger",disabled:o,onClick:()=>{i(!0),u.run().catch((N)=>{v(f(N)),i(!1)})},children:o?t("Deleting…"):t("Delete")})]})]})}export{ee as NotesPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r,t,c,p,e,n,C,x,y,_,L,m,f,Q,se,Ke,J,we,zn,Nt,Sn}from"./chunk-index-31wh5twj.js";import{fe}from"./chunk-index-hk3xyy20.js";import{pe}from"./chunk-index-b9ny4623.js";import"./chunk-index-5d8yjj4m.js";function g(a){let{cleanup:s}=Q(),[d,h]=r(),[l,o]=r(!1),[u,i]=r();if(!s)return null;let w=()=>{if(!l)h(void 0),i(void 0)};return n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",onClick:()=>h("start-over"),children:t("Start over")}),a.deletable?e("button",{type:"button",className:"danger",onClick:()=>h("delete"),children:t("Delete")}):null,n(pe,{open:d!==void 0,title:d==="delete"?t("Permanently delete {name}?",{name:a.title}):t("Start over {name}?",{name:a.title}),onClose:w,children:[e("p",{children:d==="delete"?t("The live conversation and all archives will be permanently deleted. Memory and schedules are preserved."):t("The current conversation will be archived; the next message starts a new one. Long-term memory is preserved. Active turns finish first.")}),u?e(y,{message:u}):null,n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",disabled:l,onClick:w,children:t("Cancel")}),e("button",{type:"button",className:d==="delete"?"danger":"",disabled:l,onClick:async()=>{if(!d)return;o(!0),i(void 0);try{if(d==="delete")await m.deleteConversation(a.channel);else await m.startOver(a.channel);h(void 0),a.refresh()}catch(k){i(f(k))}finally{o(!1)}},children:l?d==="delete"?t("Deleting…"):a.busy?t("Waiting for this turn…"):t("Starting over…"):d==="delete"?t("Delete permanently"):t("Start over")})]})]})]})}function K(){let a=Q(),{now:s}=se(),[d,h]=r(0),l=()=>h((i)=>i+1),{data:o,error:u}=fe(()=>m.overview(),`overview:${d}`);if(!o)return u?e(y,{message:u}):e(x,{});return n(p,{children:[u?e(y,{message:u}):null,n("section",{className:"stack",children:[e("h2",{children:t("Agent server")}),e("p",{className:"hint",children:t("Agent and group status; starting over archives the conversation and preserves memory.")}),o.agents.length+o.groups.length===0?e(_,{children:t("No agents.")}):null,o.agents.map((i)=>e(I,{agent:i,groups:o.groups,agents:o.agents,guildId:o.guildId,now:s,refresh:l},i.name)),o.groups.map((i)=>e(N,{group:i,guildId:o.guildId,now:s,timeZone:a.timeZone,refresh:l},i.name))]}),n("section",{className:"stack",children:[e("h2",{children:t("My workspaces")}),e("p",{className:"hint",children:t("Direct messages and channels where you mention the assistant. Start over archives; delete removes every archive permanently.")}),o.workspaces?.length?o.workspaces.map((i)=>e(b,{conversation:i,schedules:i.schedules,now:s,refresh:l},i.key)):e(_,{children:t("No workspaces.")})]}),n("section",{className:"stack",children:[e("h2",{children:t("Outside-agent conversations")}),e("p",{className:"hint",children:t("Conversations opened through remote MCP; after deletion the session ID cannot be resumed.")}),o.outside?.length?o.outside.map((i)=>e(b,{conversation:i,now:s,refresh:l},i.key)):e(_,{children:t("No outside-agent conversations.")})]}),n("section",{className:"stack",children:[e("h2",{children:t("Party channels")}),e("p",{className:"hint",children:t("Starting over stops the container and archives role conversations; each speaker's memory is preserved.")}),o.party?.length?o.party.map((i)=>e(A,{party:i,now:s,refresh:l},i.key)):e(_,{children:t("No party channels.")})]})]})}function v({busy:a}){return e(L,{tone:a?"busy":"plain",children:a===0?t("idle"):a===1?t("Working"):t("Working, {count} waiting",{count:a-1})})}function N(a){let{group:s,now:d,timeZone:h}=a;return n("article",{className:"card",children:[n("div",{className:"card-head",children:[s.channelId?e("a",{href:Sn(s.channelId,a.guildId),target:"_blank",rel:"noreferrer",children:s.displayName}):e("strong",{children:s.displayName}),e(L,{children:t("Group")}),e(v,{busy:s.busy})]}),e("p",{children:t("Members: {members} | Host: {host}",{members:s.members.join(", "),host:s.host})}),n("p",{className:"hint",children:[t("Last active")," ",Ke(s.lastActive,d,h)]}),s.channelId?e(g,{channel:`discord:${s.channelId}`,title:s.displayName,busy:s.busy>0,refresh:a.refresh}):null]})}function I(a){let{agent:s}=a,{timeZone:d,panes:h}=Q(),l=a.groups.find((i)=>i.channelId===s.workingIn),o=a.agents.find((i)=>i.channelId===s.workingIn),u=!s.workingIn?void 0:s.workingIn===s.channelId?t("Working in own channel"):l?t("Working in group {name}",{name:l.displayName}):o?t("Replying in {name}'s channel",{name:o.displayName}):t("Replying in another channel");return n("article",{className:"card",children:[n("div",{className:"card-head",children:[e("strong",{children:s.channelId?e("a",{href:Sn(s.channelId,a.guildId),target:"_blank",rel:"noreferrer",children:s.displayName}):s.displayName}),e(L,{children:"agent"}),s.workingIn?e(v,{busy:1+s.waiting}):s.waiting>0?e(L,{tone:"busy",children:t("{count} waiting",{count:s.waiting})}):e(L,{children:t("idle")})]}),u?e("p",{children:u}):null,n("dl",{className:"facts",children:[n("div",{children:[e("dt",{children:t("Model")}),n("dd",{children:[s.model," · thinking ",s.thinking]})]}),n("div",{children:[e("dt",{children:t("Context")}),e("dd",{children:s.context?s.context.tokens===null?t("Just compacted (limit {limit})",{limit:zn(s.context.contextWindow)}):`${zn(s.context.tokens)} / ${zn(s.context.contextWindow)} (${Math.round(s.context.tokens/s.context.contextWindow*100)}%)`:"—"})]}),n("div",{children:[e("dt",{children:t("Schedules")}),e("dd",{children:s.schedules})]}),n("div",{children:[e("dt",{children:t("Last active")}),e("dd",{children:Ke(s.lastActive,a.now,d)})]})]}),s.channelId?n(p,{children:[e(g,{channel:`discord:${s.channelId}`,title:s.displayName,busy:!!s.workingIn||s.waiting>0,refresh:a.refresh}),h.includes("conversations")?e("a",{href:C("conversations",`discord:${s.channelId}`),children:t("transcript")}):null]}):null]})}function b({conversation:a,schedules:s,now:d,refresh:h}){let{timeZone:l,panes:o}=Q(),{title:u,detail:i}=a.kind==="outside"?{title:a.firstMessage||t("(No messages)"),detail:a.id}:Nt(a.channel,a.id);return n("article",{className:"card",children:[n("div",{className:"card-head",children:[e("strong",{children:a.channel&&a.channel.kind!=="gone"?e("a",{href:Sn(a.id,a.channel.kind==="guild"?a.channel.guildId:void 0),target:"_blank",rel:"noreferrer",children:u}):u}),e(v,{busy:a.busy})]}),i?e("p",{className:"hint",children:i}):null,e("p",{children:a.liveBytes>0?t("Conversation {size} · Archives {count}",{size:we(a.liveBytes),count:a.archives}):t("No live conversation · Archives {count}",{count:a.archives})}),a.startedAt?n("p",{children:[t("Started")," ",J(a.startedAt,l)]}):null,n("p",{className:"hint",children:[s!==void 0?`${t("Schedules")} ${s} · `:"",t("Last active")," ",Ke(a.lastActive,d,l)]}),e(g,{channel:a.key,title:u,busy:a.busy>0,deletable:!0,refresh:h}),o.includes("conversations")?e("a",{href:C("conversations",a.key),children:t("transcript")}):null]})}function A({party:a,now:s,refresh:d}){let{timeZone:h}=Q(),{title:l,detail:o}=Nt(a.channel,a.channelId),u={running:c("Container running"),stopped:c("Container stopped"),missing:c("No container yet"),unknown:c("Container status unknown")};return n("article",{className:"card",children:[n("div",{className:"card-head",children:[e("strong",{children:a.channel.kind!=="gone"?e("a",{href:Sn(a.channelId,a.channel.kind==="guild"?a.channel.guildId:void 0),target:"_blank",rel:"noreferrer",children:l}):l}),e(L,{children:a.profile}),e(L,{children:t(u[a.container])}),e(v,{busy:a.busy})]}),o?e("p",{className:"hint",children:o}):null,e("p",{children:t("Enabled by {name} at {time}",{name:a.enabledBy,time:J(a.enabledAt,h)})}),n("p",{className:"hint",children:[t("Last active")," ",Ke(a.lastActive,s,h)]}),e(g,{channel:a.key,title:l,busy:a.busy>0,refresh:d})]})}export{K as OverviewPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s,X,l,r,t,e,n,a,C,H,d,oe,Lt}from"./chunk-index-31wh5twj.js";import{On}from"./chunk-index-bvfqjh77.js";import{N}from"./chunk-index-5d8yjj4m.js";function I(m){let[f,v]=r(""),[p,h]=r(0),g=l(null),b=d((i)=>i.order.flatMap((o)=>{let c=i.rooms[o]?.view;return c?[{key:o,name:c.displayName,agent:c.name,character:c.character,kind:c.kind}]:[]})),u=X(()=>[...b.map((o)=>({id:o.key,label:o.name,hint:o.kind==="agent"?t("Agent"):o.kind==="group"?t("Group"):t("Thread"),room:!0,...o.kind==="agent"?{avatar:{name:o.agent,character:o.character}}:{icon:"conversations"},go:()=>H("room",o.key)})),...m.pages.map((o)=>({id:o.pane,label:o.label,hint:t("Page"),icon:o.icon,go:()=>H(o.pane)}))].flatMap((o)=>{let c=On(f,o.label);return c===void 0?[]:[{target:o,score:c}]}).sort((o,c)=>c.score-o.score).map((o)=>o.target).slice(0,12),[b,m.pages,f]);s(()=>h(0),[f]),s(()=>{if(m.open)v(""),requestAnimationFrame(()=>g.current?.focus())},[m.open]);let y=(i)=>{if(!i)return;m.onClose(),i.go()};return e(N,{open:m.open,title:t("Find a room"),onClose:m.onClose,variant:"palette",children:n("div",{className:"palette-box",children:[n("div",{className:"palette-input",children:[e(a,{name:"search",size:18}),e("input",{ref:g,value:f,placeholder:t("Find a room or page"),"aria-label":t("Find a room or page"),role:"combobox","aria-expanded":"true","aria-controls":"palette-list","aria-activedescendant":u[p]?`palette-${p}`:void 0,onChange:(i)=>v(i.target.value),onKeyDown:(i)=>{if(Lt(i.nativeEvent))return;if(i.key==="ArrowDown")i.preventDefault(),h((o)=>Math.min(u.length-1,o+1));else if(i.key==="ArrowUp")i.preventDefault(),h((o)=>Math.max(0,o-1));else if(i.key==="Enter")i.preventDefault(),y(u[p])}}),e("kbd",{children:"Esc"})]}),n("ul",{className:"palette-list",children:[u.length===0?e("li",{className:"palette-empty",children:t("Nothing matches.")}):null,u.map((i,o)=>e("li",{"data-active":o===p||void 0,children:n("a",{href:i.room?C("room",i.id):C(i.id),onClick:(c)=>{c.preventDefault(),y(i)},onMouseMove:()=>h(o),"aria-current":o===p?"true":void 0,children:[i.avatar?e(oe,{spec:i.avatar.character,name:i.avatar.name,size:28,live:!1}):e("span",{className:"palette-icon",children:e(a,{name:i.icon??"list",size:16})}),e("span",{className:"palette-label",children:i.label}),e("span",{className:"meta",children:i.hint})]})},i.id))]})]})})}export{I as Palette};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{pi,Gr}from"./chunk-index-k7gh0jvz.js";import"./chunk-index-12bw9yj8.js";import"./chunk-index-gpkzhq1g.js";export{Gr as folderMenu,pi as placementItems};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s,r,t,e,n,x,y,_,L,f,Q,J}from"./chunk-index-31wh5twj.js";import{We}from"./chunk-index-jm23vn03.js";import{N}from"./chunk-index-5d8yjj4m.js";function T(a){let{open:m,load:b}=a,{timeZone:v}=Q(),[i,d]=r(),[u,p]=r(),[g,h]=r();s(()=>{if(!m)return;let o=!0;return d(void 0),p(void 0),h(void 0),b().then((c)=>o&&d(c),(c)=>o&&p(f(c))),()=>{o=!1}},[m]);let l=i?.find((o)=>o.id===g);return e(N,{open:m,title:a.title,size:"wide",onClose:a.onClose,children:n("div",{className:"stack history",children:[u?e(y,{message:u}):null,!i&&!u?e(x,{}):null,i?.length===0?e(_,{children:t("No changes have been kept yet.")}):null,i&&i.length>0?e("ul",{className:"menu",children:i.map((o)=>e("li",{children:n("button",{type:"button",className:"menu-item","aria-pressed":o.id===g,onClick:()=>h(o.id),children:[n("span",{className:"menu-text",children:[e("strong",{children:o.by}),e("span",{className:"meta",children:J(o.at,v)})]}),o.revert?e(L,{children:t("Back to the file version")}):null]})},o.id))}):null,l?n("section",{className:"stack","aria-label":t("This change"),children:[e(We,{label:t("This change"),before:l.previous,after:l.text}),e("p",{className:"meta",children:t("It goes into the editor, where you read it over and save it to put it in force.")}),e("div",{className:"actions",children:e("button",{type:"button",onClick:()=>a.onUse(l.text),children:t("Use this text")})})]}):null]})})}export{T as HistorySheet};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{O,W,P,Y,s,D,r,t,c,p,e,n,a,x,y,_,L,h,me,f,Q,J}from"./chunk-index-31wh5twj.js";import{ke,We}from"./chunk-index-jm23vn03.js";import{N}from"./chunk-index-5d8yjj4m.js";var I={"Shared prompt":c("Shared prompt"),"Guest prompt":c("Guest prompt"),"The base every agent's prompt starts with, the main assistant's included.":c("The base every agent's prompt starts with, the main assistant's included."),"Used instead of the shared prompt when the person speaking is not the owner.":c("Used instead of the shared prompt when the person speaking is not the owner.")},w=(l)=>t(I[l]??l);var U=P(()=>(O("yrqehads"),import("./chunk-prompt-history-yrqehads.js")).then((l)=>({default:l.HistorySheet}))),G=P(()=>(O("xrw7d732"),import("./chunk-confirm-xrw7d732.js")).then((l)=>({default:l.Confirm})));function pe(){let{timeZone:l}=Q(),[k,i]=r(),[d,g]=r(),[u,b]=r(),C=Y(()=>{ke.prompts().then((m)=>i(m.documents),(m)=>g(f(m)))},[]);return s(C,[C]),n("div",{className:"page",children:[e("header",{className:"page-head",children:e("h1",{children:t("Main prompts")})}),e("p",{className:"hint",children:t("The texts the assistant and the agents start from. A text you save here replaces the one from the file from the next turn on, until you go back to the file's.")}),d?e(y,{message:d}):null,!k&&!d?e(x,{}):null,k?.length===0?e(_,{children:t("No prompts to edit.")}):null,k?.map((m)=>n("article",{className:"card stack",children:[n("div",{className:"card-head",children:[e("strong",{children:w(m.label)}),m.differs?e(L,{tone:"warn",children:t("Differs from the file version")}):null,m.broken?e(L,{tone:"warn",children:t("File version cannot be read")}):null]}),m.description?e("p",{children:w(m.description)}):null,m.override?e("p",{className:"hint",children:t("Set by {name}, {time}",{name:m.override.by,time:J(m.override.at,l)})}):null,e("div",{className:"actions",children:e("button",{type:"button",onClick:()=>b(m.id),children:t("Edit")})})]},m.id)),u?e(M,{id:u,onClose:()=>{b(void 0),C()}}):null]})}function M({id:l,onClose:k}){let[i,d]=r(),[g,u]=r(""),[b,C]=r(),[m,S]=r(!1),[R,T]=r(!1),[B,E]=r(!1),[H,V]=r(!1),F=D();s(()=>{let o=!0;return ke.prompt(l).then((v)=>{if(!o)return;d(v),u(v.text)},(v)=>o&&C(f(v))),()=>{o=!1}},[l]);let z=async()=>{if(!i)return;T(!0);try{let o=await ke.savePrompt(l,{text:g,base:i.text});d(o),u(o.text),S(!1),h(t("Saved."))}catch(o){if(o instanceof me&&o.status===409){let{current:v}=o.body;d(v),h(o.message,"danger")}else h(f(o),"danger")}finally{T(!1)}},A=i!==void 0&&g!==i.text;return n(N,{open:!0,title:i?w(i.label):t("Main prompts"),size:"full",onClose:k,children:[b?e(y,{message:b}):null,!i&&!b?e(x,{}):null,i?.broken?e(y,{message:t("The file version of this prompt cannot be read, so it cannot be changed here until it can: {reason}",{reason:i.broken})}):null,i&&!i.broken?n("div",{className:"stack",children:[i.differs?e("p",{className:"hint",children:e(L,{tone:"warn",children:t("Differs from the file version")})}):null,m?n("section",{className:"stack review","aria-label":t("Review changes"),children:[e("h3",{children:t("Review changes")}),e(We,{label:t("Prompt"),before:i.text,after:g}),n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",disabled:R,onClick:()=>S(!1),children:t("Back to editing")}),e("button",{type:"button",disabled:R,onClick:z,children:R?t("Saving…"):t("Save")})]})]}):n(p,{children:[n("div",{className:"field",children:[n("div",{className:"field-head",children:[e("label",{htmlFor:F,children:t("Prompt")}),e("span",{className:"field-tools",children:n("button",{type:"button",className:"secondary compact","aria-haspopup":"dialog",onClick:()=>E(!0),children:[e(a,{name:"reset",size:16}),t("History")]})})]}),e("textarea",{id:F,className:"prompt-full",value:g,maxLength:i.maxChars,onChange:(o)=>u(o.target.value)})]}),n("div",{className:"actions",children:[i.override?e("button",{type:"button",className:"secondary",onClick:()=>V(!0),children:t("Revert to the file version")}):null,e("button",{type:"button",disabled:!A||!g.trim(),onClick:()=>S(!0),children:t("Review changes")})]})]}),B?e(W,{fallback:null,children:e(U,{open:B,title:t("History of {name}",{name:w(i.label)}),load:async()=>(await ke.promptHistory(l)).versions.map((o)=>({id:o.id,text:o.text,previous:o.previous,by:o.by,at:o.at,revert:o.action==="revert"})),onUse:(o)=>{u(o),S(!1),E(!1)},onClose:()=>E(!1)})}):null,H?e(W,{fallback:null,children:e(G,{open:H,title:t("Revert {name} to the file version?",{name:w(i.label)}),confirmLabel:t("Revert to the file version"),tone:"danger",onConfirm:async()=>{try{let o=await ke.revertPrompt(l,{base:i.text});d(o),u(o.text),S(!1),h(t("Back to the file version."))}catch(o){if(!(o instanceof me&&o.status===409))throw o;let{current:v}=o.body;d(v),h(o.message,"danger")}},onClose:()=>V(!1),children:e("p",{children:t("The text you saved is dropped and the text from the file applies from the next turn. It stays in the history, so you can bring it back.")})})}):null]}):null]})}export{pe as PromptsPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{oi}from"./chunk-index-4v1b7ks9.js";import"./chunk-index-b9ny4623.js";import"./chunk-index-ky42ev0b.js";import"./chunk-index-5d8yjj4m.js";import"./chunk-index-12bw9yj8.js";import"./chunk-index-ymbjrsp6.js";import"./chunk-index-gpkzhq1g.js";export{oi as RoomConfirmHost};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{O,r,t,p,e,n,a,C,d,dt,De,Te,st}from"./chunk-index-31wh5twj.js";import{Se}from"./chunk-index-12bw9yj8.js";import{Ye}from"./chunk-index-27qca4mr.js";import{ze}from"./chunk-index-pa2yyqh0.js";import{N}from"./chunk-index-5d8yjj4m.js";var c="room-menu-yolo",g="room-menu-long",h="room-menu-mute";function D(o){let[l,m]=r(!1),b=d((s)=>s.rooms[o.room]?.view?.home===!1,o.room),i=d((s)=>s.pins.includes(o.room),o.room),u=o.mode??{yolo:!1,longRunning:!1},f=async(s)=>{m(!0),await dt(o.room,{longRunning:s}),m(!1)};return e(N,{open:o.open,title:t("Room menu"),onClose:o.onClose,children:n("ul",{className:"menu",children:[o.readOnly?e("li",{children:o.parent?n("a",{className:"menu-item menu-link",href:C("room",o.parent),onClick:o.onClose,children:[e("span",{className:"menu-icon",children:e(a,{name:"rooms"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Open the parent room")}),e("span",{className:"meta",children:t("Reply to the agent that started this thread.")})]}),e(a,{name:"chevron",size:16})]}):e("p",{className:"meta",children:t("A thread has no settings.")})}):null,o.readOnly?null:e("li",{children:n("label",{className:"menu-item menu-toggle",htmlFor:h,children:[e("span",{className:"menu-icon",children:e(a,{name:o.muted?"bell-off":"bell"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Notifications")}),e("span",{className:"meta",children:t("Push this room's posts to every owner's devices. A card that waits for you is always pushed.")})]}),e(Ye,{id:h,checked:!o.muted,label:t("Notifications"),onChange:async(s)=>{m(!0),await ze(o.room,!s),m(!1)},busy:l})]})}),o.readOnly?null:e("li",{children:n("label",{className:"menu-item menu-toggle",htmlFor:c,children:[e("span",{className:"menu-icon","data-tone":"yolo",children:e(a,{name:"bolt"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Yolo mode")}),e("span",{className:"meta",children:t("Approve held actions in this room without asking. Risky ones still ask.")})]}),e(Ye,{id:c,checked:u.yolo,label:t("Yolo mode"),onChange:(s)=>{if(s)o.onAskYolo();else m(!0),dt(o.room,{yolo:!1}).then(()=>m(!1))},busy:l})]})}),o.readOnly?null:e("li",{children:n("label",{className:"menu-item menu-toggle",htmlFor:g,children:[e("span",{className:"menu-icon","data-tone":"long",children:e(a,{name:"timer"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Long-running mode")}),e("span",{className:"meta",children:t("Let turns go on past their time limit, up to the host's cap. Questions still wait for you.")})]}),e(Ye,{id:g,checked:u.longRunning,label:t("Long-running mode"),onChange:f,busy:l})]})}),o.agent?e("li",{children:n("button",{type:"button",className:"menu-item menu-link","aria-haspopup":"dialog",onClick:()=>{o.onClose(),De(o.agent)},children:[e("span",{className:"menu-icon",children:e(a,{name:"profile"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Edit agent")}),e("span",{className:"meta",children:t("Name, prompt, model and picture")})]}),e(a,{name:"chevron",size:16})]})}):null,o.group?e("li",{children:n("button",{type:"button",className:"menu-item menu-link","aria-haspopup":"dialog",onClick:()=>{o.onClose(),st({kind:"group",name:o.group})},children:[e("span",{className:"menu-icon",children:e(a,{name:"profile"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Edit group")}),e("span",{className:"meta",children:t("Name, members and host")})]}),e(a,{name:"chevron",size:16})]})}):null,o.readOnly||!b?null:n(p,{children:[e("li",{children:n("button",{type:"button",className:"menu-item menu-link",onClick:()=>{o.onClose(),(O("bv0chj41"),import("./chunk-layout-actions-bv0chj41.js")).then((s)=>s.pinRoom(o.room,!i))},children:[e("span",{className:"menu-icon",children:e(a,{name:"pin"})}),n("span",{className:"menu-text",children:[e("strong",{children:i?t("Unpin"):t("Pin")}),e("span",{className:"meta",children:t("Keep this room at the top of the list.")})]})]})}),e("li",{children:n("button",{type:"button",className:"menu-item menu-link","aria-haspopup":"dialog",onClick:()=>{o.onClose(),Se({kind:"move",room:o.room})},children:[e("span",{className:"menu-icon",children:e(a,{name:"folder"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Move to folder…")}),e("span",{className:"meta",children:t("Put this room in a folder, or take it out.")})]}),e(a,{name:"chevron",size:16})]})})]}),o.readOnly?null:e("li",{children:n("button",{type:"button",className:"menu-item menu-link",onClick:o.onAskStartOver,children:[e("span",{className:"menu-icon","data-tone":"danger",children:e(a,{name:"reset"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Start over")}),e("span",{className:"meta",children:t("Archive this conversation and begin a new one. Memory stays.")})]})]})}),o.readOnly||o.coordinator?null:e("li",{children:n("button",{type:"button",className:"menu-item menu-link",onClick:()=>{o.onClose(),Te({kind:"archive",room:o.room,name:o.displayName??""})},children:[e("span",{className:"menu-icon","data-tone":"danger",children:e(a,{name:"archive"})}),n("span",{className:"menu-text",children:[e("strong",{children:o.group?t("Archive group"):t("Archive agent")}),e("span",{className:"meta",children:t("It stops answering. The history is kept and it can be restored.")})]})]})})]})})}export{D as RoomMenu};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t,e,a,d}from"./chunk-index-31wh5twj.js";import"./chunk-index-12bw9yj8.js";import{yn}from"./chunk-index-89ajmxh7.js";function r(){if(!d((o)=>o.listed))return null;return e("button",{type:"button",className:"header-button icon-button","aria-haspopup":"menu","aria-label":t("Folders and order"),onClick:(o)=>yn(o.currentTarget),children:e(a,{name:"more",size:18})})}export{r as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r,t,c,e,n,a,C,x,y,_,L,h,m,Q,J}from"./chunk-index-31wh5twj.js";import{re}from"./chunk-index-ky42ev0b.js";import{fe}from"./chunk-index-hk3xyy20.js";import"./chunk-index-5d8yjj4m.js";var g={mon:c("Mon"),tue:c("Tue"),wed:c("Wed"),thu:c("Thu"),fri:c("Fri"),sat:c("Sat"),sun:c("Sun")};function w(d){if(typeof d!=="object"||d===null)return"";let i=d,s=typeof i.time==="string"?i.time:"";switch(i.kind){case"once":return t("Once on {date} at {time}",{date:String(i.date??""),time:s});case"every":return Number(i.everyDays)===1?t("Every day at {time}",{time:s}):t("Every {count} days at {time}",{count:Number(i.everyDays),time:s});case"weekly":{let l=Array.isArray(i.weekdays)?i.weekdays.map((u)=>t(g[String(u)]??String(u))).join(t(", ")):"";return t("{days} at {time}",{days:l,time:s})}default:return""}}function T(){let{timeZone:d}=Q(),[i,s]=r(0),[l,u]=r(),{data:p,error:f}=fe(()=>m.schedules(),`schedules:${i}`);return n("div",{className:"page",children:[e("header",{className:"page-head",children:e("h1",{children:t("Schedules")})}),f?e(y,{message:f}):null,!p&&!f?e(x,{}):null,p&&p.schedules.length===0?e(_,{children:t("Nothing is scheduled. Ask an agent to remind you or to run something later.")}):null,e("ul",{className:"schedule-list",children:p?.schedules.map((o)=>n("li",{className:"card schedule",children:[n("div",{className:"schedule-main",children:[n("div",{className:"card-head",children:[e("strong",{children:o.title}),o.lastStatus?e(L,{children:o.lastStatus}):null]}),n("p",{className:"meta",children:[w(o.recurrence)," ·"," ",t("next {when}",{when:J(o.nextRun,d)})]}),e("p",{className:"schedule-prompt",children:o.prompt}),n("p",{className:"meta",children:[o.room?e("a",{href:C("room",o.room),children:o.label}):o.label," ","· ",t("set by {name}",{name:o.createdBy})]})]}),e("button",{type:"button",className:"icon-button danger-icon","aria-label":t("Cancel {title}",{title:o.title}),onClick:()=>u(o),children:e(a,{name:"trash"})})]},o.id))}),e(re,{open:l!==void 0,title:t("Cancel this schedule?"),confirmLabel:t("Cancel schedule"),tone:"danger",onClose:()=>u(void 0),onConfirm:async()=>{if(!l)return;await m.cancelSchedule(l.id),s((o)=>o+1),h(t("Schedule cancelled."))},children:e("p",{children:t("“{title}” will not run again. Runs that already happened stay in the conversation.",{title:l?.title??""})})})]})}export{T as SchedulesPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{O,W,P,Y,s,D,X,l,r,t,c,p,e,n,a,H,d,x,y,_,h,me,m,f,oe,Kt,It,sr,or,Te,kn,ur}from"./chunk-index-31wh5twj.js";import{re}from"./chunk-index-ky42ev0b.js";import"./chunk-index-12bw9yj8.js";import"./chunk-index-ymbjrsp6.js";import{ye,rt,oi}from"./chunk-index-4v1b7ks9.js";import{Vt}from"./chunk-index-18gxy79n.js";import{ke,We}from"./chunk-index-jm23vn03.js";import"./chunk-index-b9ny4623.js";import{Ye}from"./chunk-index-27qca4mr.js";import{ze}from"./chunk-index-pa2yyqh0.js";import{N}from"./chunk-index-5d8yjj4m.js";import"./chunk-index-gpkzhq1g.js";function se(i){return n("fieldset",{className:"field",children:[e("legend",{children:i.label}),e("div",{className:"option-chips",children:i.options.map((u)=>e("button",{type:"button","aria-pressed":u.value===i.value,className:"option-chip",onClick:()=>i.onChange(u.value),children:u.label},u.value))})]})}var Fe=P(()=>(O("yrqehads"),import("./chunk-prompt-history-yrqehads.js")).then((i)=>({default:i.HistorySheet}))),Re=P(()=>(O("6yf29xwx"),import("./chunk-character-creator-6yf29xwx.js")).then((i)=>({default:i.CharacterCreator}))),xe=["default","off","minimal","low","medium","high","xhigh"],ve={default:c("Follow the assistant (automatic)"),off:c("Off"),minimal:c("Minimal"),low:c("Low"),medium:c("Medium"),high:c("High"),xhigh:c("Very high")},z="default",ce=(i)=>t(ve[i]??i),he=(i)=>({displayName:i.displayName,prompt:i.prompt,model:i.model??z,thinking:i.thinking??z});function ge(i,u){return{...u.displayName!==i.displayName?{displayName:u.displayName}:{},...u.prompt!==i.prompt?{prompt:u.prompt}:{},...u.model!==(i.model??z)?{model:u.model}:{},...u.thinking!==(i.thinking??z)?{thinking:u.thinking}:{}}}function be(){let i=or(),u=l(i);if(i)u.current=i;let o=u.current,w=i!==void 0;if(s(()=>{if(!w)return;let E=window.location.href,A=()=>{if(window.location.href!==E)It()};return window.addEventListener("popstate",A),window.addEventListener("hashchange",A),()=>{window.removeEventListener("popstate",A),window.removeEventListener("hashchange",A)}},[w]),!o)return null;return e(N,{open:i!==void 0,title:t("Edit agent"),size:"wide",onClose:It,children:e(He,{name:o.name,opened:o.id},o.name)})}function He({name:i,opened:u}){let[o,w]=r(),[E,A]=r([]),[k,T]=r(),[C,F]=r(),[g,I]=r(!1),[L,V]=r(!1),[Z,J]=r(!1),[G,K]=r(!1),ee=Kt(o?.room??""),U=l(null),j=o!==void 0,B=d((b)=>o?b.rooms[o.room]?.view?.muted===!0:!1,o?.room??""),[te,R]=r(!1),ae=d((b)=>o?b.rooms[o.room]?.view?.coordinator===!0:!1,o?.room??""),q=D(),Q=D(),S=D();s(()=>{if(!j||!sr()?.look)return;U.current?.scrollIntoView({block:"start"}),U.current?.focus({preventScroll:!0})},[j,u]);let v=l({});v.current={profile:o,draft:C},s(()=>{let b=!0;return Promise.all([m.agent(i),m.models()]).then(([ie,De])=>{if(!b)return;let{profile:fe,draft:le}=v.current,Pe=fe&&le&&Object.keys(ge(fe,le)).length>0;w(ie),A(De.models),F(Pe?le:he(ie))},(ie)=>b&&T(f(ie))),()=>{b=!1}},[i,u]);let M=X(()=>o&&C?ge(o,C):{},[o,C]);if(k)return e(y,{message:k});if(!o||!C)return e(x,{});let pe=Object.keys(M).length>0,Ie=Array.from(new Set([z,...E,C.model])),ue=async()=>{I(!0);try{let b=await m.updateAgent(i,M);w(b),F(he(b)),V(!1),h(t("Saved."))}catch(b){h(f(b),"danger")}finally{I(!1)}};return n("div",{className:"stack agent-sheet",children:[n("header",{className:"profile-head",children:[e(oe,{spec:o.character,name:o.name,size:72,state:ee,label:o.displayName}),n("div",{children:[e("h3",{children:o.displayName}),e("p",{className:"meta",children:t("Runs on {model}, thinking {thinking}",{model:o.effective.model,thinking:ce(o.effective.thinking)})})]})]}),e("ul",{className:"menu",children:e("li",{children:n("label",{className:"menu-item menu-toggle",htmlFor:S,children:[e("span",{className:"menu-icon",children:e(a,{name:B?"bell-off":"bell"})}),n("span",{className:"menu-text",children:[e("strong",{children:t("Notifications")}),e("span",{className:"meta",children:t("Push this room's posts to every owner's devices. A card that waits for you is always pushed.")})]}),e(Ye,{id:S,checked:!B,label:t("Notifications"),busy:te,onChange:async(b)=>{R(!0),await ze(o.room,!b),R(!1)}})]})})}),L?e(Ve,{profile:o,draft:C,saving:g,onBack:()=>V(!1),onSave:ue}):n("form",{className:"stack form",onSubmit:(b)=>{if(b.preventDefault(),!pe)return;if(M.prompt!==void 0)V(!0);else ue()},children:[n("label",{htmlFor:Q,children:[t("Name"),e("input",{id:Q,value:C.displayName,onChange:(b)=>F({...C,displayName:b.target.value})})]}),n("div",{className:"field",children:[n("div",{className:"field-head",children:[e("label",{htmlFor:q,children:t("Prompt")}),n("span",{className:"field-tools",children:[n("button",{type:"button",className:"secondary compact","aria-haspopup":"dialog",onClick:()=>K(!0),children:[e(a,{name:"reset",size:16}),t("History")]}),n("button",{type:"button",className:"secondary compact","aria-haspopup":"dialog",onClick:()=>J(!0),children:[e($e,{}),t("Full screen")]})]})]}),e("textarea",{id:q,rows:8,value:C.prompt,onChange:(b)=>F({...C,prompt:b.target.value})})]}),e(se,{label:t("Model"),value:C.model,onChange:(b)=>F({...C,model:b}),options:Ie.map((b)=>({value:b,label:b===z?t("Follow the assistant"):b}))}),e(se,{label:t("Thinking level"),value:C.thinking,onChange:(b)=>F({...C,thinking:b}),options:xe.map((b)=>({value:b,label:t(ve[b])}))}),e("div",{className:"actions",children:e("button",{type:"submit",disabled:!pe||g,children:g?t("Saving…"):M.prompt!==void 0?t("Review changes"):t("Save")})})]}),e(Oe,{name:i,opened:u}),n("section",{className:"card stack",ref:U,tabIndex:-1,children:[e("h3",{children:t("Look")}),e("p",{className:"meta",children:t("Class, colors and parts. The picture here, in the rooms and in Discord all follow it.")}),e(W,{fallback:e(x,{}),children:e(Re,{name:o.name,displayName:o.displayName,prompt:o.prompt,character:o.character,onSaved:(b)=>w(b)})})]}),ae?null:n("section",{className:"card stack",children:[e("h3",{children:t("Archive")}),e("p",{className:"meta",children:t("An archived agent stops answering and its schedules are cancelled. Its history is kept, and you can restore it from Archived.")}),e("div",{className:"actions",children:e("button",{type:"button",className:"danger",onClick:()=>{It(),Te({kind:"archive",room:o.room,name:o.displayName})},children:t("Archive {name}",{name:o.displayName})})})]}),G?e(W,{fallback:null,children:e(Fe,{open:G,title:t("History of the prompt"),load:async()=>(await ke.agentPromptHistory(i)).versions.map((b)=>({id:b.id,text:b.text,previous:b.previous,by:b.by,at:b.at})),onUse:(b)=>{F({...C,prompt:b}),K(!1)},onClose:()=>K(!1)})}):null,e(N,{open:Z,title:t("Prompt"),size:"full",onClose:()=>J(!1),children:e("textarea",{className:"prompt-full","aria-label":t("Prompt"),value:C.prompt,onChange:(b)=>F({...C,prompt:b.target.value})})})]})}function Oe({name:i,opened:u}){let[o,w]=r(),[E,A]=r(),[k,T]=r(),C=D();if(s(()=>{let g=!0;return ye.skills(i).then((I)=>g&&w(I),(I)=>{if(g&&!(I instanceof me&&I.status===404))T(f(I))}),()=>{g=!1}},[i,u]),k)return e(y,{message:k});if(!o)return null;let F=async(g,I)=>{A(g);try{w(await ye.setSkills(i,I?{add:[g]}:{remove:[g]}))}catch(L){h(f(L),"danger")}finally{A(void 0)}};return n("section",{className:"card stack","aria-label":t("Skills"),children:[e("h3",{children:t("Skills")}),e("p",{className:"meta",children:t("What the agent can load when a task calls for it. It applies from its next turn.")}),e("ul",{className:"menu",children:o.skills.map((g,I)=>{let L=`${C}-${I}`;return e("li",{children:n("label",{className:"menu-item menu-toggle",htmlFor:L,children:[n("span",{className:"menu-text",children:[e("strong",{children:g.name}),e("span",{className:"meta",children:g.missing?t("Its file cannot be read."):g.builtin?t("Built in: every agent carries it."):g.description??""})]}),e(Ye,{id:L,checked:g.carried,label:g.name,busy:E===g.name,disabled:g.builtin,onChange:(V)=>F(g.name,V)})]})},g.name)})})]})}var $e=()=>e("svg",{viewBox:"0 0 24 24",width:16,height:16,fill:"none",stroke:"currentColor",strokeWidth:1.8,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",focusable:"false",children:e("path",{d:"M4 9V4h5M20 9V4h-5M4 15v5h5M20 15v5h-5"})});function Ve(i){let{profile:u,draft:o}=i,w=l(null);s(()=>w.current?.focus(),[]);let E=[];if(o.displayName!==u.displayName)E.push({label:t("Name"),before:u.displayName,after:o.displayName});let A=(k)=>k===z?t("Follow the assistant"):k;if(o.model!==(u.model??z))E.push({label:t("Model"),before:A(u.model??z),after:A(o.model)});if(o.thinking!==(u.thinking??z))E.push({label:t("Thinking level"),before:ce(u.thinking??z),after:ce(o.thinking)});return n("section",{ref:w,className:"stack review",tabIndex:-1,"aria-label":t("Review changes"),children:[e("h3",{children:t("Review changes")}),E.length?e("ul",{className:"review-fields",children:E.map((k)=>n("li",{children:[e("strong",{children:k.label}),e("span",{className:"review-before",children:k.before}),e("span",{"aria-hidden":"true",children:"→"}),e("span",{className:"review-after",children:k.after})]},k.label))}):null,e(We,{label:t("Prompt"),before:u.prompt,after:o.prompt}),n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",disabled:i.saving,onClick:i.onBack,children:t("Back to editing")}),e("button",{type:"button",disabled:i.saving,onClick:i.onSave,children:i.saving?t("Saving…"):t("Save")})]})]})}function Ne(){let[i,u]=r(),[o,w]=r(),[E,A]=r(),[k,T]=r(),C=Y(async()=>{try{u((await ye.archive()).entries),w(void 0)}catch(g){w(f(g))}},[]);s(()=>{C()},[C]);let F=async(g)=>{A(g.name);try{if(g.kind==="agent")await ye.restoreAgent(g.name);else await ye.restoreGroup(g.name);await rt(),h(t("Restored {name}.",{name:g.displayName})),await C()}catch(I){h(f(I),"danger")}finally{A(void 0)}};if(o&&!i)return e(y,{message:o});if(!i)return e(x,{});return n("div",{className:"stack",children:[e("p",{className:"meta",children:t("Archived agents and groups no longer answer. Their history is kept until you delete them.")}),i.length===0?e(_,{children:t("Nothing is archived.")}):null,e("ul",{className:"menu",children:i.map((g)=>n("li",{className:"menu-item",children:[e("span",{className:"menu-icon",children:e(a,{name:g.kind==="agent"?"profile":"rooms"})}),n("span",{className:"menu-text",children:[e("strong",{children:g.displayName}),n("span",{className:"meta",children:[g.kind==="agent"?t("Agent"):t("Group")," ·"," ",g.name]})]}),e("button",{type:"button",className:"secondary compact",disabled:E===g.name,onClick:()=>F(g),children:t("Restore")}),e("button",{type:"button",className:"compact danger",disabled:E===g.name,onClick:()=>T(g),children:t("Delete")})]},`${g.kind}:${g.name}`))}),e(re,{open:k!==void 0,title:t("Delete {name}?",{name:k?.displayName??""}),confirmLabel:t("Delete"),tone:"danger",onClose:()=>T(void 0),onConfirm:async()=>{if(!k)return;if(k.kind==="agent")await ye.deleteAgent(k.name);else await ye.deleteGroup(k.name);await rt(),h(t("Deleted {name}.",{name:k.displayName})),await C()},children:e("p",{children:t("{name} and its messages in this app are deleted for good, and the name can be used again. This cannot be undone.",{name:k?.displayName??""})})})]})}var we=/^[a-z0-9-]{1,32}$/,Ce=2,Se=6,ne="\x00";function Ge(){let i=d((u)=>u.order.flatMap((o)=>{let w=u.rooms[o]?.view;return w?.kind==="agent"?[`${w.name}${ne}${w.displayName}`]:[]}).join(`${ne}${ne}`));return X(()=>i===""?[]:i.split(`${ne}${ne}`).map((u)=>{let[o="",w=""]=u.split(ne);return{name:o,displayName:w}}),[i])}function Ae(i){let u=Ge(),[o,w]=r(),[E,A]=r(),[k,T]=r(""),[C,F]=r(""),[g,I]=r(!1),[L,V]=r([]),[Z,J]=r(""),[G,K]=r(!1),[ee,U]=r(i.name===void 0),j=D(),B=D();s(()=>{let S=i.name;if(S===void 0)return;let v=!0;return ye.group(S).then((M)=>{if(!v)return;w(M),T(M.displayName),V(M.members),J(M.host),U(!0)},(M)=>v&&A(f(M))),()=>{v=!1}},[i.name]);let te=(S)=>u.find((v)=>v.name===S)?.displayName??S,R=L.includes(Z)?Z:L[0]??"",ae=o===void 0?!0:k.trim()!==o.displayName||L.join(",")!==o.members.join(",")||R!==o.host,q=k.trim()!==""&&L.length>=Ce&&L.length<=Se&&(o!==void 0||we.test(C));if(E&&!ee)return e(y,{message:E});if(!ee)return e(x,{});let Q=async()=>{K(!0),A(void 0);try{if(o){await ye.updateGroup(o.name,{...k.trim()!==o.displayName?{displayName:k.trim()}:{},...L.join(",")!==o.members.join(",")?{members:L}:{},...R!==o.host?{host:R}:{}}),await rt(),h(t("Saved.")),i.onDone();return}let S=await ye.createGroup({name:C,displayName:k.trim(),members:L,host:R});await rt(),h(t("Made {name}.",{name:S.displayName})),i.onDone(),H("room",S.room)}catch(S){A(f(S))}finally{K(!1)}};return n("form",{className:"stack form",onSubmit:(S)=>{if(S.preventDefault(),q&&ae&&!G)Q()},children:[n("label",{htmlFor:j,children:[t("Name"),e("input",{id:j,value:k,autoComplete:"off",onChange:(S)=>{if(T(S.target.value),!o&&!g)F(S.target.value.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"").slice(0,32))}})]}),o?null:n("label",{htmlFor:B,children:[t("Permanent name"),e("input",{id:B,value:C,autoComplete:"off",autoCapitalize:"none",spellCheck:!1,"aria-invalid":C!==""&&!we.test(C),onChange:(S)=>{I(!0),F(S.target.value)}}),e("span",{className:"meta",children:t("Lowercase letters, digits and dashes, up to 32. It names the room and cannot be changed.")})]}),n("fieldset",{className:"field",children:[e("legend",{children:t("Members")}),e("span",{className:"meta",children:t("Pick 2 to 6 agents. They take turns in the order picked.")}),e("ul",{className:"menu",children:u.map((S)=>{let v=L.includes(S.name);return e("li",{children:n("label",{className:"menu-item menu-toggle",children:[e("input",{type:"checkbox",checked:v,disabled:!v&&L.length>=Se,onChange:()=>V(v?L.filter((M)=>M!==S.name):[...L,S.name])}),e("span",{className:"menu-text",children:e("strong",{children:S.displayName})})]})},S.name)})})]}),L.length>=Ce?e(se,{label:t("Host"),value:R,onChange:J,options:L.map((S)=>({value:S,label:te(S)}))}):null,E?e(y,{message:E}):null,n("div",{className:"actions",children:[o?e("button",{type:"button",className:"danger",onClick:()=>{i.onDone(),Te({kind:"archive",room:o.room,name:o.displayName})},children:t("Archive group")}):null,e("button",{type:"submit",disabled:!q||!ae||G,children:G?t("Saving…"):o?t("Save"):t("Make group")})]})]})}var Be=P(()=>(O("6yf29xwx"),import("./chunk-character-creator-6yf29xwx.js")).then((i)=>({default:i.CharacterCreator}))),Ee=/^[a-z0-9-]{1,32}$/,de="default";function Ke(i){let u=[];for(let o of i){let w=o.indexOf("/"),E=w>0?o.slice(0,w):"",A=u.find((k)=>k.provider===E&&E!=="");if(A)A.models.push(o);else u.push({provider:E,models:[o]})}return u}var Ue=(i)=>i.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"").slice(0,32);function Me({onDone:i}){let[u,o]=r(""),[w,E]=r(""),[A,k]=r(!1),[T,C]=r(""),[F,g]=r(de),[I,L]=r(""),[V,Z]=r(),[J,G]=r(!1),[K,ee]=r([]),[U,j]=r(),[B,te]=r(!1),R=[D(),D(),D(),D(),D()];s(()=>{let v=!0;return m.models().then((M)=>v&&ee(M.models),()=>{return}),()=>{v=!1}},[]);let ae=X(()=>Vt({name:w,displayName:u,prompt:T}),[w,u,T]),q=V?.spec??ae,Q=Ee.test(w)&&u.trim()!==""&&T.trim()!=="";if(J)return e(W,{fallback:e(x,{}),children:e(Be,{name:w||"new",displayName:u,prompt:T,character:q,onPick:(v,M)=>{Z({input:v,spec:M}),G(!1)},onCancel:()=>G(!1)})});let S=async()=>{te(!0),j(void 0);try{let v={name:w,displayName:u.trim(),prompt:T,...F!==de?{model:F}:{},...I.trim()?{task:I.trim()}:{},...V?{character:V.input}:{}},M=await ye.createAgent(v);await rt(),h(t("Made {name}.",{name:M.displayName})),i(),H("room",M.room)}catch(v){j(v instanceof me&&v.field?`${v.field}: ${f(v)}`:f(v))}finally{te(!1)}};return n("form",{className:"stack form",onSubmit:(v)=>{if(v.preventDefault(),Q&&!B)S()},children:[n("label",{htmlFor:R[0],children:[t("Name"),e("input",{id:R[0],value:u,autoComplete:"off",onChange:(v)=>{if(o(v.target.value),!A)E(Ue(v.target.value))}})]}),n("label",{htmlFor:R[1],children:[t("Permanent name"),e("input",{id:R[1],value:w,autoComplete:"off",autoCapitalize:"none",spellCheck:!1,"aria-invalid":w!==""&&!Ee.test(w),onChange:(v)=>{k(!0),E(v.target.value)}}),e("span",{className:"meta",children:t("Lowercase letters, digits and dashes, up to 32. It names the room and cannot be changed.")})]}),n("label",{htmlFor:R[2],children:[t("Prompt"),e("textarea",{id:R[2],rows:6,value:T,onChange:(v)=>C(v.target.value)}),e("span",{className:"meta",children:t("Its job, its sources, its limits and how it reports.")})]}),n("label",{htmlFor:R[4],children:[t("Model"),n("select",{id:R[4],value:F,onChange:(v)=>g(v.target.value),children:[e("option",{value:de,children:t("Follow the assistant")}),Ke(K).map((v)=>v.provider===""?v.models.map((M)=>e("option",{value:M,children:M},M)):e("optgroup",{label:v.provider,children:v.models.map((M)=>e("option",{value:M,children:M},M))},v.provider))]})]}),n("label",{htmlFor:R[3],children:[t("Opening task"),e("textarea",{id:R[3],rows:3,value:I,onChange:(v)=>L(v.target.value)}),e("span",{className:"meta",children:t("Optional. The agent starts on it as soon as it is made.")})]}),n("div",{className:"profile-head",children:[e(oe,{spec:q,name:w||"new",size:72,label:u}),n("div",{children:[e("strong",{children:t("Look")}),e("span",{className:"meta",children:V?t("Your look"):t("Suggested from its role")}),e("button",{type:"button",className:"secondary compact",onClick:()=>G(!0),children:t("Choose a look")})]})]}),U?e(y,{message:U}):null,e("div",{className:"actions",children:e("button",{type:"submit",disabled:!Q||B,children:B?t("Making…"):t("Make agent")})})]})}var _e=(i)=>i.kind==="new-agent"?t("New agent"):i.kind==="archive"?t("Archived"):i.name===void 0?t("New group"):t("Edit group");function Le(){let i=ur(),u=l(i);if(i)u.current=i;let o=u.current,w=i!==void 0;if(s(()=>{if(!w)return;let E=window.location.href,A=()=>{if(window.location.href!==E)kn()};return window.addEventListener("popstate",A),window.addEventListener("hashchange",A),()=>{window.removeEventListener("popstate",A),window.removeEventListener("hashchange",A)}},[w]),!o)return null;return e(N,{open:i!==void 0,title:_e(o),size:"wide",onClose:kn,children:e("div",{className:"stack agent-sheet",children:o.kind==="new-agent"?e(Me,{onDone:kn}):o.kind==="archive"?e(Ne,{}):e(Ae,{...o.name===void 0?{}:{name:o.name},onDone:kn})},o.id)})}function da(){return n(p,{children:[e(oi,{}),e(be,{}),e(Le,{})]})}export{da as SheetHosts};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import{O,W,P,s,D,r,t,p,e,n,a,x,y,h,me,f}from"./chunk-index-31wh5twj.js";import{ke,We}from"./chunk-index-jm23vn03.js";import{N}from"./chunk-index-5d8yjj4m.js";var V=P(()=>(O("yrqehads"),import("./chunk-prompt-history-yrqehads.js")).then((c)=>({default:c.HistorySheet}))),K=`---
|
|
2
|
-
name: my-skill
|
|
3
|
-
description: "Use when "
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# My skill
|
|
7
|
-
|
|
8
|
-
`;function _(c){let{name:d}=c,[l,g]=r(),[m,u]=r(d?"":K),[v,F]=r(),[I,b]=r(!1),[k,S]=r(!1),[R,C]=r(!1),[H,w]=r(!1),T=D();s(()=>{if(!d)return;let i=!0;return ke.skillDocument(d).then((o)=>{if(!i)return;g(o),u(o.text)},(o)=>i&&F(f(o))),()=>{i=!1}},[d]);let L=l?.text??"",z=m!==L,E=d!==void 0&&!l&&!v,A=async()=>{S(!0);try{if(l){let i=await ke.saveSkillDocument(l.name,{text:m,baseHash:l.hash});g(i),u(i.text),b(!1),C(!1),h(t("Saved.")),c.onSaved()}else await ke.createSkillDocument({text:m}),h(t("Skill created.")),c.onSaved(),c.onClose()}catch(i){if(i instanceof me&&i.status===409){let{current:o}=i.body;g(o),C(!0)}else h(f(i),"danger")}finally{S(!1)}};return n(N,{open:!0,title:d??t("New skill"),size:"full",onClose:c.onClose,children:[v?e(y,{message:v}):null,E?e(x,{}):null,l&&!l.writable?e(y,{message:t("This skill cannot be edited here.")}):null,!E&&!v&&(!l||l.writable)?n("div",{className:"stack",children:[I?n("section",{className:"stack review","aria-label":t("Review changes"),children:[e("h3",{children:t("Review changes")}),R?e(y,{message:t("This skill changed while you were editing it. The changes below are against the version there now; save again to replace it, or go back to edit.")}):null,e(We,{label:"SKILL.md",before:L,after:m}),n("div",{className:"actions",children:[e("button",{type:"button",className:"secondary",disabled:k,onClick:()=>b(!1),children:t("Back to editing")}),e("button",{type:"button",disabled:k,onClick:A,children:k?t("Saving…"):l?t("Save"):t("Create skill")})]})]}):n(p,{children:[n("div",{className:"field",children:[n("div",{className:"field-head",children:[e("label",{htmlFor:T,children:"SKILL.md"}),l?e("span",{className:"field-tools",children:n("button",{type:"button",className:"secondary compact","aria-haspopup":"dialog",onClick:()=>w(!0),children:[e(a,{name:"reset",size:16}),t("History")]})}):null]}),e("textarea",{id:T,className:"prompt-full",spellCheck:!1,value:m,onChange:(i)=>u(i.target.value)}),e("p",{className:"meta",children:t("Frontmatter holds the name, which cannot change, and a description that starts with “Use when”. The rest is the skill.")})]}),e("div",{className:"actions",children:e("button",{type:"button",disabled:!z||!m.trim(),onClick:()=>b(!0),children:t("Review changes")})})]}),H&&l?e(W,{fallback:null,children:e(V,{open:H,title:t("History of {name}",{name:l.name}),load:async()=>{let{versions:i}=await ke.skillHistory(l.name);return i.map((o,U)=>({id:o.id,text:o.text,previous:i[U+1]?.text??"",by:o.by,at:o.at}))},onUse:(i)=>{u(i),b(!1),w(!1)},onClose:()=>w(!1)})}):null]}):null]})}export{_ as SkillEditor};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{O,mi,W,P,s,r,t,p,e,n,a,x,y,_,L,m,f,Tn,Jt}from"./chunk-index-31wh5twj.js";import{fe}from"./chunk-index-hk3xyy20.js";import{pe}from"./chunk-index-b9ny4623.js";import"./chunk-index-5d8yjj4m.js";function b({source:i}){return e("div",{className:"prose document",children:e(Tn,{remarkPlugins:[Jt],components:{a:({href:o,children:d})=>o&&/^https?:\/\//.test(o)?e("a",{href:o,target:"_blank",rel:"noreferrer",children:d}):e("span",{children:d}),img:({alt:o})=>e("span",{children:o}),pre:({children:o})=>e("div",{className:"code-block",children:e("pre",{children:o})}),table:({children:o})=>e("div",{className:"table-wrap",children:e("table",{children:o})})},children:i})})}var S=P(()=>(O("h6k6whwg"),import("./chunk-skill-editor-h6k6whwg.js")).then((i)=>({default:i.SkillEditor})));function j(){let[i,o]=r(0),{data:d,error:l}=fe(()=>m.skills(),`skills:${i}`),[k,w]=r(),[u,g]=r();s(()=>{m.session().then(w,()=>{return})},[]);let h=k?.skillEdit===!0;return n("section",{className:"stack",children:[n("div",{className:"card-head",children:[e("h2",{children:t("Skills")}),h?n("button",{type:"button",className:"secondary",onClick:()=>g({name:void 0}),children:[e(a,{name:"plus",size:16}),t("New skill")]}):null]}),e("p",{className:"hint",children:h?t("Registered skills and their carriers. A skill an agent wrote can be edited here; the others are read-only."):t("Registered skills and their carriers; ask an agent on Discord to edit their contents.")}),l?e(y,{message:l}):null,!d&&!l?e(x,{}):null,d?.length===0?e(_,{children:t("No skills.")}):null,d?.map((c)=>e(v,{skill:c,onEdit:h&&c.source.kind==="written"?()=>g({name:c.name}):void 0},`${c.name}:${i}`)),u?e(W,{fallback:null,children:e(S,{name:u.name,onSaved:()=>o((c)=>c+1),onClose:()=>g(void 0)},u.name??"")}):null]})}function N(i){switch(i.kind){case"builtin":return t("Built in with the release; it changes with the release.");case"package":return t("From the package {package}; it changes when the package is upgraded.",{package:i.package});case"linked":return t("Linked from {repo}; change it in its repository.",{repo:`${i.repo}:${i.path}`});default:return}}function v({skill:i,onEdit:o}){let[d,l]=r(!1),[k,w]=r(),[u,g]=r(),h=i.source.kind==="builtin"?t("Built-in"):i.source.kind==="written"?t("Assistant-written"):i.source.kind==="package"?i.source.package:`${i.source.repo}:${i.source.path}`;return n("article",{className:"card",children:[n("div",{className:"card-head",children:[e("strong",{children:i.name}),e(L,{children:h}),i.missing?e(L,{tone:"warn",children:t("File missing")}):n(p,{children:[o?e("button",{type:"button",className:"secondary",onClick:o,children:t("Edit")}):null,e("button",{type:"button",className:"secondary",onClick:()=>{if(l(!0),!k)g(void 0),m.skill(i.name).then(w).catch((c)=>g(f(c)))},children:"SKILL.md"})]})]}),e("p",{children:i.missing??i.description}),i.source.kind!=="written"?n("p",{className:"hint skill-lock",children:[e(a,{name:"lock",size:14}),e("span",{children:N(i.source)})]}):null,n("p",{className:"hint",children:[t("Carriers"),":"," ",i.source.kind==="builtin"?t("All agents"):i.carriers.join(", ")||t("None")]}),i.groups.length?n("p",{className:"hint",children:[t("Groups"),": ",i.groups.join(", ")]}):null,e(pe,{open:d,title:i.name,size:"wide",onClose:()=>l(!1),children:u?e(y,{message:u}):!k?e(x,{}):e(E,{title:i.name,detail:k})})]})}function E({title:i,detail:o}){let d=o.metadata.filter((l)=>!(l.key==="name"&&l.value===i));return n("div",{className:"skill-document",children:[d.length?e("dl",{className:"skill-meta",children:d.map((l)=>n(mi,{children:[e("dt",{children:l.key}),e("dd",{children:l.value})]},l.key))}):null,e(b,{source:o.body})]})}export{j as SkillsPage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{X,l,r,t,ut,p,e,n,a,C,H,je,d,Lt,$e,kt,Dt,Ut}from"./chunk-index-31wh5twj.js";import{fn,pn,mn,wt}from"./chunk-index-wmbmmrd4.js";import{On}from"./chunk-index-bvfqjh77.js";import{Ir,gt}from"./chunk-index-gpkzhq1g.js";fn();function v(){let o=d((c)=>JSON.stringify(Ir(c,(s)=>gt(c,s),(s)=>je(c,s)>0,!0).map((s)=>({id:s.id,...s.title===void 0?{}:{title:s.title},entries:s.keys.map((u)=>({key:u,name:c.rooms[u]?.view?.displayName??u,waiting:je(c,u)>0}))})))),m=mn(),y=l(o);if(!m)y.current=o;let f=y.current;return X(()=>JSON.parse(f),[f])}function b(o){let{key:m,name:y}=o.entry,f=d((i)=>i.rooms[m]),c=d((i)=>je(i,m)),s=f?.view,u=$e(s?.character),g=wt(()=>kt(m,o.onLeave),o.liftable&&!s?.home?pn(m):void 0);if(!s)return null;return e("li",{...o.liftable&&!s.home?{"data-drop-item":"","data-key":m}:{},children:n("a",{className:"switcher-row",...g,href:C("room",m),"aria-current":m===o.current?"page":void 0,style:u,onClick:(i)=>{if(i.button!==0||i.metaKey||i.ctrlKey||i.shiftKey||i.altKey)return;i.preventDefault(),o.onPick(m)},children:[n("span",{className:"switcher-picture",children:[e(Ut,{view:s,size:40}),c?e("span",{className:"switcher-dot","aria-hidden":"true"}):null]}),n("span",{className:"switcher-name",children:[e("strong",{children:y}),f?.typing?n("span",{className:"switcher-working",children:[n("span",{className:"typing","aria-hidden":"true",children:[e("i",{}),e("i",{}),e("i",{})]}),t("Working")]}):null]}),c?e("span",{className:"badge badge-warn",children:ut(c,"{count} card waiting","{count} cards waiting")}):null,s.muted?n("span",{className:"switcher-mode","data-mode":"muted",title:t("Notifications are off"),children:[e(a,{name:"bell-off",size:14}),e("span",{className:"visually-hidden",children:t("Notifications are off")})]}):null,f?.mode.yolo?n("span",{className:"switcher-mode","data-mode":"yolo",title:t("Yolo"),children:[e(a,{name:"bolt",size:14}),e("span",{className:"visually-hidden",children:t("Yolo")})]}):null,f?.mode.longRunning?n("span",{className:"switcher-mode","data-mode":"long",title:t("Long-running"),children:[e(a,{name:"timer",size:14}),e("span",{className:"visually-hidden",children:t("Long-running")})]}):null]})})}function Y(o){let[m,y]=r(""),f=v(),c=f.map((i)=>({...i,entries:i.entries.filter((h)=>On(m,h.name)!==void 0)})).filter((i)=>i.entries.length>0||m===""),s=(i)=>o.close(i===o.current?void 0:()=>H("room",i)),u=f.some((i)=>i.id!=="waiting"&&i.id!=="home"&&i.id!=="rest"&&(i.id!=="pinned"||i.entries.length>0))?t("Ungrouped"):t("Rooms"),g=c.filter((i)=>i.entries.length>0).length>1;return n(p,{children:[n("div",{className:"switcher-search",children:[e(a,{name:"search",size:16}),e("input",{type:"search",value:m,placeholder:t("Find a room"),"aria-label":t("Find a room"),enterKeyHint:"go",autoComplete:"off",onChange:(i)=>y(i.target.value),onKeyDown:(i)=>{let h=c.flatMap((w)=>w.entries)[0];if(i.key==="Enter"&&h&&!Lt(i.nativeEvent))s(h.key)}}),e("button",{type:"button",className:"icon-button switcher-add","aria-label":t("Add"),"aria-haspopup":"menu",onClick:(i)=>Dt(i.currentTarget,o.close),children:e(a,{name:"plus"})})]}),e("div",{className:"switcher-scroll","data-drop-root":"",children:c.map((i)=>{let h=i.id==="waiting",w=i.id==="pinned"?"pinned":i.id==="rest"?"rest":h||i.id==="home"?void 0:"folder";return n("section",{"aria-label":h?t("Waiting for you"):i.id==="home"?t("Home"):i.id==="pinned"?t("Pinned"):i.id==="rest"?u:i.title??t("Rooms"),...i.entries.length===0?{"data-empty":""}:{},...w?{"data-drop-zone":w,"data-zone-id":i.id,...w==="folder"?{"data-folder":i.id}:{}}:{},children:[h?e("h2",{className:"switcher-heading","data-waiting":"",children:t("Waiting for you")}):g||i.entries.length===0?e("h2",{className:"switcher-heading",children:i.id==="home"?t("Home"):i.id==="pinned"?t("Pinned"):i.id==="rest"?u:i.title}):null,e("ul",{className:"switcher-list",children:i.entries.map((N)=>e(b,{entry:N,current:o.current,onPick:s,onLeave:o.close,liftable:!h&&i.id!=="home"},N.key))})]},i.id)})})]})}export{Y as SwitcherList};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{O,W,P,s,r,t,e,n,He,H,d,Vn,_n,Xt,Oe,dr}from"./chunk-index-31wh5twj.js";import{ji,gn}from"./chunk-index-4dy94pbz.js";import"./chunk-index-5d8yjj4m.js";var C=P(()=>(O("wqkjn8bc"),import("./chunk-table-seats-wqkjn8bc.js")).then((a)=>({default:a.TableSeatsSheet}))),w=300;function A(a){let[c,u]=r(!1);return s(()=>{if(!a){u(!1);return}if(He()){u(!0);return}let i=setTimeout(()=>u(!0),w);return()=>clearTimeout(i)},[a]),c}function v(a,c,u,i){dr(a).then((f)=>{if(f)Oe({...f,at:c,via:u,source:i})},()=>{return})}function _({focus:a}){let[c,u]=r(),i=Vn(void 0),f=_n(),[k,g]=r(!1),[S,T]=r(!1),h=d((o)=>o.listed),l=ji(a,i),p=i.find((o)=>o.name===l);s(()=>{if(a&&h&&l===null)H("table",void 0,{replace:!0})},[a,h,l]);let M=A(l!==null),b=(o)=>{if(o===l)return;H("table",o??void 0,{replace:l!==null})},y=()=>{T(!0),g(!0)},R=i.length===0&&f.length>0;return n("div",{className:"table-page","data-focused":l!==null||void 0,children:[n("header",{className:"page-head",children:[e("h1",{children:t("Round table")}),n("div",{className:"table-tools",children:[c?.kind==="webgl"?e("button",{type:"button",className:"secondary",onClick:()=>b(null),children:t("Reset view")}):null,f.length>0?e("button",{type:"button",className:"secondary","aria-haspopup":"dialog",onClick:y,children:t("Who's at the table")}):null]})]}),n("div",{className:"table-frame","data-focused":l!==null||void 0,children:[R?n("div",{className:"table-empty-state",children:[e("strong",{children:t("The table is empty")}),e("p",{className:"meta",children:t("Every agent has left the table. Choose who sits down.")}),e("button",{type:"button",onClick:y,children:t("Who's at the table")})]}):e(Xt,{onHandle:u,focus:l,onFocus:b,onSeat:b,onSeatMenu:(o)=>{let m=i.find((N)=>N.name===o.id);if(m)v(m.key,o.at,o.via,o.source)}}),p?e(gn,{roomKey:p.key,open:M,onBack:()=>b(null),onMenu:(o)=>{let m=o.getBoundingClientRect();v(p.key,{x:m.left,y:m.bottom},"key",o)}},p.key):null]}),S?e(W,{fallback:null,children:e(C,{open:k,onClose:()=>g(!1)})}):null]})}export{_ as TablePage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{D,r,t,e,n,_n,Ut}from"./chunk-index-31wh5twj.js";import{Ye}from"./chunk-index-27qca4mr.js";import{ze}from"./chunk-index-pa2yyqh0.js";import{N}from"./chunk-index-5d8yjj4m.js";function u({view:s}){let o=D(),[a,m]=r(!1),l=s.muted===!0;return e("li",{children:n("label",{className:"menu-item menu-toggle seat-row",htmlFor:o,children:[e(Ut,{view:s,size:40}),n("span",{className:"menu-text",children:[e("strong",{children:s.displayName}),l?e("span",{className:"meta",children:t("Off the table")}):null]}),e(Ye,{id:o,checked:!l,label:s.displayName,busy:a,onChange:async(i)=>{m(!0),await ze(s.key,!i),m(!1)}})]})})}function g(s){let o=_n();return e(N,{open:s.open,title:t("Who's at the table"),onClose:s.onClose,children:n("div",{className:"stack table-seats",children:[e("p",{className:"meta",children:t("An agent who leaves the table is muted: its room stops pushing to you. A card that waits for you is always pushed.")}),e("ul",{className:"menu",children:o.map((a)=>e(u,{view:a},a.key))})]})})}export{g as TableSeatsSheet};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s,l,r,t,c,p,e,n,C,x,y,_,L,m,Q,J,wn}from"./chunk-index-31wh5twj.js";import{fe}from"./chunk-index-hk3xyy20.js";function O({conversationKey:o}){let[d,v]=r(),u=l(!1),{data:a,error:f}=fe(()=>m.transcript(o,d),`${o}|${d??""}`);s(()=>{if(a&&!u.current)u.current=!0,window.scrollTo(0,document.body.scrollHeight)},[a]);let g=n("a",{className:"back",href:C("conversations"),children:["← ",t("Conversations")]});if(!a)return n(p,{children:[g,f?e(y,{message:f}):e(x,{})]});let{conversation:h}=a,N=h.kind==="outside"?t("Outside agent · {id}",{id:h.id.slice(0,8)}):wn(h);return n(p,{children:[g,n("section",{className:"stack",children:[n("div",{className:"card-head",children:[e("h2",{children:N}),h.busy>0?e(L,{tone:"busy",children:t("running")}):null]}),a.archives.length>0?n("label",{className:"inline",children:[t("Showing")," ",n("select",{value:d??"",onChange:(i)=>{u.current=!1,v(i.target.value||void 0)},children:[e("option",{value:"",children:t("Current conversation")}),a.archives.map((i)=>e("option",{value:i,children:t("Archived {name}",{name:i})},i))]})]}):null,f?e(y,{message:f}):null,a.truncated?e("p",{className:"hint",children:t("This conversation is longer than the console reads; the oldest entries are not shown.")}):null,a.entries.length===0?e(_,{children:t("Nothing to show.")}):null,e("ol",{className:"transcript",children:a.entries.map((i,T)=>e(w,{entry:i},T))})]})]})}function w({entry:o}){let{timeZone:d}=Q(),v=o.at?J(o.at,d):"";if(o.role==="tool")return e("li",{className:"entry entry-tool",children:n("details",{children:[n("summary",{children:[o.failed?t("Tool failed"):t("Tool result"),o.tool?` · ${o.tool}`:""]}),e("pre",{children:o.text||t("(empty)")})]})});return n("li",{className:`entry entry-${o.role}`,children:[n("div",{className:"entry-head",children:[e("span",{className:"role",children:t(E[o.role])}),e("span",{className:"meta",children:v})]}),o.text?e("p",{className:"text",children:o.text}):null,o.calls?.map((u,a)=>n("code",{className:"call",children:[u.name," ",u.preview]},a))]})}var E={user:c("User"),assistant:c("Assistant"),tool:c("Tool"),compaction:c("Summary of earlier conversation")};export{O as TranscriptPage};
|