efficient-shell 9.11.0 → 9.12.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.
Files changed (103) hide show
  1. package/README.md +12 -0
  2. package/dist/{Browser-XPDD6RSI.js → Browser-G7AXZ4OT.js} +14 -14
  3. package/dist/Calculator-6NA35GFS.js +29 -0
  4. package/dist/{CurrencyConverter-AW7BB3DD.js → CurrencyConverter-EDEJOKHC.js} +7 -7
  5. package/dist/{Documents-7SVXJFXI.js → Documents-7AVOO2DA.js} +1 -1
  6. package/dist/{Files-H4TP2FLK.js → Files-MT6PMAHO.js} +79 -79
  7. package/dist/{Notepad-XP5TPXS5.js → Notepad-KBRNR5BU.js} +9 -9
  8. package/dist/{PomodoroTimer-5VCWY4QT.js → PomodoroTimer-HCLT2JVD.js} +6 -6
  9. package/dist/{Preview-3ZNKGYVJ.js → Preview-4SOGNXHL.js} +1 -1
  10. package/dist/Sidebar-LIP2DYTO.js +44 -0
  11. package/dist/{Spreadsheet-VZGSCFFQ.js → Spreadsheet-W2AGKEWT.js} +13 -13
  12. package/dist/{Stock-2VWS2IQJ.js → Stock-3IBS63UR.js} +4 -4
  13. package/dist/{Weather-4MEYBP4D.js → Weather-EFIIVKFE.js} +8 -8
  14. package/dist/{WorldClock-Y4YRJ43F.js → WorldClock-ERQQ4VWP.js} +5 -5
  15. package/dist/ai/index.d.ts +42 -1
  16. package/dist/ai/index.js +59 -56
  17. package/dist/ai.css +1 -1
  18. package/dist/apps/index.js +1 -1
  19. package/dist/bin/media-host-check.js +1 -1
  20. package/dist/bin/ui-check.js +1 -1
  21. package/dist/brand.css +1 -1
  22. package/dist/{chunk-4YKRYIA7.js → chunk-27W6BXT6.js} +2 -2
  23. package/dist/{chunk-REGXKU74.js → chunk-2J2OU65F.js} +2 -2
  24. package/dist/chunk-4GPUKEYQ.js +1 -0
  25. package/dist/{chunk-ZA6S5XVM.js → chunk-5ZGL2BRZ.js} +2 -2
  26. package/dist/{chunk-2XBJNB7D.js → chunk-6FI3HVUR.js} +28 -28
  27. package/dist/{chunk-UYDP4DK3.js → chunk-7BYBGPWU.js} +3 -3
  28. package/dist/{chunk-73W7537K.js → chunk-AOSLOKAL.js} +1 -1
  29. package/dist/chunk-AVAYZK3Z.js +3 -0
  30. package/dist/{chunk-5EM5US6A.js → chunk-B74Y4QR2.js} +1 -1
  31. package/dist/{chunk-7IC4JMFA.js → chunk-ERLZDA75.js} +4 -4
  32. package/dist/{chunk-BRHKQMRH.js → chunk-FVDX6ZSZ.js} +6 -6
  33. package/dist/{chunk-FPGRKHUW.js → chunk-HAFB45DT.js} +7 -7
  34. package/dist/{chunk-5Y7JITHW.js → chunk-HMG5TW2R.js} +1 -1
  35. package/dist/{chunk-FNSVXN7B.js → chunk-IK332TWA.js} +1 -1
  36. package/dist/{chunk-ODOEH5QZ.js → chunk-JENEVLJU.js} +1 -1
  37. package/dist/{chunk-XREN3AKD.js → chunk-JGDLTIOX.js} +4 -4
  38. package/dist/{chunk-XS4HFUTW.js → chunk-JWX7QRGE.js} +1 -1
  39. package/dist/{chunk-AGETTWMK.js → chunk-KJHXCVNI.js} +5 -5
  40. package/dist/{chunk-IQWIYZB5.js → chunk-NU2YQSOP.js} +2 -2
  41. package/dist/{chunk-EGAV5LSX.js → chunk-O25B75XX.js} +1 -1
  42. package/dist/{chunk-WIOG2NOJ.js → chunk-O56CY36U.js} +5 -5
  43. package/dist/{chunk-IVY7CCTS.js → chunk-OVDHEMLK.js} +5 -5
  44. package/dist/{chunk-4SZ3NNVF.js → chunk-R6R57BWQ.js} +4 -4
  45. package/dist/{chunk-KOSV4UPK.js → chunk-RISKWWMD.js} +3 -3
  46. package/dist/{chunk-VR4GSAFM.js → chunk-SAHQB2JD.js} +11 -11
  47. package/dist/{chunk-HHOXLECO.js → chunk-SYH7EPLF.js} +23 -23
  48. package/dist/chunk-VVZE27M4.js +7 -0
  49. package/dist/{chunk-IEPSBXMU.js → chunk-Z3CYLDHB.js} +9 -9
  50. package/dist/data/ListLoadError.js +1 -1
  51. package/dist/format/index.js +1 -1
  52. package/dist/forms/BorderInput.js +1 -1
  53. package/dist/forms/BrandAssetEditor.js +1 -1
  54. package/dist/forms/ColorPicker.js +1 -1
  55. package/dist/forms/ComposerAttachments.js +1 -1
  56. package/dist/forms/CornersInput.js +1 -1
  57. package/dist/forms/DisplayChips.js +1 -1
  58. package/dist/forms/IconPicker.js +1 -1
  59. package/dist/forms/InputNumber.js +1 -1
  60. package/dist/forms/LinkPicker.js +1 -1
  61. package/dist/forms/MediaLibrary.js +1 -1
  62. package/dist/forms/MediaUploadField.js +1 -1
  63. package/dist/forms/MediaUsedInList.js +1 -1
  64. package/dist/forms/PositionInput.js +1 -1
  65. package/dist/forms/SidesInput.js +1 -1
  66. package/dist/forms/Slider.js +1 -1
  67. package/dist/forms/Snippet.js +1 -1
  68. package/dist/forms/SplitButton.js +1 -1
  69. package/dist/forms/TextToolbar.js +1 -1
  70. package/dist/forms/WidthsBar.js +1 -1
  71. package/dist/hooks/useTheme.d.ts +1 -1
  72. package/dist/icons/index.js +1 -1
  73. package/dist/index.d.ts +1 -1
  74. package/dist/index.js +111 -111
  75. package/dist/map/index.js +1 -1
  76. package/dist/page-tabs/index.js +5 -5
  77. package/dist/shell/AppUpdateBanner.js +1 -1
  78. package/dist/shell/ContextMenu.js +1 -1
  79. package/dist/shell/DropdownMenu.js +1 -1
  80. package/dist/shell/HelpCenter.js +1 -1
  81. package/dist/shell/ImageLightbox.js +1 -1
  82. package/dist/shell/LanguageSelect.js +1 -1
  83. package/dist/shell/Markdown.js +1 -1
  84. package/dist/shell/PopupMenu.js +1 -1
  85. package/dist/shell/SearchableSelect.js +1 -1
  86. package/dist/shell/SettingReset.js +1 -1
  87. package/dist/shell/SettingRow.js +1 -1
  88. package/dist/shell/TopNav.js +1 -1
  89. package/dist/telemetry/index.js +1 -1
  90. package/dist/templates/ChatTemplate.js +1 -1
  91. package/dist/templates/CheckoutTemplate.js +1 -1
  92. package/dist/templates/DataTablePage.js +1 -1
  93. package/dist/templates/EmailTemplate.js +1 -1
  94. package/dist/templates/ErrorBoundary.d.ts +1 -1
  95. package/dist/templates/FormLayoutPage.js +1 -1
  96. package/dist/ui/index.js +1 -1
  97. package/dist/version.js +1 -1
  98. package/package.json +1 -1
  99. package/dist/Calculator-IZXBE6R7.js +0 -29
  100. package/dist/Sidebar-TLJ7N3AQ.js +0 -44
  101. package/dist/chunk-JG6DATT4.js +0 -1
  102. package/dist/chunk-POCQ7ZL4.js +0 -3
  103. package/dist/chunk-PVR4KU7H.js +0 -7
@@ -54,8 +54,18 @@ interface AssistantTurnUsage {
54
54
  output_tokens: number;
55
55
  generation_ms: number;
56
56
  }
57
+ /** Someone in a chat with several people in it, by name (never an address). */
58
+ interface AssistantPerson {
59
+ id: string;
60
+ name: string;
61
+ }
57
62
  interface AssistantMessageMetadata {
58
63
  source?: MessageSource;
64
+ /** In a chat with several people in it: who wrote a message the person did
65
+ * not, from a restored thread. Absent on the person's own. */
66
+ author?: AssistantPerson;
67
+ /** In such a chat: on an answer to someone else's question, who asked it. */
68
+ askedBy?: AssistantPerson;
59
69
  /** Set on a reply streamed in this window; a restored thread has none. */
60
70
  usage?: AssistantTurnUsage;
61
71
  /** The server's run that wrote this answer, on an answer the person can
@@ -273,6 +283,21 @@ interface AssistantChatLabels {
273
283
  rateFailed: string;
274
284
  /** A file card's action, for assistive technology: "{name}" is filled in. */
275
285
  openFile: string;
286
+ /** In a chat with several people in it: the word that sends a message to
287
+ * the assistant ("@JARVIS"). A message without it goes to the people. */
288
+ assistantMention: string;
289
+ /** Above the box when the draft goes to the people: "{names}" is filled in. */
290
+ toPeople: string;
291
+ /** Above the box when the draft names the assistant. */
292
+ toAssistant: string;
293
+ /** The button that addresses the draft to the assistant. */
294
+ askAssistant: string;
295
+ /** The box's placeholder there: "{names}" and "{mention}" are filled in. */
296
+ peoplePlaceholder: string;
297
+ /** Over an answer to someone else's question: "{name}" is filled in. */
298
+ askedBy: string;
299
+ /** When a message to the people could not be sent. */
300
+ sayFailed: string;
276
301
  }
277
302
  type AssistantChatVariant = 'panel' | 'window' | 'bubble';
278
303
  /** A host's own action on a piece of the person's text — the admin portal's
@@ -489,6 +514,15 @@ declare function attachmentsOf(message: AssistantUIMessage): AssistantAttachment
489
514
  */
490
515
  declare const OWN_DATA_PARTS: ReadonlySet<string>;
491
516
  declare function buildRequestBody(messages: AssistantUIMessage[], conversationId: string | null): AssistantChatRequestBody;
517
+ /** Whether a draft names the assistant (`mention`, say "@JARVIS"), as a word
518
+ * of its own and in any case. In a chat with several people in it, only such
519
+ * a message goes to the assistant; any other goes to the people. */
520
+ declare function mentionsAssistant(text: string, mention: string): boolean;
521
+ /** The draft as a question to the assistant: `mention` first, unless it is
522
+ * already there. */
523
+ declare function addressedToAssistant(text: string, mention: string): string;
524
+ /** People named in a sentence: "Sam Patel", "Sam Patel and Mia Chen", "A, B and C". */
525
+ declare function peopleNames(people: AssistantPerson[]): string;
492
526
  interface HistoryMessage {
493
527
  id: string;
494
528
  role: 'user' | 'assistant';
@@ -504,6 +538,10 @@ interface HistoryMessage {
504
538
  rating?: AssistantAnswerRating | null;
505
539
  /** Files the assistant made with this answer (servers before files omit it). */
506
540
  files?: FileDataPart[];
541
+ /** In an invited chat: who wrote a message the caller did not. */
542
+ author?: AssistantPerson;
543
+ /** In an invited chat: who asked, on an answer to someone else's question. */
544
+ asked_by?: AssistantPerson;
507
545
  }
508
546
  interface HistoryApproval {
509
547
  approval_id: string;
@@ -525,6 +563,9 @@ interface ConversationHistory {
525
563
  pending_approvals: HistoryApproval[];
526
564
  /** Every plan of the conversation, oldest first (servers before plans omit it). */
527
565
  plans?: PlanDataPart[];
566
+ /** Everyone in a chat several people take part in, but the caller. Empty or
567
+ * absent for a chat of one person, where every message is a question. */
568
+ people?: AssistantPerson[];
528
569
  }
529
570
  /** The latest state of every plan in the thread, by plan id. A later part for
530
571
  * the same plan (the server re-sends it on every change) wins. */
@@ -611,4 +652,4 @@ declare function finishedStats(usage: AssistantTurnUsage, labels: StatsLabels):
611
652
  /** The line under a reply being written: `elapsedMs` since the reply began. */
612
653
  declare function liveStats(text: string, elapsedMs: number, labels: StatsLabels): string;
613
654
 
614
- export { ApprovalCard, type ApprovalDecision, type AssistantAnswerAction, type AssistantAnswerRating, type AssistantAnswerVerdict, type AssistantAttachment, type AssistantAttachmentsConfig, AssistantChat, type AssistantChatLabels, type AssistantChatProps, type AssistantChatRequestBody, type AssistantChatVariant, type AssistantConversation, type AssistantDataPart, type AssistantErrorCode, Message as AssistantMessage, type AssistantMessageMetadata, type AssistantRateRequest, type AssistantTextAction, type AssistantTurnUsage, type AssistantUIMessage, type ConversationHistory, DEFAULT_ASSISTANT_CHAT_LABELS, type ErrorDataPart, type FailureView, type FileDataPart, type MessageSource, OWN_DATA_PARTS, PlanApprovalCard, PlanChecklist, type PlanDataPart, type PlanStatus, type PlanStepData, type ToolLabel, type ToolLabelSpec, type ToolLabels, ToolStep, type ToolSummaryDataPart, type ToolSummaryRow, attachmentPart, attachmentsOf, buildRequestBody, estimateTokens, failureView, filesOf, finishedStats, isDroppedConnection, liveStats, messagesFromHistory, pinnedPlan, plansOf, tokensPerSecond, toolSummariesOf };
655
+ export { ApprovalCard, type ApprovalDecision, type AssistantAnswerAction, type AssistantAnswerRating, type AssistantAnswerVerdict, type AssistantAttachment, type AssistantAttachmentsConfig, AssistantChat, type AssistantChatLabels, type AssistantChatProps, type AssistantChatRequestBody, type AssistantChatVariant, type AssistantConversation, type AssistantDataPart, type AssistantErrorCode, Message as AssistantMessage, type AssistantMessageMetadata, type AssistantPerson, type AssistantRateRequest, type AssistantTextAction, type AssistantTurnUsage, type AssistantUIMessage, type ConversationHistory, DEFAULT_ASSISTANT_CHAT_LABELS, type ErrorDataPart, type FailureView, type FileDataPart, type MessageSource, OWN_DATA_PARTS, PlanApprovalCard, PlanChecklist, type PlanDataPart, type PlanStatus, type PlanStepData, type ToolLabel, type ToolLabelSpec, type ToolLabels, ToolStep, type ToolSummaryDataPart, type ToolSummaryRow, addressedToAssistant, attachmentPart, attachmentsOf, buildRequestBody, estimateTokens, failureView, filesOf, finishedStats, isDroppedConnection, liveStats, mentionsAssistant, messagesFromHistory, peopleNames, pinnedPlan, plansOf, tokensPerSecond, toolSummariesOf };
package/dist/ai/index.js CHANGED
@@ -1,57 +1,60 @@
1
1
  "use client";
2
- import{StepChain as e,StepChainItem as t}from"../chunk-RBD7SB6M.js";import{Markdown as n}from"../chunk-7JJUI52C.js";import{Divider as a}from"../chunk-DFOFEBYX.js";import{Textarea_default as r}from"../chunk-PB7G6CJ7.js";import"../chunk-UJUTS6LJ.js";import"../chunk-PJPK2ADX.js";import{useContextMenu as o,ContextMenu as s}from"../chunk-IQWIYZB5.js";import{Banner as l}from"../chunk-7WLFHDWA.js";import"../chunk-XS4HFUTW.js";import{Input_default as i}from"../chunk-MAMWQCJ6.js";import{AttachButton as c,AttachmentDropZone as d}from"../chunk-AGETTWMK.js";import{IconButton_default as p}from"../chunk-RUTUVS4H.js";import"../chunk-AYZY3YNC.js";import{CloseGlyph as u}from"../chunk-D4KZOYXQ.js";import"../chunk-BJONHLET.js";import{useFileIntake as m,humanSize as h,FileIntakeAlert as f}from"../chunk-LYX55RI3.js";import{parseChartSpec as g}from"../chunk-CR7T435F.js";import{SpecChart as b}from"../chunk-UEIJSV45.js";import{formatBytes as v}from"../chunk-X2S2XDZI.js";import"../chunk-5OTS2G3M.js";import"../chunk-36BRD5J3.js";import"../chunk-GVH3NG6G.js";import"../chunk-QMYQ4B5A.js";import"../chunk-CK2YOGUS.js";import"../chunk-2GPHHW7C.js";import"../chunk-VFC6QUEN.js";import"../chunk-NBKQADMY.js";import"../chunk-465RRWBY.js";import{ChartSkeleton as y}from"../chunk-MCMUJDEP.js";import"../chunk-CNYAHYE6.js";import"../chunk-FPGRKHUW.js";import"../chunk-URHGHXDN.js";import"../chunk-5QFPTDQF.js";import"../chunk-LNARMEEZ.js";import{Button_default as x}from"../chunk-NHH2MXFU.js";import"../chunk-UQYNPYF4.js";import"../chunk-HL6JSDN3.js";import{Icon as w}from"../chunk-FSPFV4MI.js";import"../chunk-J75ZT2JQ.js";import{SpinnerRing as k}from"../chunk-R2VKEMZH.js";import"../chunk-MRJKZWWV.js";import"../chunk-OZAAIE4E.js";import"../chunk-BCDG4N6L.js";import"../chunk-PGN5ME7B.js";import"../chunk-62LW225J.js";import"../chunk-GLUJS42B.js";import"../chunk-D65T4H6J.js";import"../chunk-TLRCTNUF.js";import"../chunk-DTJRIWFR.js";import"../chunk-4CPE5NBC.js";import"../chunk-QCFN3ET4.js";import"../chunk-2JWPNR2U.js";import"../chunk-MAFUXCPZ.js";import"../chunk-TZFACUMR.js";import"../chunk-TWVUQUUD.js";import{useShellStrings as N}from"../chunk-PEM7UXQ3.js";import"../chunk-C3QOHMR6.js";import{useRef as A,Fragment as C,useState as j,useEffect as S,useId as T,useCallback as O,useMemo as $}from"react";import{jsx as R,jsxs as _,Fragment as I}from"react/jsx-runtime";import{isToolUIPart as M,getToolName as D,DefaultChatTransport as F,lastAssistantMessageIsCompleteWithApprovalResponses as E}from"ai";import{useChat as z}from"@ai-sdk/react";function L({labels:e,placeholder:t,busy:n,focusWhen:a,onSend:o,onStop:s,onNewChat:l,actions:i,attachments:g}){const[b,v]=j(""),y=A(null),C=function(e){const[t,n]=j([]),a=A(0),r=A(!0);S(()=>()=>{r.current=!1},[]);const o=e?.upload,s=O(e=>{if(o)for(const t of e){const e=a.current++;n(n=>[...n,{key:e,name:t.name,size:t.size}]),o(t).then(t=>{r.current&&n(n=>n.map(n=>n.key===e?{...n,attachment:t}:n))},t=>{const a=t instanceof Error&&t.message?t.message:String(t);r.current&&n(t=>t.map(t=>t.key===e?{...t,error:a}:t))})}},[o]),l=t.some(e=>!e.attachment&&!e.error),i=t.flatMap(e=>e.attachment?[e.attachment]:[]);return{pending:t,add:s,remove:e=>n(t=>t.filter(t=>t.key!==e)),clear:()=>n([]),uploading:l,ready:i}}(g),T=N().files,$=m({accept:g?.accept,maxSizeBytes:g?.maxSizeBytes,maxFiles:g?.maxFiles??5,acceptHint:g?.acceptHint,currentCount:C.pending.length,disabled:!g,onAccept:C.add});S(()=>{a&&y.current?.focus()},[a]);const I=n||C.uploading||!b.trim(),M=()=>{I||(o(b,C.ready),v(""),C.clear(),$.clearRejections())},D=/* @__PURE__ */_("form",{className:("flex items-end gap-2 p-3 "+(g?"":"border-t border-gray-200")).trim(),onSubmit:e=>{e.preventDefault(),M()},children:[l&&/* @__PURE__ */R(p,{type:"button",variant:"ghost","aria-label":e.newChat,title:e.newChat,onClick:l,children:/* @__PURE__ */R(w,{name:"add"})}),g&&/* @__PURE__ */R(c,{variant:"icon",label:e.attach,onClick:$.open,disabled:n}),
3
- /* @__PURE__ */R("div",{className:"min-w-0 flex-1",children:/* @__PURE__ */R(r,{ref:y,"aria-label":e.inputLabel,placeholder:t,rows:1,autoGrow:!0,value:b,onChange:e=>v(e.target.value),onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||e.nativeEvent.isComposing||(e.preventDefault(),M())},className:"max-h-32"})}),i?.map(e=>e.icon?/* @__PURE__ */R(p,{type:"button",variant:"ghost","aria-label":e.label,title:e.label,disabled:!b.trim(),onClick:()=>e.onSelect(b.trim()),children:/* @__PURE__ */R(w,{name:e.icon})},e.key):/* @__PURE__ */R(x,{type:"button",variant:"ghost",disabled:!b.trim(),onClick:()=>e.onSelect(b.trim()),children:e.label},e.key)),/* @__PURE__ */R(x,n?{type:"button",variant:"secondary",onClick:s,children:e.stop}:{type:"submit",disabled:I,children:e.send})]});return g?/* @__PURE__ */_(d,{intake:$,className:"border-t border-gray-200",children:[C.pending.length>0&&/* @__PURE__ */R("ul",{className:"flex flex-wrap gap-2 px-3 pt-3",children:C.pending.map(t=>/* @__PURE__ */_("li",{className:"flex max-w-full items-center gap-2 rounded-md border py-1 pl-2 pr-1 text-xs "+(t.error?"border-red-200 bg-red-50 text-red-700":"border-gray-200 bg-gray-50 text-gray-700"),children:[t.attachment||t.error?/* @__PURE__ */R(w,{name:"page",size:14,"aria-hidden":"true"}):/* @__PURE__ */R("span",{role:"status","aria-label":e.attaching,className:"inline-flex",children:/* @__PURE__ */R(k,{className:"h-3 w-3"})}),
4
- /* @__PURE__ */R("span",{className:"min-w-0 truncate",title:t.error??t.name,children:t.name}),
5
- /* @__PURE__ */R("span",{className:"shrink-0 tabular-nums text-gray-400",children:h(t.size,T)}),
6
- /* @__PURE__ */R("button",{type:"button",onClick:()=>C.remove(t.key),"aria-label":e.removeAttachment.replace("{name}",t.name),className:"shrink-0 rounded p-0.5 text-gray-400 hover:bg-gray-200 hover:text-gray-600",children:/* @__PURE__ */R(u,{className:"h-3.5 w-3.5"})})]},t.key))}),C.pending.some(e=>e.error)&&/* @__PURE__ */R("ul",{role:"alert",className:"flex flex-col gap-0.5 px-3 pt-1",children:C.pending.flatMap(e=>e.error?[/* @__PURE__ */R("li",{className:"text-xs text-red-600",children:`${e.name}: ${e.error}`},e.key)]:[])}),
7
- /* @__PURE__ */R(f,{rejections:$.rejections,className:"px-3 pt-1"}),D]}):D}function U(e){if(!M(e))return null;const t=e;return{toolName:D(e),toolCallId:t.toolCallId,state:t.state,input:t.input,output:t.output,errorText:t.errorText,approvalId:t.approval?.id,approved:t.approval?.approved}}function B(e){const t=/* @__PURE__ */new Map;for(const n of e.parts){if("data-tool-summary"!==n.type)continue;const e=n.data;e&&"string"==typeof e.tool_call_id&&Array.isArray(e.rows)&&e.rows.length>0&&t.set(e.tool_call_id,e)}return t}function H(e){const t=/* @__PURE__ */new Map;for(const n of e.parts){if("data-file"!==n.type)continue;const e=n.data;e&&"string"==typeof e.id&&"string"==typeof e.filename&&t.set(e.id,e)}return[...t.values()]}function P(e){return e.parts.map(e=>"text"===e.type?e.text:"").join("")}var W="efficient-attachment:";function J(e){return{type:"file",mediaType:e.content_type,filename:e.filename,url:`${W}${e.id}`,providerMetadata:{efficient:{size:e.size}}}}function Y(e){const t=[];for(const n of e.parts){if("file"!==n.type||!n.url.startsWith(W))continue;const e=n.providerMetadata?.efficient?.size;t.push({id:n.url.slice(21),filename:n.filename??"",content_type:n.mediaType,size:"number"==typeof e?e:0})}return t}var q=/* @__PURE__ */new Set(["data-conversation","data-plan","data-followups","data-tool-summary","data-error","data-file","data-approval","data-busy"]);function Q(e,t){const n=e[e.length-1];if(!n)throw new Error("assistant chat: no message to send");if("user"===n.role){const e=P(n).trim();if(!e)throw new Error("assistant chat: empty message");const a=Y(n).map(e=>e.id);return{conversation_id:t,text:e,approvals:[],...a.length>0?{attachments:a}:{}}}const a=function(e){const t=[];for(const n of e.parts){if(!M(n))continue;const e=n;if("approval-responded"!==e.state||!e.approval||"boolean"!=typeof e.approval.approved)continue;const a={approval_id:e.approval.id,approved:e.approval.approved};e.approval.reason&&(a.reason=e.approval.reason),t.push(a)}return t}(n);if(0===a.length)throw new Error("assistant chat: no approval decision to send");return{conversation_id:t,text:null,approvals:a}}var G=/* @__PURE__ */new Set(["proposed","approved","running"]);function Z(e){return G.has(e.status)}function K(e){const t=[];for(const n of e.parts)"data-plan"===n.type&&t.push(n.data);return t}function X(e){const t=/* @__PURE__ */new Map;for(const n of e)for(const e of K(n))t.delete(e.id),t.set(e.id,e);return t}function V(e){const t=[...X(e).values()],n=t[t.length-1];if(!n)return null;if(Z(n))return n;const a=e[e.length-1];return a&&"assistant"===a.role&&K(a).some(e=>e.id===n.id)?n:null}function ee(e){const t={};return e.source&&e.source!==e.role&&(t.source=e.source),"assistant"===e.role&&e.run_id&&(t.run_id=e.run_id,t.rating=e.rating??null),Object.keys(t).length>0?{metadata:t}:{}}function te(e){const t=e.messages.filter(e=>e.text).map(e=>({id:e.id,role:e.role,parts:[...(e.attachments??[]).map(J),{type:"text",text:e.text},...(e.files??[]).map(e=>({type:"data-file",id:`file-${e.id}`,data:e}))],...ee(e)})),n=(e.plans??[]).filter(Z);return(e.pending_approvals.length>0||n.length>0)&&t.push({id:`pending-approvals-${e.id}`,role:"assistant",parts:[...n.map(e=>({type:"data-plan",id:e.id,data:e})),...e.pending_approvals.map(e=>({type:`tool-${e.tool_name}`,toolCallId:e.tool_call_id??e.approval_id,state:"approval-requested",input:e.input,approval:{id:e.approval_id}}))]}),t}function ne(e,t){const n=e?.message?.trim();if(!n)return t;if(n.startsWith("{")){try{const e=JSON.parse(n);for(const t of["detail","errorText","message","title","error"]){const n=e[t];if("string"==typeof n&&n.trim())return n.trim()}}catch{return t}return t}return n.startsWith("<")||n.length>400?t:n}var ae=/^(load failed|failed to fetch|network ?error( when attempting to fetch resource)?|(the )?network connection was lost|error in input stream|terminated)\.?$/i;function re(e){return!(!e||"AbortError"===e.name)&&ae.test(e.message?.trim()??"")}var oe=/* @__PURE__ */new Set(["budget_reached","not_permitted"]);function se(e,t,n){return re(e)?{text:n.connectionDropped,retryable:!0}:{text:ne(e,n.genericError),retryable:!(t&&oe.has(t))}}function le(e){const t=e[e.length-1];if(!t)return!1;if("user"===t.role)return""!==P(t).trim();const n=e[e.length-2];return!(!n||"user"!==n.role||!P(n).trim())&&!t.parts.some(e=>void 0!==U(e)?.approvalId)}function ie(e){const t=e.replace(/^tool-/,"").replace(/([a-z0-9])([A-Z])/g,"$1 $2").replace(/[_\-.]+/g," ").trim().toLowerCase();return t?t.charAt(0).toUpperCase()+t.slice(1):e}var ce={propose_plan:{label:"Plan the changes",running:"Planning the changes",done:"Planned the changes"}};function de(e,t){const n=t?.[e]??ce[e];return"string"==typeof n?{label:n}:n??{label:ie(e)}}function pe(e,t){return de(e,t).label}function ue(e){return e&&"object"==typeof e&&!Array.isArray(e)?e:{}}function me(e,t,n){const a=de(e,n).describe;if(!a)return"";try{return a(ue(t))?.trim()??""}catch{return""}}function he(e,t){return null==e?"":"boolean"==typeof e?e?"Yes":"No":"object"!=typeof e?String(e):Array.isArray(e)?e.map(e=>he(e,t+1)).filter(Boolean).join(", "):t>=3?"…":Object.entries(e).map(([e,n])=>{const a=he(n,t+1);return a?`${ie(e)}: ${a}`:""}).filter(Boolean).join("; ")}function fe(e){const t=ue(e),n=[];for(const[e,a]of Object.entries(t)){if(e.startsWith("_"))continue;const t=he(a,0);t&&n.push({label:ie(e),value:t})}return 0===n.length&&null!=e&&"object"!=typeof e&&n.push({label:"Value",value:he(e,0)}),n}var ge={proposed:"planProposed",approved:"planApproved",running:"planRunning",completed:"planCompleted",failed:"planFailed",denied:"planDenied",expired:"planExpired"},be={pending:"pending",running:"active",done:"complete",failed:"failed",skipped:"skipped"};function ve(e,t){const n=me(e.tool_name,e.input,t);return`${pe(e.tool_name,t)}${n?` ${n}`:""}`}function ye(e,t){return e.replace(/\{(\w+)\}/g,(e,n)=>n in t?String(t[n]):e)}function xe(e,t){const n=e.steps.filter(e=>"done"===e.status).length;return`${ye(t.planSummary,{done:n,total:e.steps.length})} · ${t[ge[e.status]]}`}function we({plan:n,labels:a}){/* @__PURE__ */
8
- return R("section",{"aria-label":a.plan,className:"border-t border-gray-200 bg-white px-3 py-2",children:/* @__PURE__ */R(e,{summary:xe(n,a),busy:Z(n),label:a.plan,children:n.steps.map(e=>/* @__PURE__ */R(t,{label:e.title,status:be[e.status],description:"done"!==e.status&&e.result_summary?e.result_summary:void 0},e.id))})})}function ke({approvalId:e,plan:t,input:n,labels:a,toolLabels:r,onApprove:o}){const s=function(e,t){if(e)return e.steps.map(e=>({key:e.id,title:e.title,tool_name:e.tool_name,input:e.input}));const n=t?.steps;return Array.isArray(n)?n.map((e,t)=>{const n=e??{};return{key:String(t),title:"string"==typeof n.title?n.title:"",tool_name:"string"==typeof n.tool?n.tool:"",input:n.args}}):[]}(t,n),l=ye(a.planApprovalHeading,{count:s.length});/* @__PURE__ */
9
- return _("div",{role:"group","aria-label":l,className:"rounded-lg border border-amber-300 bg-amber-50 p-3 text-sm",children:[
10
- /* @__PURE__ */R("div",{className:"font-medium text-gray-900",children:l}),
11
- /* @__PURE__ */R("ol",{className:"mt-2 list-decimal space-y-2 pl-5",children:s.map(e=>{const t=fe(e.input);/* @__PURE__ */
12
- return _("li",{children:[
13
- /* @__PURE__ */R("div",{className:"font-medium text-gray-900",children:ve(e,r)}),e.title&&/* @__PURE__ */R("div",{className:"text-xs text-gray-600",children:e.title}),t.length>0&&/* @__PURE__ */R("dl",{className:"mt-1 grid grid-cols-[max-content_1fr] gap-x-3 gap-y-1 text-xs",children:t.map(e=>/* @__PURE__ */_("div",{className:"contents",children:[
14
- /* @__PURE__ */R("dt",{className:"text-gray-500",children:e.label}),
15
- /* @__PURE__ */R("dd",{className:"min-w-0 break-words text-gray-800",children:e.value})]},e.label))})]},e.key)})}),
16
- /* @__PURE__ */_("div",{className:"mt-3 flex gap-2",children:[
17
- /* @__PURE__ */R(x,{size:"sm",onClick:()=>o(e,!0),children:a.approvePlan}),
18
- /* @__PURE__ */R(x,{size:"sm",variant:"secondary",onClick:()=>o(e,!1),children:a.deny})]})]})}function Ne({questions:e,label:t,onAsk:n}){return 0===e.length?null:/* @__PURE__ */R("div",{role:"group","aria-label":t,className:"flex flex-wrap gap-2 pl-1",children:e.map(e=>/* @__PURE__ */R(x,{size:"sm",variant:"secondary",onClick:()=>n(e),children:e},e))})}function Ae({initial:e,labels:t,onRate:n}){const[a,r]=j(e??null),[o,s]=j(!1),[l,c]=j(""),[d,u]=j(!1),[m,h]=j(!1),[f,g]=j(!1),b=async e=>{const t=a;r(e),h(!1),g(!0);try{return await n(e),!0}catch{return r(t),h(!0),!1}finally{g(!1)}},v=e=>{const n="up"===e?t.rateUp:t.rateDown;/* @__PURE__ */
19
- return R(p,{size:"sm","aria-label":n,title:n,"aria-pressed":a?.verdict===e,disabled:f,onClick:()=>{(async e=>{if(u(!1),a?.verdict===e)return s(!1),void await b(null);const t=await b({verdict:e,note:""});s(t&&"down"===e),c("")})(e)},children:/* @__PURE__ */R(w,{name:"hand-thumb-up",className:"down"===e?"h-3.5 w-3.5 rotate-180":"h-3.5 w-3.5"})})};/* @__PURE__ */
20
- return _("div",{role:"group","aria-label":t.rateAnswer,className:"flex min-w-0 flex-1 flex-col gap-1",children:[
21
- /* @__PURE__ */_("div",{className:"flex items-center gap-1",children:[v("up"),v("down"),d&&/* @__PURE__ */R("span",{role:"status",className:"px-1 text-xs text-gray-500",children:t.rateThanks}),m&&/* @__PURE__ */R("span",{role:"alert",className:"px-1 text-xs text-red-600",children:t.rateFailed})]}),o&&/* @__PURE__ */_("form",{className:"flex items-center gap-2",onSubmit:e=>{(async e=>{e.preventDefault();const t=l.trim();t&&!await b({verdict:"down",note:t})||(s(!1),u(Boolean(t)))})(e)},children:[
22
- /* @__PURE__ */R("div",{className:"min-w-0 flex-1",children:/* @__PURE__ */R(i,{size:"sm","aria-label":t.rateNote,placeholder:t.rateNote,maxLength:500,value:l,onChange:e=>c(e.target.value),autoFocus:!0})}),
23
- /* @__PURE__ */R(x,{type:"submit",size:"sm",variant:"secondary",disabled:f||!l.trim(),children:t.rateNoteSend}),
24
- /* @__PURE__ */R(x,{type:"button",size:"sm",variant:"ghost",onClick:()=>s(!1),children:t.rateNoteSkip})]})]})}function Ce({rows:e,label:t}){/* @__PURE__ */
25
- return R("dl",{"aria-label":t,className:"grid grid-cols-[max-content_1fr] gap-x-3 gap-y-1 text-xs",children:e.map((e,t)=>/* @__PURE__ */_("div",{className:"contents",children:[
26
- /* @__PURE__ */R("dt",{className:"text-gray-500",children:e.label}),
27
- /* @__PURE__ */R("dd",{className:"min-w-0 break-words "+(e.warn?"font-medium text-amber-700":"text-gray-800"),children:e.value})]},`${e.label}-${t}`))})}function je({tool:e,toolLabels:t,labels:n,onApprove:a}){const r=me(e.toolName,e.input,t),o=fe(e.input),s=e.approvalId,l=`${n.approvalNeeded}: ${pe(e.toolName,t)}${r?` ${r}`:""}`;/* @__PURE__ */
28
- return _("div",{role:"group","aria-label":l,className:"rounded-lg border border-amber-300 bg-amber-50 p-3 text-sm",children:[
29
- /* @__PURE__ */R("div",{className:"font-medium text-gray-900",children:l}),o.length>0&&/* @__PURE__ */R("div",{className:"mt-2",children:/* @__PURE__ */R(Ce,{rows:o})}),
30
- /* @__PURE__ */_("div",{className:"mt-3 flex gap-2",children:[
31
- /* @__PURE__ */R(x,{size:"sm",onClick:()=>a(s,!0),children:n.approve}),
32
- /* @__PURE__ */R(x,{size:"sm",variant:"secondary",onClick:()=>a(s,!1),children:n.deny})]})]})}var Se={running:"active",done:"complete",failed:"failed",declined:"stopped",waiting:"waiting"};function Te(e,t,n){return function(e,t,n,a,r,o){const s=de(n,r),l=me(n,a,r),i=(e,t)=>({kind:e,base:t,subject:l,text:l?`${t} ${l}`:t});switch(e){case"output-available":return i("done",s.done??s.label);case"output-error":return i("failed",`${s.label} ${o.toolFailed}`);case"output-denied":return i("declined",`${s.label} ${o.toolDeclined}`);case"approval-requested":return i("waiting",`${o.approvalNeeded}: ${s.label}`);case"approval-responded":return!1===t?i("declined",`${s.label} — ${o.declined}`):i("running",`${o.approved}: ${s.running??s.label}`);default:return i("running",s.running??s.label)}}(e.state,e.approved,e.toolName,e.input,t,n)}function Oe({tool:e,summary:n,toolLabels:a,labels:r,showOutput:o}){const s=Te(e,a,r),l=fe(e.input),i=o&&"output-available"===e.state?fe(e.output):[],c=o&&"output-error"===e.state&&e.errorText?e.errorText:"",d="output-available"===e.state&&n?n.rows:[];let p=null;return(l.length>0||i.length>0||c)&&(p=/* @__PURE__ */_("details",{className:d.length>0?"mt-1":void 0,children:[
33
- /* @__PURE__ */R("summary",{className:"cursor-pointer select-none",children:r.details}),
34
- /* @__PURE__ */_("div",{className:"mt-1 space-y-2",children:[l.length>0&&/* @__PURE__ */R(Ce,{rows:l}),i.length>0&&/* @__PURE__ */R(Ce,{rows:i}),c&&/* @__PURE__ */R("div",{className:"text-red-600",children:c})]})]})),/* @__PURE__ */_(t,{label:s.base,description:s.subject||void 0,status:Se[s.kind],children:[d.length>0&&/* @__PURE__ */R(Ce,{rows:d,label:r.stepSources}),p]})}function $e(e,t){return e>0&&t>=100?e/(t/1e3):null}function Re(e){return Math.ceil(e.length/4)}var _e=(e,t)=>e.replace(/\{(\w+)\}/g,(e,n)=>t[n]??e),Ie=e=>Math.round(e).toLocaleString();function Me(e,t){const n=$e(e.output_tokens,e.generation_ms);return null===n?_e(t.replyTokens,{tokens:Ie(e.output_tokens)}):_e(t.replyStats,{tokens:Ie(e.output_tokens),seconds:(e.generation_ms/1e3).toFixed(1),rate:Ie(n)})}function De(e,t,n){const a=t>=1e3?$e(Re(e),t):null;return null===a?n.streaming:_e(n.streamingRate,{rate:Ie(a)})}function Fe(e){if("chart"!==e.lang)return null;if(!e.closed)/* @__PURE__ */return R(y,{height:200});const t=g(e.code);return t?/* @__PURE__ */R(b,{spec:t}):null}function Ee(e,t){return"approval-responded"===e.state&&t.some(t=>{return t.toolName===e.toolName&&"approval-requested"!==t.state&&(t.toolCallId===e.toolCallId||(n=t.input,a=e.input,JSON.stringify(n)===JSON.stringify(a)));var n,a})}function ze(e,t,n,a){const r=e.flatMap(e=>"tool"===e.kind?[Te(e.tool,n,a)]:[]);if(t){const e=r.find(e=>"running"===e.kind);return e?e.base:a.working}const o=[...new Set(r.map(e=>e.base))];return o.length>0?o.join(" · "):a.reasoning}function Le({message:e,live:t,labels:n}){const a=P(e),r=a.length>0,o=A(null),[s,l]=j(0);S(()=>{if(!t)return;null===o.current&&(o.current=performance.now());const e=setInterval(()=>l(performance.now()-(o.current??performance.now())),500);return()=>clearInterval(e)},[t]);const i=e.metadata?.usage;let c=null;return t?c=r?De(a,s,n):null:i&&(c=Me(i,n)),c?/* @__PURE__ */R("div",{className:"px-1 text-xs leading-6 tabular-nums text-gray-500",children:c}):null}function Ue({files:e,labels:t,onOpen:n}){const a="flex max-w-full items-center gap-2 rounded-md border border-gray-200 bg-white px-2 py-1 text-xs text-gray-700";/* @__PURE__ */
35
- return R("ul",{className:"flex max-w-[85%] flex-wrap justify-end gap-2",children:e.map(e=>{const r=/* @__PURE__ */_(I,{children:[
36
- /* @__PURE__ */R(w,{name:"page",size:14,"aria-hidden":"true",className:"shrink-0"}),
37
- /* @__PURE__ */R("span",{className:"min-w-0 truncate",children:e.filename})]});/* @__PURE__ */
38
- return R("li",{className:"max-w-full",children:n?/* @__PURE__ */R("button",{type:"button",className:`${a} hover:bg-gray-50`,title:t.openAttachment.replace("{name}",e.filename),onClick:()=>n(e),children:r}):/* @__PURE__ */R("span",{className:a,children:r})},e.id)})})}function Be(e){return["xlsx"===e.kind?"Excel":String(e.kind||"").toUpperCase(),v(e.size)].filter(Boolean).join(" · ")}function He({file:e,labels:t,onOpen:n}){const a=/* @__PURE__ */_(I,{children:["pdf"===e.kind?/* @__PURE__ */R(w,{name:"document",size:20,className:"shrink-0"}):/* @__PURE__ */R(w,{name:"table",size:20,className:"shrink-0"}),
39
- /* @__PURE__ */_("span",{className:"min-w-0 flex-1",children:[
40
- /* @__PURE__ */R("span",{className:"block truncate text-sm font-medium text-gray-800",children:e.filename}),
41
- /* @__PURE__ */R("span",{className:"block text-xs text-gray-500",children:Be(e)})]})]}),r="flex w-full max-w-sm items-center gap-2 rounded-lg border border-gray-200 bg-gray-50 px-3 py-2 text-left";return n?/* @__PURE__ */R("button",{type:"button",className:`${r} hover:border-blue-300 hover:bg-blue-50 focus:outline-none focus-visible:ring-2 focus-visible:ring-blue-500`,"data-assistant-file":e.id,"aria-label":t.openFile.replace("{name}",e.filename),onClick:()=>n(e),children:a}):/* @__PURE__ */R("div",{className:r,"data-assistant-file":e.id,children:a})}function Pe({message:e,labels:t,showCopy:n,actions:r,answer:o}){const[s,l]=j(!1);S(()=>{if(!s)return;const e=setTimeout(()=>l(!1),1500);return()=>clearTimeout(e)},[s]);const i=P(e);if(!i.trim()||!n&&!r?.length)return null;const c=async()=>{const e=Array.from(o.current?.querySelectorAll("[data-answer-text]")??[]);l(await async function(e,t){const n="undefined"!=typeof navigator?navigator.clipboard:void 0;if(!n)return!1;try{return t&&"undefined"!=typeof ClipboardItem&&n.write?(await n.write([new ClipboardItem({"text/html":new Blob([t],{type:"text/html"}),"text/plain":new Blob([e],{type:"text/plain"})})]),!0):(await n.writeText(e),!0)}catch{return!1}}(i,function(e){return e.map(e=>{const t=e.cloneNode(!0);return t.querySelectorAll("button, [data-chat-chrome]").forEach(e=>e.remove()),t.querySelectorAll("[class]").forEach(e=>e.removeAttribute("class")),t.removeAttribute("class"),t.querySelectorAll("table").forEach(e=>e.setAttribute("style","border-collapse:collapse")),t.querySelectorAll("th, td").forEach(e=>e.setAttribute("style","border:1px solid #d0d5dd;padding:4px 8px;text-align:left;vertical-align:top")),t.innerHTML.trim()}).filter(Boolean).join("\n")}(e)))},d=[];return n&&d.push(
42
- /* @__PURE__ */R(x,{size:"sm",variant:"ghost",leftIcon:/* @__PURE__ */R(w,{name:s?"check":"copy",look:"mini",className:"h-3.5 w-3.5","aria-hidden":"true"}),onClick:()=>{c()},children:s?t.copied:t.copyAnswer},"copy")),r?.forEach(t=>d.push(
43
- /* @__PURE__ */R(x,{size:"sm",variant:"ghost",leftIcon:t.icon?/* @__PURE__ */R(w,{name:t.icon,look:"mini",className:"h-3.5 w-3.5","aria-hidden":"true"}):void 0,onClick:()=>t.onSelect({id:e.id,text:i}),children:t.label},t.key))),/* @__PURE__ */R("div",{className:"ml-auto flex items-center gap-0.5","data-chat-chrome":"",children:d.map((e,t)=>/* @__PURE__ */_(C,{children:[t>0&&/* @__PURE__ */R("span",{className:"flex h-3",children:/* @__PURE__ */R(a,{orientation:"vertical"})}),e]},t))})}function We({text:e,actions:t,files:n,labels:a,onOpenAttachment:r}){const l=o(),i=/* @__PURE__ */R("div",{className:"max-w-[85%] whitespace-pre-wrap break-words rounded-2xl bg-blue-600 px-3 py-2 text-sm text-white",children:e}),c=n.length>0?/* @__PURE__ */R(Ue,{files:n,labels:a,onOpen:r}):null;return t?.length?/* @__PURE__ */_("div",{className:c?"flex flex-col items-end gap-2":"flex justify-end",onContextMenu:e=>l.open(e,void 0),children:[c,i,l.state&&/* @__PURE__ */R(s,{...l.props,"aria-label":e,items:t.map(t=>({key:t.key,label:t.label,onSelect:()=>t.onSelect(e)}))})]}):c?/* @__PURE__ */_("div",{className:"flex flex-col items-end gap-2",children:[c,i]}):/* @__PURE__ */R("div",{className:"flex justify-end",children:i})}function Je({message:a,toolLabels:r,labels:o,showReasoning:s,showToolOutput:l,showUsage:i,live:c,onApprove:d,plans:p,userActions:u,tableActions:m,onLinkClick:h,onOpenAttachment:f,onOpenFile:g,renderDataPart:b,showCopy:v,answerActions:y,onRate:x}){const w=a.metadata?.source,k=A(null);if("system"===w){const e=P(a);return e?/* @__PURE__ */R("div",{className:"text-center text-xs text-gray-500",children:e}):null}if("user"===a.role){const e=P(a);return e?/* @__PURE__ */R(We,{text:e,actions:u,files:Y(a),labels:o,onOpenAttachment:f}):null}const N=a.parts.map(U),j=B(a),S=[],T=/* @__PURE__ */new Set,O=[];let $=-1;const I=e=>{$<0&&($=S.push(null)-1),O.push(e)};if(a.parts.forEach((e,t)=>{if("text"===e.type)return void(e.text.trim()&&S.push(
44
- /* @__PURE__ */R("div",{"data-answer-text":"",children:/* @__PURE__ */R(n,{renderFence:Fe,tableActions:c?void 0:m,onLinkClick:h,children:e.text})},t)));if("data-file"===e.type){const t=e.data;return void(t&&"string"==typeof t.id&&!T.has(t.id)&&(T.add(t.id),S.push(/* @__PURE__ */R(He,{file:t,labels:o,onOpen:g},`file-${t.id}`))))}if(b&&e.type.startsWith("data-")&&!q.has(e.type)){const n=b(e,a);return void(n&&S.push(/* @__PURE__ */R(C,{children:n},`data-${t}`)))}if("reasoning"===e.type)return void(s&&e.text.trim()&&I({kind:"reasoning",key:`r${t}`,text:e.text}));const l=N[t];l&&(Ee(l,N.slice(t+1).filter(e=>null!==e))||("approval-requested"===l.state&&l.approvalId&&"propose_plan"===l.toolName?S.push(
45
- /* @__PURE__ */R(ke,{approvalId:l.approvalId,plan:p?.get(l.approvalId),input:l.input,labels:o,toolLabels:r,onApprove:d},l.toolCallId)):"approval-requested"===l.state&&l.approvalId?S.push(
46
- /* @__PURE__ */R(je,{tool:l,toolLabels:r,labels:o,onApprove:d},l.toolCallId)):I({kind:"tool",key:l.toolCallId,tool:l})))}),$>=0&&(S[$]=/* @__PURE__ */R(e,{summary:ze(O,c,r,o),busy:c,label:o.steps,children:O.map(e=>"tool"===e.kind?/* @__PURE__ */R(Oe,{tool:e.tool,summary:j.get(e.tool.toolCallId),toolLabels:r,labels:o,showOutput:l},e.key):/* @__PURE__ */R(t,{status:"complete",label:/* @__PURE__ */_("details",{children:[
47
- /* @__PURE__ */R("summary",{className:"cursor-pointer select-none",children:o.reasoning}),
48
- /* @__PURE__ */R("div",{className:"mt-1 whitespace-pre-wrap text-gray-500",children:e.text})]})},e.key))},"chain")),0===S.length)return null;const M=/* @__PURE__ */_("div",{ref:k,className:"max-w-[92%] min-w-0 space-y-2 rounded-2xl bg-white px-3 py-2 text-gray-800 shadow-sm",children:["staff"===w&&/* @__PURE__ */R("div",{className:"text-xs font-medium text-blue-600",children:o.teamName}),S]}),D=c?null:/* @__PURE__ */R(Pe,{message:a,labels:o,showCopy:!0===v,actions:y,answer:k}),F=i&&!w,E=a.metadata?.run_id,z=Boolean(x&&E&&!c&&!w);return F||z||D?/* @__PURE__ */_("div",{className:"flex flex-col items-start gap-1",children:[M,
49
- /* @__PURE__ */_("div",{className:"flex w-full max-w-[92%] flex-wrap items-start gap-x-2 gap-y-1",children:[
50
- /* @__PURE__ */_("div",{className:"flex min-w-0 flex-1 items-start gap-1",children:[F&&/* @__PURE__ */R(Le,{message:a,live:c,labels:o}),z&&x&&E&&/* @__PURE__ */R(Ae,{initial:a.metadata?.rating,labels:o,onRate:e=>x(E,e)})]}),D]})]}):/* @__PURE__ */R("div",{className:"flex justify-start",children:M})}function Ye(e){const{messages:t,status:n,error:a,history:r,labels:o}=e,s=A(null),i=$(()=>function(e){const t=/* @__PURE__ */new Map;for(const n of X(e).values())t.set(n.approval_id,n);return t}(t),[t]),c=a?se(a,e.errorCode??null,o):null,d=t[t.length-1],p="ready"!==n||a||e.handedOver||"assistant"!==d?.role||!e.onAsk?[]:e.followups??[];return S(()=>{const e=s.current;e&&(e.scrollTop=e.scrollHeight)},[t,n]),/* @__PURE__ */_("div",{ref:s,role:"log","aria-label":e.title,"aria-live":"polite","aria-busy":"submitted"===n||"streaming"===n,className:"flex min-h-0 flex-1 flex-col gap-3 overflow-auto bg-gray-50 p-3",children:["loading"===r&&/* @__PURE__ */_("div",{role:"status",className:"flex items-center gap-2 text-xs text-gray-500",children:[
51
- /* @__PURE__ */R(k,{className:"h-3 w-3"}),o.loadingHistory]}),"failed"===r&&/* @__PURE__ */R(l,{tone:"warning",children:o.historyFailed}),0===t.length&&"idle"===r&&/* @__PURE__ */R("p",{className:"m-auto text-center text-sm text-gray-500",children:o.emptyState}),t.map((a,r)=>/* @__PURE__ */R(Je,{live:r===t.length-1&&("submitted"===n||"streaming"===n),message:a,toolLabels:e.toolLabels,labels:o,showReasoning:e.showReasoning,showToolOutput:e.showToolOutput,showUsage:e.showUsage,tableActions:e.tableActions,onApprove:e.onApprove,onLinkClick:e.onLinkClick,onOpenFile:e.onOpenFile,renderDataPart:e.renderDataPart,plans:i,userActions:e.userMessageActions,onOpenAttachment:e.onOpenAttachment,showCopy:e.showCopy,answerActions:e.answerActions,onRate:e.onRate},a.id)),e.onAsk&&/* @__PURE__ */R(Ne,{questions:p,label:o.followups,onAsk:e.onAsk}),e.handedOver&&/* @__PURE__ */R("div",{role:"status",className:"text-center text-xs text-gray-500",children:o.teamJoined}),"submitted"===n&&/* @__PURE__ */_("div",{role:"status",className:"flex items-center gap-2 text-xs text-gray-500",children:[
52
- /* @__PURE__ */R(k,{className:"h-3 w-3"}),o.thinking]}),c&&/* @__PURE__ */_("div",{role:"alert",className:"flex flex-col items-start gap-2",children:[
53
- /* @__PURE__ */R(l,{tone:"danger",children:c.text}),c.retryable&&e.onRetry&&"error"===n&&/* @__PURE__ */R(x,{size:"sm",variant:"secondary",onClick:e.onRetry,children:o.retry})]})]})}var qe={title:"Assistant",placeholder:"Ask a question…",inputLabel:"Message to the assistant",send:"Send",stop:"Stop",newChat:"New chat",open:"Open assistant",close:"Close assistant",thinking:"Thinking",loadingHistory:"Loading the conversation",historyFailed:"The earlier conversation could not be loaded.",emptyState:"Ask me anything to get started.",approvalNeeded:"Approval needed",approve:"Approve",deny:"Deny",approved:"Approved",declined:"Declined",toolFailed:"did not complete",toolDeclined:"was not approved",details:"Details",stepSources:"Where these figures came from",reasoning:"Reasoning",genericError:"Something went wrong. Please try again.",connectionDropped:"The connection dropped. Your question may still be answering; reopen the chat in a moment.",retry:"Retry",working:"Working",steps:"Steps",teamName:"Team",teamJoined:"A team member has joined",plan:"Plan",planSummary:"Plan: {done} of {total} done",planProposed:"waiting for your approval",planApproved:"approved, starting",planRunning:"in progress",planCompleted:"finished",planFailed:"stopped — not every step ran",planDenied:"not approved — nothing was changed",planExpired:"expired — nothing was changed",planApprovalHeading:"Approve this plan of {count} steps",approvePlan:"Approve plan",replyStats:"{tokens} tokens · {seconds} s · {rate} tok/s",replyTokens:"{tokens} tokens",streaming:"Streaming",streamingRate:"Streaming · ~{rate} tok/s",followups:"Suggested follow-up questions",attach:"Attach a file",attaching:"Uploading",removeAttachment:"Remove {name}",openAttachment:"Open {name}",copyAnswer:"Copy",copied:"Copied",readOnly:"You can read this chat but not continue it.",rateAnswer:"Rate this answer",rateUp:"Helpful",rateDown:"Not helpful",rateNote:"What was wrong? (optional)",rateNoteSend:"Send",rateNoteSkip:"Skip",rateThanks:"Thanks for telling us.",rateFailed:"Your rating could not be saved.",openFile:"Open {name}"},Qe=(e,t)=>`${e.replace(/\/+$/,"")}/${t}`;function Ge(e){return Qe(e,"assistant/chat/")}function Ze(e,t){return Qe(e,`assistant/chat/${encodeURIComponent(t)}/`)}function Ke(e){const t=A(e);t.current=e;const n=A(e.conversationId?{id:e.conversationId}:null),[a,r]=j("idle"),[o,s]=j(!1),[l,i]=j(null),[c,d]=j([]),[p,u]=j(n.current),m=O(e=>{n.current=e,u(e)},[]),h=O((e,n)=>(t.current.fetch??fetch)(e,n),[]),f=$(()=>new F({api:Ge(e.apiBase),fetch:h,prepareSendMessagesRequest:async({messages:e})=>{const{apiBase:a,getHeaders:r,credentials:o}=t.current;return{api:Ge(a),body:Q(e,n.current?.id??null),headers:await(r?.())??{},...o?{credentials:o}:{}}}}),[h]),g=z({transport:f,sendAutomaticallyWhen:E,onData:e=>{if(!q.has(e.type))return void t.current.onDataPart?.(e);if("data-error"===e.type)return void i(e.data.code);if("data-followups"===e.type)return void d(function(e){const t=e?.questions;if(!Array.isArray(t))return[];const n=[];for(const e of t){if("string"!=typeof e)continue;const t=e.trim();!t||t.includes("\n")||n.includes(t)||n.push(t)}return n.slice(0,3)}(e.data));if("data-conversation"!==e.type)return;const{id:a,guest_token:r}=e.data,o=n.current,s=r??(o?.id===a?o.guestToken:void 0);o&&o.id===a&&o.guestToken===s||(m(s?{id:a,guestToken:s}:{id:a}),t.current.onConversation?.(n.current))}}),{setMessages:b,stop:v}=g,y=O(async(e,n)=>{const{apiBase:a,getHeaders:o,credentials:l,onConversation:i}=t.current;r("loading"),d([]);try{const t=await h(Ze(a,e),{method:"GET",headers:await(o?.())??{},...l?{credentials:l}:{},signal:n});if(n.aborted)return;if(404===t.status)return m(null),i?.(null),void r("idle");if(!t.ok)throw new Error(`history ${t.status}`);const c=await t.json();if(n.aborted)return;s(!0===c.handed_over),b(e=>e.length>0?e:te(c)),r("idle")}catch{n.aborted||r("failed")}},[h,b,m]),x=e.conversationId??null;S(()=>{if(x===(n.current?.id??null)&&g.messages.length>0)return;if(null===x)return n.current&&(m(null),v(),b([]),d([])),void r("idle");n.current?.id===x||m({id:x});const e=new AbortController;return y(x,e.signal),()=>e.abort()},[x,y,b,v,m]);const w=O(async e=>{const a=n.current?.id;if(a)try{const{apiBase:r,getHeaders:o,credentials:l}=t.current,i=await h(Ze(r,a),{method:"GET",headers:await(o?.())??{},...l?{credentials:l}:{},...e?{signal:e}:{}});if(!i.ok||e?.aborted||n.current?.id!==a)return;const c=await i.json();s(!0===c.handed_over);const d=te(c).filter(e=>e.metadata?.source);if(0===d.length)return;b(e=>{const t=new Set(e.map(e=>e.id)),n=d.filter(e=>!t.has(e.id));return n.length>0?[...e,...n]:e})}catch{}},[h,b]),k=A(w);k.current=w;const{status:N}=g,C="submitted"===N||"streaming"===N,T=A(!1),R=A(!1),_=!!e.subscribe;S(()=>{const e=T.current&&!C;if(T.current=C,!e)return;if(_&&!R.current)return;R.current=!1;const t=new AbortController;return k.current(t.signal),()=>t.abort()},[C,_]);const I=A(C);I.current=C;const M=p?.id,D=p?.guestToken;S(()=>{const e=n.current,a=t.current.subscribe;if(e&&a)return a(e,()=>{I.current?R.current=!0:k.current()})??void 0},[M,D]);const L=O((e,t=[])=>{const n=e.trim();n&&(i(null),d([]),g.sendMessage(t.length>0?{text:n,files:t.map(J)}:{text:n}))},[g]),U=O(()=>{le(g.messages)&&(i(null),d([]),g.regenerate())},[g]),B=O((e,t)=>{i(null),d([]),g.addToolApprovalResponse({id:e,approved:t})},[g]),H=O(()=>{v(),m(null),b([]),r("idle"),s(!1),i(null),d([]),t.current.onConversation?.(null)},[b,v,m]);return{conversationId:p?.id??null,messages:g.messages,status:g.status,error:g.error,errorCode:l,canRetry:le(g.messages),retry:U,historyState:a,handedOver:o,followups:c,send:L,stop:v,approve:B,reset:H}}function Xe(e){const t={...qe,...e.labels},n=e.variant??"panel",a=Ke(e),r="submitted"===a.status||"streaming"===a.status,o=A(e.onBusyChange);o.current=e.onBusyChange,S(()=>{o.current?.(r)},[r]);const s="window"===n,l=e.showHeader??"window"!==n,i=e.title??t.title,c=V(a.messages),d=!0===e.readOnly,{onRate:u}=e,{conversationId:m}=a,h=A(!1),{send:f}=a;return S(()=>{h.current||d||e.conversationId||!e.initialQuestion?.trim()||(h.current=!0,f(e.initialQuestion))},[]),/* @__PURE__ */_("section",{"aria-label":i,className:`flex h-full min-h-0 flex-col bg-white text-gray-900 ${e.className??""}`.trim(),children:[l&&/* @__PURE__ */_("header",{className:"flex items-center gap-2 border-b border-gray-200 px-3 py-2",children:[
54
- /* @__PURE__ */R("h2",{className:"min-w-0 flex-1 truncate text-sm font-semibold",children:i}),a.messages.length>0&&/* @__PURE__ */R(x,{size:"sm",variant:"ghost",onClick:a.reset,children:t.newChat}),e.onClose&&/* @__PURE__ */R(p,{size:"sm","aria-label":t.close,onClick:e.onClose,children:/* @__PURE__ */R(w,{name:"close"})})]}),
55
- /* @__PURE__ */R(Ye,{messages:a.messages,status:a.status,error:a.error,errorCode:a.errorCode,history:a.historyState,handedOver:a.handedOver,labels:t,title:i,toolLabels:e.toolLabels,showReasoning:s&&!0===e.showReasoning,showToolOutput:s,showUsage:s&&!0===e.showUsage,tableActions:e.tableActions,onApprove:a.approve,onLinkClick:e.onLinkClick,onOpenFile:e.onOpenFile,renderDataPart:e.renderDataPart,userMessageActions:d?void 0:e.userMessageActions,showCopy:e.showCopy??s,answerActions:e.answerActions,onOpenAttachment:e.attachments?.onOpen,followups:a.followups,onAsk:d?void 0:a.send,onRetry:d?void 0:a.canRetry?a.retry:void 0,onRate:u&&m&&!d?(e,t)=>u({conversationId:m,runId:e,rating:t}):void 0}),c&&/* @__PURE__ */R(we,{plan:c,labels:t},c.id),!d&&e.composerTop,d?/* @__PURE__ */R("p",{role:"note",className:"border-t border-gray-200 px-3 py-2 text-xs text-gray-500",children:t.readOnly}):/* @__PURE__ */R(L,{labels:t,placeholder:e.placeholder??t.placeholder,busy:r,focusWhen:e.focusComposer,onSend:a.send,onStop:a.stop,onNewChat:!l&&!1!==e.showNewChat&&a.messages.length>0?a.reset:void 0,actions:e.composerActions,attachments:e.attachments})]})}function Ve(e){const t={...qe,...e.labels},[n,a]=j(e.defaultOpen??!1),r=T(),o=A(null),s=A(n),l=t=>{a(t),e.onOpenChange?.(t)};return S(()=>{s.current&&!n&&o.current?.focus(),s.current=n},[n]),/* @__PURE__ */_("div",{className:"rosh-assistant",style:{display:"contents"},children:[n&&/* @__PURE__ */R("div",{id:r,role:"dialog","aria-label":e.title??t.title,onKeyDown:e=>{"Escape"===e.key&&l(!1)},className:"fixed inset-x-2 bottom-20 z-[var(--z-window,1000)] h-[min(34rem,calc(100dvh-6rem))] overflow-hidden rounded-xl border border-gray-200 shadow-xl sm:inset-x-auto sm:right-4 sm:w-96",children:/* @__PURE__ */R(Xe,{...e,onClose:()=>l(!1),focusComposer:!0})}),
56
- /* @__PURE__ */R("button",{ref:o,type:"button","aria-expanded":n,"aria-controls":n?r:void 0,"aria-label":n?t.close:t.open,onClick:()=>l(!n),className:"fixed bottom-4 right-4 z-[var(--z-window,1000)] flex h-12 w-12 items-center justify-center rounded-full shadow-lg bg-[var(--assistant-launcher-bg,var(--color-blue-600))] text-[var(--assistant-launcher-ink,var(--color-white))] hover:bg-[var(--assistant-launcher-bg-hover,var(--color-blue-700))] focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-[var(--assistant-launcher-bg,var(--color-blue-600))]",children:/* @__PURE__ */R(w,n?{name:"close",size:20}:{name:"chat-bubble-left-right",size:22})})]})}function et(e){if("bubble"===e.variant)/* @__PURE__ */return R(Ve,{...e});const t="window"!==e.variant;/* @__PURE__ */
57
- return R(Xe,{...e,className:`${t?"border-l border-gray-200":""} ${e.className??""}`.trim()})}export{je as ApprovalCard,et as AssistantChat,Je as AssistantMessage,qe as DEFAULT_ASSISTANT_CHAT_LABELS,q as OWN_DATA_PARTS,ke as PlanApprovalCard,we as PlanChecklist,Oe as ToolStep,J as attachmentPart,Y as attachmentsOf,Q as buildRequestBody,Re as estimateTokens,se as failureView,H as filesOf,Me as finishedStats,re as isDroppedConnection,De as liveStats,te as messagesFromHistory,V as pinnedPlan,X as plansOf,$e as tokensPerSecond,B as toolSummariesOf};
2
+ import{StepChain as e,StepChainItem as t}from"../chunk-RBD7SB6M.js";import{Markdown as n}from"../chunk-7JJUI52C.js";import{Divider as a}from"../chunk-DFOFEBYX.js";import{Textarea_default as r}from"../chunk-PB7G6CJ7.js";import"../chunk-UJUTS6LJ.js";import"../chunk-PJPK2ADX.js";import{useContextMenu as o,ContextMenu as s}from"../chunk-NU2YQSOP.js";import{Banner as l}from"../chunk-7WLFHDWA.js";import"../chunk-JWX7QRGE.js";import{Input_default as i}from"../chunk-MAMWQCJ6.js";import"../chunk-AYZY3YNC.js";import{AttachButton as c,AttachmentDropZone as d}from"../chunk-KJHXCVNI.js";import{CloseGlyph as p}from"../chunk-D4KZOYXQ.js";import"../chunk-BJONHLET.js";import{IconButton_default as u}from"../chunk-RUTUVS4H.js";import{useFileIntake as m,humanSize as h,FileIntakeAlert as f}from"../chunk-LYX55RI3.js";import{parseChartSpec as g}from"../chunk-CR7T435F.js";import{SpecChart as y}from"../chunk-UEIJSV45.js";import{formatBytes as b}from"../chunk-X2S2XDZI.js";import"../chunk-5OTS2G3M.js";import"../chunk-36BRD5J3.js";import"../chunk-GVH3NG6G.js";import"../chunk-QMYQ4B5A.js";import"../chunk-CK2YOGUS.js";import"../chunk-2GPHHW7C.js";import"../chunk-VFC6QUEN.js";import"../chunk-NBKQADMY.js";import"../chunk-465RRWBY.js";import{ChartSkeleton as v}from"../chunk-MCMUJDEP.js";import"../chunk-CNYAHYE6.js";import"../chunk-HAFB45DT.js";import"../chunk-5QFPTDQF.js";import"../chunk-URHGHXDN.js";import"../chunk-LNARMEEZ.js";import{Button_default as x}from"../chunk-NHH2MXFU.js";import"../chunk-UQYNPYF4.js";import{Icon as w}from"../chunk-FSPFV4MI.js";import"../chunk-J75ZT2JQ.js";import"../chunk-HL6JSDN3.js";import{SpinnerRing as k}from"../chunk-R2VKEMZH.js";import"../chunk-MRJKZWWV.js";import"../chunk-OZAAIE4E.js";import"../chunk-BCDG4N6L.js";import"../chunk-PGN5ME7B.js";import"../chunk-62LW225J.js";import"../chunk-GLUJS42B.js";import"../chunk-D65T4H6J.js";import"../chunk-TLRCTNUF.js";import"../chunk-DTJRIWFR.js";import"../chunk-4CPE5NBC.js";import"../chunk-QCFN3ET4.js";import"../chunk-2JWPNR2U.js";import"../chunk-MAFUXCPZ.js";import"../chunk-TZFACUMR.js";import"../chunk-TWVUQUUD.js";import{useShellStrings as N}from"../chunk-PEM7UXQ3.js";import"../chunk-C3QOHMR6.js";import{useRef as A,Fragment as C,useState as j,useEffect as S,useId as $,useCallback as T,useMemo as O}from"react";import{isToolUIPart as R,getToolName as _,DefaultChatTransport as M,lastAssistantMessageIsCompleteWithApprovalResponses as F}from"ai";import{jsx as I,jsxs as B,Fragment as E}from"react/jsx-runtime";import{useChat as D}from"@ai-sdk/react";function z(e){if(!R(e))return null;const t=e;return{toolName:_(e),toolCallId:t.toolCallId,state:t.state,input:t.input,output:t.output,errorText:t.errorText,approvalId:t.approval?.id,approved:t.approval?.approved}}function L(e){const t=/* @__PURE__ */new Map;for(const n of e.parts){if("data-tool-summary"!==n.type)continue;const e=n.data;e&&"string"==typeof e.tool_call_id&&Array.isArray(e.rows)&&e.rows.length>0&&t.set(e.tool_call_id,e)}return t}function P(e){const t=/* @__PURE__ */new Map;for(const n of e.parts){if("data-file"!==n.type)continue;const e=n.data;e&&"string"==typeof e.id&&"string"==typeof e.filename&&t.set(e.id,e)}return[...t.values()]}function U(e){return e.parts.map(e=>"text"===e.type?e.text:"").join("")}var H="efficient-attachment:";function J(e){return{type:"file",mediaType:e.content_type,filename:e.filename,url:`${H}${e.id}`,providerMetadata:{efficient:{size:e.size}}}}function W(e){const t=[];for(const n of e.parts){if("file"!==n.type||!n.url.startsWith(H))continue;const e=n.providerMetadata?.efficient?.size;t.push({id:n.url.slice(21),filename:n.filename??"",content_type:n.mediaType,size:"number"==typeof e?e:0})}return t}var Y=/* @__PURE__ */new Set(["data-conversation","data-plan","data-followups","data-tool-summary","data-error","data-file","data-approval","data-busy"]);function Q(e,t){const n=e[e.length-1];if(!n)throw new Error("assistant chat: no message to send");if("user"===n.role){const e=U(n).trim();if(!e)throw new Error("assistant chat: empty message");const a=W(n).map(e=>e.id);return{conversation_id:t,text:e,approvals:[],...a.length>0?{attachments:a}:{}}}const a=function(e){const t=[];for(const n of e.parts){if(!R(n))continue;const e=n;if("approval-responded"!==e.state||!e.approval||"boolean"!=typeof e.approval.approved)continue;const a={approval_id:e.approval.id,approved:e.approval.approved};e.approval.reason&&(a.reason=e.approval.reason),t.push(a)}return t}(n);if(0===a.length)throw new Error("assistant chat: no approval decision to send");return{conversation_id:t,text:null,approvals:a}}function q(e,t){const n=t.trim();if(!n)return!1;const a=n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return new RegExp(`(^|[^\\p{L}\\p{N}_])${a}(?![\\p{L}\\p{N}_])`,"iu").test(e)}function G(e,t){return q(e,t)?e:`${t.trim()} ${e.trimStart()}`}function X(e){const t=e.map(e=>e.name).filter(Boolean);return t.length<=1?t[0]??"":`${t.slice(0,-1).join(", ")} and ${t[t.length-1]}`}var Z=/* @__PURE__ */new Set(["proposed","approved","running"]);function K(e){return Z.has(e.status)}function V(e){const t=[];for(const n of e.parts)"data-plan"===n.type&&t.push(n.data);return t}function ee(e){const t=/* @__PURE__ */new Map;for(const n of e)for(const e of V(n))t.delete(e.id),t.set(e.id,e);return t}function te(e){const t=[...ee(e).values()],n=t[t.length-1];if(!n)return null;if(K(n))return n;const a=e[e.length-1];return a&&"assistant"===a.role&&V(a).some(e=>e.id===n.id)?n:null}function ne(e){const t={};return e.source&&e.source!==e.role&&(t.source=e.source),e.author&&(t.author=e.author),e.asked_by&&(t.askedBy=e.asked_by),"assistant"===e.role&&e.run_id&&(t.run_id=e.run_id,t.rating=e.rating??null),Object.keys(t).length>0?{metadata:t}:{}}function ae(e){const t=e.messages.filter(e=>e.text).map(e=>({id:e.id,role:e.role,parts:[...(e.attachments??[]).map(J),{type:"text",text:e.text},...(e.files??[]).map(e=>({type:"data-file",id:`file-${e.id}`,data:e}))],...ne(e)})),n=(e.plans??[]).filter(K);return(e.pending_approvals.length>0||n.length>0)&&t.push({id:`pending-approvals-${e.id}`,role:"assistant",parts:[...n.map(e=>({type:"data-plan",id:e.id,data:e})),...e.pending_approvals.map(e=>({type:`tool-${e.tool_name}`,toolCallId:e.tool_call_id??e.approval_id,state:"approval-requested",input:e.input,approval:{id:e.approval_id}}))]}),t}function re(e,t){const n=e?.message?.trim();if(!n)return t;if(n.startsWith("{")){try{const e=JSON.parse(n);for(const t of["detail","errorText","message","title","error"]){const n=e[t];if("string"==typeof n&&n.trim())return n.trim()}}catch{return t}return t}return n.startsWith("<")||n.length>400?t:n}var oe=/^(load failed|failed to fetch|network ?error( when attempting to fetch resource)?|(the )?network connection was lost|error in input stream|terminated)\.?$/i;function se(e){return!(!e||"AbortError"===e.name)&&oe.test(e.message?.trim()??"")}var le=/* @__PURE__ */new Set(["budget_reached","not_permitted"]);function ie(e,t,n){return se(e)?{text:n.connectionDropped,retryable:!0}:{text:re(e,n.genericError),retryable:!(t&&le.has(t))}}function ce(e){const t=e[e.length-1];if(!t)return!1;if("user"===t.role)return""!==U(t).trim();const n=e[e.length-2];return!(!n||"user"!==n.role||!U(n).trim())&&!t.parts.some(e=>void 0!==z(e)?.approvalId)}function de({labels:e,placeholder:t,busy:n,focusWhen:a,onSend:o,onStop:s,onNewChat:l,actions:i,attachments:g,people:y}){const[b,v]=j(""),C=A(null),$=function(e){const[t,n]=j([]),a=A(0),r=A(!0);S(()=>()=>{r.current=!1},[]);const o=e?.upload,s=T(e=>{if(o)for(const t of e){const e=a.current++;n(n=>[...n,{key:e,name:t.name,size:t.size}]),o(t).then(t=>{r.current&&n(n=>n.map(n=>n.key===e?{...n,attachment:t}:n))},t=>{const a=t instanceof Error&&t.message?t.message:String(t);r.current&&n(t=>t.map(t=>t.key===e?{...t,error:a}:t))})}},[o]),l=t.some(e=>!e.attachment&&!e.error),i=t.flatMap(e=>e.attachment?[e.attachment]:[]);return{pending:t,add:s,remove:e=>n(t=>t.filter(t=>t.key!==e)),clear:()=>n([]),uploading:l,ready:i}}(g),O=N().files,R=m({accept:g?.accept,maxSizeBytes:g?.maxSizeBytes,maxFiles:g?.maxFiles??5,acceptHint:g?.acceptHint,currentCount:$.pending.length,disabled:!g,onAccept:$.add});S(()=>{a&&C.current?.focus()},[a]);const _=n||$.uploading||!b.trim(),M=()=>{_||(o(b,$.ready),v(""),$.clear(),R.clearRejections())},F=!!y&&(q(b,e.assistantMention)||$.pending.length>0),E=y?/* @__PURE__ */B("div",{className:"flex items-center gap-2 px-3 pt-2 text-xs",children:[
3
+ /* @__PURE__ */I("span",{role:"status",className:"min-w-0 flex-1 truncate "+(F?"text-accent-text":"text-ink-faint"),children:F?e.toAssistant:e.toPeople.replace("{names}",y)}),!F&&/* @__PURE__ */I(x,{type:"button",size:"sm",variant:"ghost",onClick:()=>{v(t=>G(t,e.assistantMention)),C.current?.focus()},children:e.askAssistant})]}):null,D=/* @__PURE__ */B("form",{className:("flex items-end gap-2 p-3 "+(g||y?"":"border-t border-gray-200")).trim(),onSubmit:e=>{e.preventDefault(),M()},children:[l&&/* @__PURE__ */I(u,{type:"button",variant:"ghost","aria-label":e.newChat,title:e.newChat,onClick:l,children:/* @__PURE__ */I(w,{name:"add"})}),g&&/* @__PURE__ */I(c,{variant:"icon",label:e.attach,onClick:R.open,disabled:n}),
4
+ /* @__PURE__ */I("div",{className:"min-w-0 flex-1",children:/* @__PURE__ */I(r,{ref:C,"aria-label":e.inputLabel,placeholder:t,rows:1,autoGrow:!0,value:b,onChange:e=>v(e.target.value),onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||e.nativeEvent.isComposing||(e.preventDefault(),M())},className:"max-h-32"})}),i?.map(e=>e.icon?/* @__PURE__ */I(u,{type:"button",variant:"ghost","aria-label":e.label,title:e.label,disabled:!b.trim(),onClick:()=>e.onSelect(b.trim()),children:/* @__PURE__ */I(w,{name:e.icon})},e.key):/* @__PURE__ */I(x,{type:"button",variant:"ghost",disabled:!b.trim(),onClick:()=>e.onSelect(b.trim()),children:e.label},e.key)),/* @__PURE__ */I(x,n?{type:"button",variant:"secondary",onClick:s,children:e.stop}:{type:"submit",disabled:_,children:e.send})]});return g?/* @__PURE__ */B(d,{intake:R,className:"border-t border-gray-200",children:[E,$.pending.length>0&&/* @__PURE__ */I("ul",{className:"flex flex-wrap gap-2 px-3 pt-3",children:$.pending.map(t=>/* @__PURE__ */B("li",{className:"flex max-w-full items-center gap-2 rounded-md border py-1 pl-2 pr-1 text-xs "+(t.error?"border-red-200 bg-red-50 text-red-700":"border-gray-200 bg-gray-50 text-gray-700"),children:[t.attachment||t.error?/* @__PURE__ */I(w,{name:"page",size:14,"aria-hidden":"true"}):/* @__PURE__ */I("span",{role:"status","aria-label":e.attaching,className:"inline-flex",children:/* @__PURE__ */I(k,{className:"h-3 w-3"})}),
5
+ /* @__PURE__ */I("span",{className:"min-w-0 truncate",title:t.error??t.name,children:t.name}),
6
+ /* @__PURE__ */I("span",{className:"shrink-0 tabular-nums text-gray-400",children:h(t.size,O)}),
7
+ /* @__PURE__ */I("button",{type:"button",onClick:()=>$.remove(t.key),"aria-label":e.removeAttachment.replace("{name}",t.name),className:"shrink-0 rounded p-0.5 text-gray-400 hover:bg-gray-200 hover:text-gray-600",children:/* @__PURE__ */I(p,{className:"h-3.5 w-3.5"})})]},t.key))}),$.pending.some(e=>e.error)&&/* @__PURE__ */I("ul",{role:"alert",className:"flex flex-col gap-0.5 px-3 pt-1",children:$.pending.flatMap(e=>e.error?[/* @__PURE__ */I("li",{className:"text-xs text-red-600",children:`${e.name}: ${e.error}`},e.key)]:[])}),
8
+ /* @__PURE__ */I(f,{rejections:R.rejections,className:"px-3 pt-1"}),D]}):E?/* @__PURE__ */B("div",{className:"border-t border-line",children:[E,D]}):D}function pe(e){const t=e.replace(/^tool-/,"").replace(/([a-z0-9])([A-Z])/g,"$1 $2").replace(/[_\-.]+/g," ").trim().toLowerCase();return t?t.charAt(0).toUpperCase()+t.slice(1):e}var ue={propose_plan:{label:"Plan the changes",running:"Planning the changes",done:"Planned the changes"}};function me(e,t){const n=t?.[e]??ue[e];return"string"==typeof n?{label:n}:n??{label:pe(e)}}function he(e,t){return me(e,t).label}function fe(e){return e&&"object"==typeof e&&!Array.isArray(e)?e:{}}function ge(e,t,n){const a=me(e,n).describe;if(!a)return"";try{return a(fe(t))?.trim()??""}catch{return""}}function ye(e,t){return null==e?"":"boolean"==typeof e?e?"Yes":"No":"object"!=typeof e?String(e):Array.isArray(e)?e.map(e=>ye(e,t+1)).filter(Boolean).join(", "):t>=3?"…":Object.entries(e).map(([e,n])=>{const a=ye(n,t+1);return a?`${pe(e)}: ${a}`:""}).filter(Boolean).join("; ")}function be(e){const t=fe(e),n=[];for(const[e,a]of Object.entries(t)){if(e.startsWith("_"))continue;const t=ye(a,0);t&&n.push({label:pe(e),value:t})}return 0===n.length&&null!=e&&"object"!=typeof e&&n.push({label:"Value",value:ye(e,0)}),n}var ve={proposed:"planProposed",approved:"planApproved",running:"planRunning",completed:"planCompleted",failed:"planFailed",denied:"planDenied",expired:"planExpired"},xe={pending:"pending",running:"active",done:"complete",failed:"failed",skipped:"skipped"};function we(e,t){const n=ge(e.tool_name,e.input,t);return`${he(e.tool_name,t)}${n?` ${n}`:""}`}function ke(e,t){return e.replace(/\{(\w+)\}/g,(e,n)=>n in t?String(t[n]):e)}function Ne(e,t){const n=e.steps.filter(e=>"done"===e.status).length;return`${ke(t.planSummary,{done:n,total:e.steps.length})} · ${t[ve[e.status]]}`}function Ae({plan:n,labels:a}){/* @__PURE__ */
9
+ return I("section",{"aria-label":a.plan,className:"border-t border-gray-200 bg-white px-3 py-2",children:/* @__PURE__ */I(e,{summary:Ne(n,a),busy:K(n),label:a.plan,children:n.steps.map(e=>/* @__PURE__ */I(t,{label:e.title,status:xe[e.status],description:"done"!==e.status&&e.result_summary?e.result_summary:void 0},e.id))})})}function Ce({approvalId:e,plan:t,input:n,labels:a,toolLabels:r,onApprove:o}){const s=function(e,t){if(e)return e.steps.map(e=>({key:e.id,title:e.title,tool_name:e.tool_name,input:e.input}));const n=t?.steps;return Array.isArray(n)?n.map((e,t)=>{const n=e??{};return{key:String(t),title:"string"==typeof n.title?n.title:"",tool_name:"string"==typeof n.tool?n.tool:"",input:n.args}}):[]}(t,n),l=ke(a.planApprovalHeading,{count:s.length});/* @__PURE__ */
10
+ return B("div",{role:"group","aria-label":l,className:"rounded-lg border border-amber-300 bg-amber-50 p-3 text-sm",children:[
11
+ /* @__PURE__ */I("div",{className:"font-medium text-gray-900",children:l}),
12
+ /* @__PURE__ */I("ol",{className:"mt-2 list-decimal space-y-2 pl-5",children:s.map(e=>{const t=be(e.input);/* @__PURE__ */
13
+ return B("li",{children:[
14
+ /* @__PURE__ */I("div",{className:"font-medium text-gray-900",children:we(e,r)}),e.title&&/* @__PURE__ */I("div",{className:"text-xs text-gray-600",children:e.title}),t.length>0&&/* @__PURE__ */I("dl",{className:"mt-1 grid grid-cols-[max-content_1fr] gap-x-3 gap-y-1 text-xs",children:t.map(e=>/* @__PURE__ */B("div",{className:"contents",children:[
15
+ /* @__PURE__ */I("dt",{className:"text-gray-500",children:e.label}),
16
+ /* @__PURE__ */I("dd",{className:"min-w-0 break-words text-gray-800",children:e.value})]},e.label))})]},e.key)})}),
17
+ /* @__PURE__ */B("div",{className:"mt-3 flex gap-2",children:[
18
+ /* @__PURE__ */I(x,{size:"sm",onClick:()=>o(e,!0),children:a.approvePlan}),
19
+ /* @__PURE__ */I(x,{size:"sm",variant:"secondary",onClick:()=>o(e,!1),children:a.deny})]})]})}function je({questions:e,label:t,onAsk:n}){return 0===e.length?null:/* @__PURE__ */I("div",{role:"group","aria-label":t,className:"flex flex-wrap gap-2 pl-1",children:e.map(e=>/* @__PURE__ */I(x,{size:"sm",variant:"secondary",onClick:()=>n(e),children:e},e))})}function Se({initial:e,labels:t,onRate:n}){const[a,r]=j(e??null),[o,s]=j(!1),[l,c]=j(""),[d,p]=j(!1),[m,h]=j(!1),[f,g]=j(!1),y=async e=>{const t=a;r(e),h(!1),g(!0);try{return await n(e),!0}catch{return r(t),h(!0),!1}finally{g(!1)}},b=e=>{const n="up"===e?t.rateUp:t.rateDown;/* @__PURE__ */
20
+ return I(u,{size:"sm","aria-label":n,title:n,"aria-pressed":a?.verdict===e,disabled:f,onClick:()=>{(async e=>{if(p(!1),a?.verdict===e)return s(!1),void await y(null);const t=await y({verdict:e,note:""});s(t&&"down"===e),c("")})(e)},children:/* @__PURE__ */I(w,{name:"hand-thumb-up",className:"down"===e?"h-3.5 w-3.5 rotate-180":"h-3.5 w-3.5"})})};/* @__PURE__ */
21
+ return B("div",{role:"group","aria-label":t.rateAnswer,className:"flex min-w-0 flex-1 flex-col gap-1",children:[
22
+ /* @__PURE__ */B("div",{className:"flex items-center gap-1",children:[b("up"),b("down"),d&&/* @__PURE__ */I("span",{role:"status",className:"px-1 text-xs text-gray-500",children:t.rateThanks}),m&&/* @__PURE__ */I("span",{role:"alert",className:"px-1 text-xs text-red-600",children:t.rateFailed})]}),o&&/* @__PURE__ */B("form",{className:"flex items-center gap-2",onSubmit:e=>{(async e=>{e.preventDefault();const t=l.trim();t&&!await y({verdict:"down",note:t})||(s(!1),p(Boolean(t)))})(e)},children:[
23
+ /* @__PURE__ */I("div",{className:"min-w-0 flex-1",children:/* @__PURE__ */I(i,{size:"sm","aria-label":t.rateNote,placeholder:t.rateNote,maxLength:500,value:l,onChange:e=>c(e.target.value),autoFocus:!0})}),
24
+ /* @__PURE__ */I(x,{type:"submit",size:"sm",variant:"secondary",disabled:f||!l.trim(),children:t.rateNoteSend}),
25
+ /* @__PURE__ */I(x,{type:"button",size:"sm",variant:"ghost",onClick:()=>s(!1),children:t.rateNoteSkip})]})]})}function $e({rows:e,label:t}){/* @__PURE__ */
26
+ return I("dl",{"aria-label":t,className:"grid grid-cols-[max-content_1fr] gap-x-3 gap-y-1 text-xs",children:e.map((e,t)=>/* @__PURE__ */B("div",{className:"contents",children:[
27
+ /* @__PURE__ */I("dt",{className:"text-gray-500",children:e.label}),
28
+ /* @__PURE__ */I("dd",{className:"min-w-0 break-words "+(e.warn?"font-medium text-amber-700":"text-gray-800"),children:e.value})]},`${e.label}-${t}`))})}function Te({tool:e,toolLabels:t,labels:n,onApprove:a}){const r=ge(e.toolName,e.input,t),o=be(e.input),s=e.approvalId,l=`${n.approvalNeeded}: ${he(e.toolName,t)}${r?` ${r}`:""}`;/* @__PURE__ */
29
+ return B("div",{role:"group","aria-label":l,className:"rounded-lg border border-amber-300 bg-amber-50 p-3 text-sm",children:[
30
+ /* @__PURE__ */I("div",{className:"font-medium text-gray-900",children:l}),o.length>0&&/* @__PURE__ */I("div",{className:"mt-2",children:/* @__PURE__ */I($e,{rows:o})}),
31
+ /* @__PURE__ */B("div",{className:"mt-3 flex gap-2",children:[
32
+ /* @__PURE__ */I(x,{size:"sm",onClick:()=>a(s,!0),children:n.approve}),
33
+ /* @__PURE__ */I(x,{size:"sm",variant:"secondary",onClick:()=>a(s,!1),children:n.deny})]})]})}var Oe={running:"active",done:"complete",failed:"failed",declined:"stopped",waiting:"waiting"};function Re(e,t,n){return function(e,t,n,a,r,o){const s=me(n,r),l=ge(n,a,r),i=(e,t)=>({kind:e,base:t,subject:l,text:l?`${t} ${l}`:t});switch(e){case"output-available":return i("done",s.done??s.label);case"output-error":return i("failed",`${s.label} ${o.toolFailed}`);case"output-denied":return i("declined",`${s.label} ${o.toolDeclined}`);case"approval-requested":return i("waiting",`${o.approvalNeeded}: ${s.label}`);case"approval-responded":return!1===t?i("declined",`${s.label} — ${o.declined}`):i("running",`${o.approved}: ${s.running??s.label}`);default:return i("running",s.running??s.label)}}(e.state,e.approved,e.toolName,e.input,t,n)}function _e({tool:e,summary:n,toolLabels:a,labels:r,showOutput:o}){const s=Re(e,a,r),l=be(e.input),i=o&&"output-available"===e.state?be(e.output):[],c=o&&"output-error"===e.state&&e.errorText?e.errorText:"",d="output-available"===e.state&&n?n.rows:[];let p=null;return(l.length>0||i.length>0||c)&&(p=/* @__PURE__ */B("details",{className:d.length>0?"mt-1":void 0,children:[
34
+ /* @__PURE__ */I("summary",{className:"cursor-pointer select-none",children:r.details}),
35
+ /* @__PURE__ */B("div",{className:"mt-1 space-y-2",children:[l.length>0&&/* @__PURE__ */I($e,{rows:l}),i.length>0&&/* @__PURE__ */I($e,{rows:i}),c&&/* @__PURE__ */I("div",{className:"text-red-600",children:c})]})]})),/* @__PURE__ */B(t,{label:s.base,description:s.subject||void 0,status:Oe[s.kind],children:[d.length>0&&/* @__PURE__ */I($e,{rows:d,label:r.stepSources}),p]})}function Me(e,t){return e>0&&t>=100?e/(t/1e3):null}function Fe(e){return Math.ceil(e.length/4)}var Ie=(e,t)=>e.replace(/\{(\w+)\}/g,(e,n)=>t[n]??e),Be=e=>Math.round(e).toLocaleString();function Ee(e,t){const n=Me(e.output_tokens,e.generation_ms);return null===n?Ie(t.replyTokens,{tokens:Be(e.output_tokens)}):Ie(t.replyStats,{tokens:Be(e.output_tokens),seconds:(e.generation_ms/1e3).toFixed(1),rate:Be(n)})}function De(e,t,n){const a=t>=1e3?Me(Fe(e),t):null;return null===a?n.streaming:Ie(n.streamingRate,{rate:Be(a)})}function ze(e){if("chart"!==e.lang)return null;if(!e.closed)/* @__PURE__ */return I(v,{height:200});const t=g(e.code);return t?/* @__PURE__ */I(y,{spec:t}):null}function Le(e,t){return"approval-responded"===e.state&&t.some(t=>{return t.toolName===e.toolName&&"approval-requested"!==t.state&&(t.toolCallId===e.toolCallId||(n=t.input,a=e.input,JSON.stringify(n)===JSON.stringify(a)));var n,a})}function Pe(e,t,n,a){const r=e.flatMap(e=>"tool"===e.kind?[Re(e.tool,n,a)]:[]);if(t){const e=r.find(e=>"running"===e.kind);return e?e.base:a.working}const o=[...new Set(r.map(e=>e.base))];return o.length>0?o.join(" · "):a.reasoning}function Ue({message:e,live:t,labels:n}){const a=U(e),r=a.length>0,o=A(null),[s,l]=j(0);S(()=>{if(!t)return;null===o.current&&(o.current=performance.now());const e=setInterval(()=>l(performance.now()-(o.current??performance.now())),500);return()=>clearInterval(e)},[t]);const i=e.metadata?.usage;let c=null;return t?c=r?De(a,s,n):null:i&&(c=Ee(i,n)),c?/* @__PURE__ */I("div",{className:"px-1 text-xs leading-6 tabular-nums text-gray-500",children:c}):null}function He({files:e,labels:t,onOpen:n}){const a="flex max-w-full items-center gap-2 rounded-md border border-gray-200 bg-white px-2 py-1 text-xs text-gray-700";/* @__PURE__ */
36
+ return I("ul",{className:"flex max-w-[85%] flex-wrap justify-end gap-2",children:e.map(e=>{const r=/* @__PURE__ */B(E,{children:[
37
+ /* @__PURE__ */I(w,{name:"page",size:14,"aria-hidden":"true",className:"shrink-0"}),
38
+ /* @__PURE__ */I("span",{className:"min-w-0 truncate",children:e.filename})]});/* @__PURE__ */
39
+ return I("li",{className:"max-w-full",children:n?/* @__PURE__ */I("button",{type:"button",className:`${a} hover:bg-gray-50`,title:t.openAttachment.replace("{name}",e.filename),onClick:()=>n(e),children:r}):/* @__PURE__ */I("span",{className:a,children:r})},e.id)})})}function Je(e){return["xlsx"===e.kind?"Excel":String(e.kind||"").toUpperCase(),b(e.size)].filter(Boolean).join(" · ")}function We({file:e,labels:t,onOpen:n}){const a=/* @__PURE__ */B(E,{children:["pdf"===e.kind?/* @__PURE__ */I(w,{name:"document",size:20,className:"shrink-0"}):/* @__PURE__ */I(w,{name:"table",size:20,className:"shrink-0"}),
40
+ /* @__PURE__ */B("span",{className:"min-w-0 flex-1",children:[
41
+ /* @__PURE__ */I("span",{className:"block truncate text-sm font-medium text-gray-800",children:e.filename}),
42
+ /* @__PURE__ */I("span",{className:"block text-xs text-gray-500",children:Je(e)})]})]}),r="flex w-full max-w-sm items-center gap-2 rounded-lg border border-gray-200 bg-gray-50 px-3 py-2 text-left";return n?/* @__PURE__ */I("button",{type:"button",className:`${r} hover:border-blue-300 hover:bg-blue-50 focus:outline-none focus-visible:ring-2 focus-visible:ring-blue-500`,"data-assistant-file":e.id,"aria-label":t.openFile.replace("{name}",e.filename),onClick:()=>n(e),children:a}):/* @__PURE__ */I("div",{className:r,"data-assistant-file":e.id,children:a})}function Ye({message:e,labels:t,showCopy:n,actions:r,answer:o}){const[s,l]=j(!1);S(()=>{if(!s)return;const e=setTimeout(()=>l(!1),1500);return()=>clearTimeout(e)},[s]);const i=U(e);if(!i.trim()||!n&&!r?.length)return null;const c=async()=>{const e=Array.from(o.current?.querySelectorAll("[data-answer-text]")??[]);l(await async function(e,t){const n="undefined"!=typeof navigator?navigator.clipboard:void 0;if(!n)return!1;try{return t&&"undefined"!=typeof ClipboardItem&&n.write?(await n.write([new ClipboardItem({"text/html":new Blob([t],{type:"text/html"}),"text/plain":new Blob([e],{type:"text/plain"})})]),!0):(await n.writeText(e),!0)}catch{return!1}}(i,function(e){return e.map(e=>{const t=e.cloneNode(!0);return t.querySelectorAll("button, [data-chat-chrome]").forEach(e=>e.remove()),t.querySelectorAll("[class]").forEach(e=>e.removeAttribute("class")),t.removeAttribute("class"),t.querySelectorAll("table").forEach(e=>e.setAttribute("style","border-collapse:collapse")),t.querySelectorAll("th, td").forEach(e=>e.setAttribute("style","border:1px solid #d0d5dd;padding:4px 8px;text-align:left;vertical-align:top")),t.innerHTML.trim()}).filter(Boolean).join("\n")}(e)))},d=[];return n&&d.push(
43
+ /* @__PURE__ */I(x,{size:"sm",variant:"ghost",leftIcon:/* @__PURE__ */I(w,{name:s?"check":"copy",look:"mini",className:"h-3.5 w-3.5","aria-hidden":"true"}),onClick:()=>{c()},children:s?t.copied:t.copyAnswer},"copy")),r?.forEach(t=>d.push(
44
+ /* @__PURE__ */I(x,{size:"sm",variant:"ghost",leftIcon:t.icon?/* @__PURE__ */I(w,{name:t.icon,look:"mini",className:"h-3.5 w-3.5","aria-hidden":"true"}):void 0,onClick:()=>t.onSelect({id:e.id,text:i}),children:t.label},t.key))),/* @__PURE__ */I("div",{className:"ml-auto flex items-center gap-0.5","data-chat-chrome":"",children:d.map((e,t)=>/* @__PURE__ */B(C,{children:[t>0&&/* @__PURE__ */I("span",{className:"flex h-3",children:/* @__PURE__ */I(a,{orientation:"vertical"})}),e]},t))})}function Qe({text:e,actions:t,files:n,labels:a,onOpenAttachment:r}){const l=o(),i=/* @__PURE__ */I("div",{className:"max-w-[85%] whitespace-pre-wrap break-words rounded-2xl bg-blue-600 px-3 py-2 text-sm text-white",children:e}),c=n.length>0?/* @__PURE__ */I(He,{files:n,labels:a,onOpen:r}):null;return t?.length?/* @__PURE__ */B("div",{className:c?"flex flex-col items-end gap-2":"flex justify-end",onContextMenu:e=>l.open(e,void 0),children:[c,i,l.state&&/* @__PURE__ */I(s,{...l.props,"aria-label":e,items:t.map(t=>({key:t.key,label:t.label,onSelect:()=>t.onSelect(e)}))})]}):c?/* @__PURE__ */B("div",{className:"flex flex-col items-end gap-2",children:[c,i]}):/* @__PURE__ */I("div",{className:"flex justify-end",children:i})}function qe({message:a,toolLabels:r,labels:o,showReasoning:s,showToolOutput:l,showUsage:i,live:c,onApprove:d,plans:p,userActions:u,tableActions:m,onLinkClick:h,onOpenAttachment:f,onOpenFile:g,renderDataPart:y,showCopy:b,answerActions:v,onRate:x}){const w=a.metadata?.source,k=A(null);if("system"===w){const e=U(a);return e?/* @__PURE__ */I("div",{className:"text-center text-xs text-gray-500",children:e}):null}if("user"===a.role){const e=U(a);if(!e)return null;const t=a.metadata?.author;return t?/* @__PURE__ */B("div",{className:"flex flex-col items-start gap-0.5",children:[
45
+ /* @__PURE__ */I("div",{className:"px-1 text-xs text-ink-faint",children:t.name}),
46
+ /* @__PURE__ */I("div",{className:"max-w-[85%] whitespace-pre-wrap break-words rounded-2xl border border-line bg-surface-sunken px-3 py-2 text-sm text-ink",children:e})]}):/* @__PURE__ */I(Qe,{text:e,actions:u,files:W(a),labels:o,onOpenAttachment:f})}const N=a.parts.map(z),j=L(a),S=[],$=/* @__PURE__ */new Set,T=[];let O=-1;const R=e=>{O<0&&(O=S.push(null)-1),T.push(e)};if(a.parts.forEach((e,t)=>{if("text"===e.type)return void(e.text.trim()&&S.push(
47
+ /* @__PURE__ */I("div",{"data-answer-text":"",children:/* @__PURE__ */I(n,{renderFence:ze,tableActions:c?void 0:m,onLinkClick:h,children:e.text})},t)));if("data-file"===e.type){const t=e.data;return void(t&&"string"==typeof t.id&&!$.has(t.id)&&($.add(t.id),S.push(/* @__PURE__ */I(We,{file:t,labels:o,onOpen:g},`file-${t.id}`))))}if(y&&e.type.startsWith("data-")&&!Y.has(e.type)){const n=y(e,a);return void(n&&S.push(/* @__PURE__ */I(C,{children:n},`data-${t}`)))}if("reasoning"===e.type)return void(s&&e.text.trim()&&R({kind:"reasoning",key:`r${t}`,text:e.text}));const l=N[t];l&&(Le(l,N.slice(t+1).filter(e=>null!==e))||("approval-requested"===l.state&&l.approvalId&&"propose_plan"===l.toolName?S.push(
48
+ /* @__PURE__ */I(Ce,{approvalId:l.approvalId,plan:p?.get(l.approvalId),input:l.input,labels:o,toolLabels:r,onApprove:d},l.toolCallId)):"approval-requested"===l.state&&l.approvalId?S.push(
49
+ /* @__PURE__ */I(Te,{tool:l,toolLabels:r,labels:o,onApprove:d},l.toolCallId)):R({kind:"tool",key:l.toolCallId,tool:l})))}),O>=0&&(S[O]=/* @__PURE__ */I(e,{summary:Pe(T,c,r,o),busy:c,label:o.steps,children:T.map(e=>"tool"===e.kind?/* @__PURE__ */I(_e,{tool:e.tool,summary:j.get(e.tool.toolCallId),toolLabels:r,labels:o,showOutput:l},e.key):/* @__PURE__ */I(t,{status:"complete",label:/* @__PURE__ */B("details",{children:[
50
+ /* @__PURE__ */I("summary",{className:"cursor-pointer select-none",children:o.reasoning}),
51
+ /* @__PURE__ */I("div",{className:"mt-1 whitespace-pre-wrap text-gray-500",children:e.text})]})},e.key))},"chain")),0===S.length)return null;const _=/* @__PURE__ */B("div",{ref:k,className:"max-w-[92%] min-w-0 space-y-2 rounded-2xl bg-white px-3 py-2 text-gray-800 shadow-sm",children:["staff"===w&&/* @__PURE__ */I("div",{className:"text-xs font-medium text-blue-600",children:o.teamName}),a.metadata?.askedBy&&/* @__PURE__ */I("div",{className:"text-xs text-ink-faint",children:o.askedBy.replace("{name}",a.metadata.askedBy.name)}),S]}),M=c?null:/* @__PURE__ */I(Ye,{message:a,labels:o,showCopy:!0===b,actions:v,answer:k}),F=i&&!w,E=a.metadata?.run_id,D=Boolean(x&&E&&!c&&!w);return F||D||M?/* @__PURE__ */B("div",{className:"flex flex-col items-start gap-1",children:[_,
52
+ /* @__PURE__ */B("div",{className:"flex w-full max-w-[92%] flex-wrap items-start gap-x-2 gap-y-1",children:[
53
+ /* @__PURE__ */B("div",{className:"flex min-w-0 flex-1 items-start gap-1",children:[F&&/* @__PURE__ */I(Ue,{message:a,live:c,labels:o}),D&&x&&E&&/* @__PURE__ */I(Se,{initial:a.metadata?.rating,labels:o,onRate:e=>x(E,e)})]}),M]})]}):/* @__PURE__ */I("div",{className:"flex justify-start",children:_})}function Ge(e){const{messages:t,status:n,error:a,history:r,labels:o}=e,s=A(null),i=O(()=>function(e){const t=/* @__PURE__ */new Map;for(const n of ee(e).values())t.set(n.approval_id,n);return t}(t),[t]),c=a?ie(a,e.errorCode??null,o):null,d=t[t.length-1],p="ready"!==n||a||e.handedOver||"assistant"!==d?.role||!e.onAsk?[]:e.followups??[];return S(()=>{const e=s.current;e&&(e.scrollTop=e.scrollHeight)},[t,n]),/* @__PURE__ */B("div",{ref:s,role:"log","aria-label":e.title,"aria-live":"polite","aria-busy":"submitted"===n||"streaming"===n,className:"flex min-h-0 flex-1 flex-col gap-3 overflow-auto bg-gray-50 p-3",children:["loading"===r&&/* @__PURE__ */B("div",{role:"status",className:"flex items-center gap-2 text-xs text-gray-500",children:[
54
+ /* @__PURE__ */I(k,{className:"h-3 w-3"}),o.loadingHistory]}),"failed"===r&&/* @__PURE__ */I(l,{tone:"warning",children:o.historyFailed}),0===t.length&&"idle"===r&&/* @__PURE__ */I("p",{className:"m-auto text-center text-sm text-gray-500",children:o.emptyState}),t.map((a,r)=>/* @__PURE__ */I(qe,{live:r===t.length-1&&("submitted"===n||"streaming"===n),message:a,toolLabels:e.toolLabels,labels:o,showReasoning:e.showReasoning,showToolOutput:e.showToolOutput,showUsage:e.showUsage,tableActions:e.tableActions,onApprove:e.onApprove,onLinkClick:e.onLinkClick,onOpenFile:e.onOpenFile,renderDataPart:e.renderDataPart,plans:i,userActions:e.userMessageActions,onOpenAttachment:e.onOpenAttachment,showCopy:e.showCopy,answerActions:e.answerActions,onRate:e.onRate},a.id)),e.onAsk&&/* @__PURE__ */I(je,{questions:p,label:o.followups,onAsk:e.onAsk}),e.handedOver&&/* @__PURE__ */I("div",{role:"status",className:"text-center text-xs text-gray-500",children:o.teamJoined}),"submitted"===n&&/* @__PURE__ */B("div",{role:"status",className:"flex items-center gap-2 text-xs text-gray-500",children:[
55
+ /* @__PURE__ */I(k,{className:"h-3 w-3"}),o.thinking]}),c&&/* @__PURE__ */B("div",{role:"alert",className:"flex flex-col items-start gap-2",children:[
56
+ /* @__PURE__ */I(l,{tone:"danger",children:c.text}),c.retryable&&e.onRetry&&"error"===n&&/* @__PURE__ */I(x,{size:"sm",variant:"secondary",onClick:e.onRetry,children:o.retry})]})]})}var Xe={title:"Assistant",placeholder:"Ask a question…",inputLabel:"Message to the assistant",send:"Send",stop:"Stop",newChat:"New chat",open:"Open assistant",close:"Close assistant",thinking:"Thinking",loadingHistory:"Loading the conversation",historyFailed:"The earlier conversation could not be loaded.",emptyState:"Ask me anything to get started.",approvalNeeded:"Approval needed",approve:"Approve",deny:"Deny",approved:"Approved",declined:"Declined",toolFailed:"did not complete",toolDeclined:"was not approved",details:"Details",stepSources:"Where these figures came from",reasoning:"Reasoning",genericError:"Something went wrong. Please try again.",connectionDropped:"The connection dropped. Your question may still be answering; reopen the chat in a moment.",retry:"Retry",working:"Working",steps:"Steps",teamName:"Team",teamJoined:"A team member has joined",plan:"Plan",planSummary:"Plan: {done} of {total} done",planProposed:"waiting for your approval",planApproved:"approved, starting",planRunning:"in progress",planCompleted:"finished",planFailed:"stopped — not every step ran",planDenied:"not approved — nothing was changed",planExpired:"expired — nothing was changed",planApprovalHeading:"Approve this plan of {count} steps",approvePlan:"Approve plan",replyStats:"{tokens} tokens · {seconds} s · {rate} tok/s",replyTokens:"{tokens} tokens",streaming:"Streaming",streamingRate:"Streaming · ~{rate} tok/s",followups:"Suggested follow-up questions",attach:"Attach a file",attaching:"Uploading",removeAttachment:"Remove {name}",openAttachment:"Open {name}",copyAnswer:"Copy",copied:"Copied",readOnly:"You can read this chat but not continue it.",rateAnswer:"Rate this answer",rateUp:"Helpful",rateDown:"Not helpful",rateNote:"What was wrong? (optional)",rateNoteSend:"Send",rateNoteSkip:"Skip",rateThanks:"Thanks for telling us.",rateFailed:"Your rating could not be saved.",openFile:"Open {name}",assistantMention:"@Assistant",toPeople:"To {names} only. The assistant won’t reply.",toAssistant:"The assistant will reply. Everyone in the chat sees it.",askAssistant:"Ask the assistant",peoplePlaceholder:"Message {names}, or type {mention} to ask",askedBy:"Asked by {name}",sayFailed:"Your message didn’t send. Try again."},Ze=(e,t)=>`${e.replace(/\/+$/,"")}/${t}`;function Ke(e){return Ze(e,"assistant/chat/")}function Ve(e,t){return Ze(e,`assistant/chat/${encodeURIComponent(t)}/`)}function et(e){const t=e.metadata;return Boolean(t?.source||t?.author||t?.askedBy)}function tt(e){return e.parts.map(e=>e.approval?.id??"").filter(Boolean).sort().join(",")}function nt(e){const t=A(e);t.current=e;const n=A(e.conversationId?{id:e.conversationId}:null),[a,r]=j("idle"),[o,s]=j(!1),[l,i]=j(null),[c,d]=j([]),[p,u]=j([]),[m,h]=j(!1),[f,g]=j(n.current),y=T(e=>{n.current=e,g(e)},[]),b=T((e,n)=>(t.current.fetch??fetch)(e,n),[]),v=O(()=>new M({api:Ke(e.apiBase),fetch:b,prepareSendMessagesRequest:async({messages:e})=>{const{apiBase:a,getHeaders:r,credentials:o}=t.current;return{api:Ke(a),body:Q(e,n.current?.id??null),headers:await(r?.())??{},...o?{credentials:o}:{}}}}),[b]),x=D({transport:v,sendAutomaticallyWhen:F,onData:e=>{if(!Y.has(e.type))return void t.current.onDataPart?.(e);if("data-error"===e.type)return void i(e.data.code);if("data-followups"===e.type)return void d(function(e){const t=e?.questions;if(!Array.isArray(t))return[];const n=[];for(const e of t){if("string"!=typeof e)continue;const t=e.trim();!t||t.includes("\n")||n.includes(t)||n.push(t)}return n.slice(0,3)}(e.data));if("data-conversation"!==e.type)return;const{id:a,guest_token:r}=e.data,o=n.current,s=r??(o?.id===a?o.guestToken:void 0);o&&o.id===a&&o.guestToken===s||(y(s?{id:a,guestToken:s}:{id:a}),t.current.onConversation?.(n.current))}}),{setMessages:w,stop:k}=x,N=T(async(e,n)=>{const{apiBase:a,getHeaders:o,credentials:l,onConversation:i}=t.current;r("loading"),d([]);try{const t=await b(Ve(a,e),{method:"GET",headers:await(o?.())??{},...l?{credentials:l}:{},signal:n});if(n.aborted)return;if(404===t.status)return y(null),i?.(null),void r("idle");if(!t.ok)throw new Error(`history ${t.status}`);const c=await t.json();if(n.aborted)return;s(!0===c.handed_over),u(c.people??[]),w(e=>e.length>0?e:ae(c)),r("idle")}catch{n.aborted||r("failed")}},[b,w,y]),C=e.conversationId??null;S(()=>{if(C===(n.current?.id??null)&&x.messages.length>0)return;if(null===C)return n.current&&(y(null),k(),w([]),d([]),u([])),void r("idle");n.current?.id===C||y({id:C});const e=new AbortController;return N(C,e.signal),()=>e.abort()},[C,N,w,k,y]);const $=T(async e=>{const a=n.current?.id;if(a)try{const{apiBase:r,getHeaders:o,credentials:l}=t.current,i=await b(Ve(r,a),{method:"GET",headers:await(o?.())??{},...l?{credentials:l}:{},...e?{signal:e}:{}});if(!i.ok||e?.aborted||n.current?.id!==a)return;const c=await i.json();s(!0===c.handed_over),u(c.people??[]);const d=ae(c),p=d.filter(et),m=d.find(e=>e.id===`pending-approvals-${a}`);if(0===p.length&&!m)return;w(e=>{const t=new Set(e.map(e=>e.id)),n=p.filter(e=>!t.has(e.id));let a=n.length>0?[...e,...n]:e;const r=new Set(a.filter(e=>e.id!==m?.id).flatMap(e=>tt(e).split(",").filter(Boolean)));if(m&&!tt(m).split(",").every(e=>r.has(e))){const e=a.find(e=>e.id===m.id);e?tt(e)!==tt(m)&&(a=[...a.filter(e=>e.id!==m.id),m]):a=[...a,m]}return a})}catch{}},[b,w]),R=A($);R.current=$;const{status:_}=x,I="submitted"===_||"streaming"===_,B=A(!1),E=A(!1),z=!!e.subscribe;S(()=>{const e=B.current&&!I;if(B.current=I,!e)return;if(z&&!E.current)return;E.current=!1;const t=new AbortController;return R.current(t.signal),()=>t.abort()},[I,z]);const L=A(I);L.current=I;const P=f?.id,U=f?.guestToken;S(()=>{const e=n.current,a=t.current.subscribe;if(e&&a)return a(e,()=>{L.current?E.current=!0:R.current()})??void 0},[P,U]);const H=T((e,t=[])=>{const n=e.trim();n&&(i(null),d([]),h(!1),x.sendMessage(t.length>0?{text:n,files:t.map(J)}:{text:n}))},[x]),W=T(async e=>{const a=n.current?.id;if(a){h(!1),d([]);try{const{apiBase:n,getHeaders:r,credentials:o}=t.current,s=await b(function(e,t){return Ze(e,`assistant/chat/${encodeURIComponent(t)}/messages/`)}(n,a),{method:"POST",headers:{"Content-Type":"application/json",...await(r?.())??{}},body:JSON.stringify({text:e}),...o?{credentials:o}:{}});if(!s.ok)throw new Error(`say ${s.status}`);const l=await s.json(),[i]=ae({id:a,messages:[l],pending_approvals:[]});i&&w(e=>e.some(e=>e.id===i.id)?e:[...e,i])}catch{h(!0)}}},[b,w]),X=e.mention??"",Z=p.length>0,K=T((e,t=[])=>{const n=e.trim();n&&(!Z||0!==t.length||q(n,X)?H(n,t):W(n))},[H,W,Z,X]),V=T(e=>H(Z?G(e,X):e),[H,Z,X]),ee=T(()=>{ce(x.messages)&&(i(null),d([]),x.regenerate())},[x]),te=T((e,t)=>{i(null),d([]),x.addToolApprovalResponse({id:e,approved:t})},[x]),ne=T(()=>{k(),y(null),w([]),r("idle"),s(!1),i(null),d([]),u([]),h(!1),t.current.onConversation?.(null)},[w,k,y]);return{conversationId:f?.id??null,messages:x.messages,status:x.status,error:x.error,errorCode:l,canRetry:ce(x.messages),retry:ee,historyState:a,handedOver:o,followups:c,people:p,sayFailed:m,send:K,askAssistant:V,stop:k,approve:te,reset:ne}}function at(e){const t={...Xe,...e.labels},n=e.variant??"panel",a=nt({...e,mention:t.assistantMention}),r=X(a.people),o="submitted"===a.status||"streaming"===a.status,s=A(e.onBusyChange);s.current=e.onBusyChange,S(()=>{s.current?.(o)},[o]);const l="window"===n,i=e.showHeader??"window"!==n,c=e.title??t.title,d=te(a.messages),p=!0===e.readOnly,{onRate:m}=e,{conversationId:h}=a,f=A(!1),{send:g}=a;return S(()=>{f.current||p||e.conversationId||!e.initialQuestion?.trim()||(f.current=!0,g(e.initialQuestion))},[]),/* @__PURE__ */B("section",{"aria-label":c,className:`flex h-full min-h-0 flex-col bg-white text-gray-900 ${e.className??""}`.trim(),children:[i&&/* @__PURE__ */B("header",{className:"flex items-center gap-2 border-b border-gray-200 px-3 py-2",children:[
57
+ /* @__PURE__ */I("h2",{className:"min-w-0 flex-1 truncate text-sm font-semibold",children:c}),a.messages.length>0&&/* @__PURE__ */I(x,{size:"sm",variant:"ghost",onClick:a.reset,children:t.newChat}),e.onClose&&/* @__PURE__ */I(u,{size:"sm","aria-label":t.close,onClick:e.onClose,children:/* @__PURE__ */I(w,{name:"close"})})]}),
58
+ /* @__PURE__ */I(Ge,{messages:a.messages,status:a.status,error:a.error,errorCode:a.errorCode,history:a.historyState,handedOver:a.handedOver,labels:t,title:c,toolLabels:e.toolLabels,showReasoning:l&&!0===e.showReasoning,showToolOutput:l,showUsage:l&&!0===e.showUsage,tableActions:e.tableActions,onApprove:a.approve,onLinkClick:e.onLinkClick,onOpenFile:e.onOpenFile,renderDataPart:e.renderDataPart,userMessageActions:p?void 0:e.userMessageActions,showCopy:e.showCopy??l,answerActions:e.answerActions,onOpenAttachment:e.attachments?.onOpen,followups:a.followups,onAsk:p?void 0:a.askAssistant,onRetry:p?void 0:a.canRetry?a.retry:void 0,onRate:m&&h&&!p?(e,t)=>m({conversationId:h,runId:e,rating:t}):void 0}),d&&/* @__PURE__ */I(Ae,{plan:d,labels:t},d.id),!p&&e.composerTop,!p&&a.sayFailed&&/* @__PURE__ */I("p",{role:"alert",className:"border-t border-line px-3 py-2 text-xs text-danger-text",children:t.sayFailed}),p?/* @__PURE__ */I("p",{role:"note",className:"border-t border-gray-200 px-3 py-2 text-xs text-gray-500",children:t.readOnly}):/* @__PURE__ */I(de,{labels:t,placeholder:r?t.peoplePlaceholder.replace("{names}",r).replace("{mention}",t.assistantMention):e.placeholder??t.placeholder,people:r||void 0,busy:o,focusWhen:e.focusComposer,onSend:a.send,onStop:a.stop,onNewChat:!i&&!1!==e.showNewChat&&a.messages.length>0?a.reset:void 0,actions:e.composerActions,attachments:e.attachments})]})}function rt(e){const t={...Xe,...e.labels},[n,a]=j(e.defaultOpen??!1),r=$(),o=A(null),s=A(n),l=t=>{a(t),e.onOpenChange?.(t)};return S(()=>{s.current&&!n&&o.current?.focus(),s.current=n},[n]),/* @__PURE__ */B("div",{className:"rosh-assistant",style:{display:"contents"},children:[n&&/* @__PURE__ */I("div",{id:r,role:"dialog","aria-label":e.title??t.title,onKeyDown:e=>{"Escape"===e.key&&l(!1)},className:"fixed inset-x-2 bottom-20 z-[var(--z-window,1000)] h-[min(34rem,calc(100dvh-6rem))] overflow-hidden rounded-xl border border-gray-200 shadow-xl sm:inset-x-auto sm:right-4 sm:w-96",children:/* @__PURE__ */I(at,{...e,onClose:()=>l(!1),focusComposer:!0})}),
59
+ /* @__PURE__ */I("button",{ref:o,type:"button","aria-expanded":n,"aria-controls":n?r:void 0,"aria-label":n?t.close:t.open,onClick:()=>l(!n),className:"fixed bottom-4 right-4 z-[var(--z-window,1000)] flex h-12 w-12 items-center justify-center rounded-full shadow-lg bg-[var(--assistant-launcher-bg,var(--color-blue-600))] text-[var(--assistant-launcher-ink,var(--color-white))] hover:bg-[var(--assistant-launcher-bg-hover,var(--color-blue-700))] focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-[var(--assistant-launcher-bg,var(--color-blue-600))]",children:/* @__PURE__ */I(w,n?{name:"close",size:20}:{name:"chat-bubble-left-right",size:22})})]})}function ot(e){if("bubble"===e.variant)/* @__PURE__ */return I(rt,{...e});const t="window"!==e.variant;/* @__PURE__ */
60
+ return I(at,{...e,className:`${t?"border-l border-gray-200":""} ${e.className??""}`.trim()})}export{Te as ApprovalCard,ot as AssistantChat,qe as AssistantMessage,Xe as DEFAULT_ASSISTANT_CHAT_LABELS,Y as OWN_DATA_PARTS,Ce as PlanApprovalCard,Ae as PlanChecklist,_e as ToolStep,G as addressedToAssistant,J as attachmentPart,W as attachmentsOf,Q as buildRequestBody,Fe as estimateTokens,ie as failureView,P as filesOf,Ee as finishedStats,se as isDroppedConnection,De as liveStats,q as mentionsAssistant,ae as messagesFromHistory,X as peopleNames,te as pinnedPlan,ee as plansOf,Me as tokensPerSecond,L as toolSummariesOf};
package/dist/ai.css CHANGED
@@ -1,2 +1,2 @@
1
1
  /*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
2
- @layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-space-y-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid}}}@layer theme{:root,:host{--color-blue-600:oklch(54.6% .245 262.881);--color-blue-700:oklch(48.8% .243 264.376);--color-white:#fff}}.rosh-assistant .sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.rosh-assistant .fixed{position:fixed}.rosh-assistant .sticky{position:sticky}.rosh-assistant .inset-x-2{inset-inline:.5rem}.rosh-assistant .top-0{top:0}.rosh-assistant .right-4{right:1rem}.rosh-assistant .bottom-4{bottom:1rem}.rosh-assistant .bottom-20{bottom:5rem}.rosh-assistant .z-30{z-index:30}.rosh-assistant .z-\[var\(--z-window\,1000\)\]{z-index:var(--z-window,1000)}.rosh-assistant .container{width:100%}@media (min-width:40rem){.rosh-assistant .container{max-width:40rem}}@media (min-width:48rem){.rosh-assistant .container{max-width:48rem}}@media (min-width:64rem){.rosh-assistant .container{max-width:64rem}}@media (min-width:80rem){.rosh-assistant .container{max-width:80rem}}@media (min-width:96rem){.rosh-assistant .container{max-width:96rem}}.rosh-assistant .m-auto{margin:auto}.rosh-assistant .my-1{margin-block:.25rem}.rosh-assistant .mt-0\.5{margin-top:.125rem}.rosh-assistant .mt-1{margin-top:.25rem}.rosh-assistant .mt-2{margin-top:.5rem}.rosh-assistant .mt-3{margin-top:.75rem}.rosh-assistant .ml-2{margin-left:.5rem}.rosh-assistant .ml-auto{margin-left:auto}.rosh-assistant .block{display:block}.rosh-assistant .contents{display:contents}.rosh-assistant .flex{display:flex}.rosh-assistant .grid{display:grid}.rosh-assistant .hidden{display:none}.rosh-assistant .inline{display:inline}.rosh-assistant .inline-flex{display:inline-flex}.rosh-assistant .table{display:table}.rosh-assistant .size-3{width:.75rem;height:.75rem}.rosh-assistant .size-3\.5{width:.875rem;height:.875rem}.rosh-assistant .h-3{height:.75rem}.rosh-assistant .h-3\.5{height:.875rem}.rosh-assistant .h-4{height:1rem}.rosh-assistant .h-5{height:1.25rem}.rosh-assistant .h-6{height:1.5rem}.rosh-assistant .h-8{height:2rem}.rosh-assistant .h-10{height:2.5rem}.rosh-assistant .h-11{height:2.75rem}.rosh-assistant .h-12{height:3rem}.rosh-assistant .h-14{height:3.5rem}.rosh-assistant .h-16{height:4rem}.rosh-assistant .h-20{height:5rem}.rosh-assistant .h-\[min\(34rem\,calc\(100dvh-6rem\)\)\]{height:min(34rem,100dvh - 6rem)}.rosh-assistant .h-full{height:100%}.rosh-assistant .max-h-32{max-height:8rem}.rosh-assistant .min-h-0{min-height:0}.rosh-assistant .w-3{width:.75rem}.rosh-assistant .w-3\.5{width:.875rem}.rosh-assistant .w-4{width:1rem}.rosh-assistant .w-5{width:1.25rem}.rosh-assistant .w-6{width:1.5rem}.rosh-assistant .w-8{width:2rem}.rosh-assistant .w-10{width:2.5rem}.rosh-assistant .w-11{width:2.75rem}.rosh-assistant .w-12{width:3rem}.rosh-assistant .w-14{width:3.5rem}.rosh-assistant .w-16{width:4rem}.rosh-assistant .w-20{width:5rem}.rosh-assistant .w-full{width:100%}.rosh-assistant .max-w-\[85\%\]{max-width:85%}.rosh-assistant .max-w-\[92\%\]{max-width:92%}.rosh-assistant .max-w-full{max-width:100%}.rosh-assistant .max-w-sm{max-width:24rem}.rosh-assistant .min-w-0{min-width:0}.rosh-assistant .flex-1{flex:1}.rosh-assistant .shrink-0{flex-shrink:0}.rosh-assistant .grow{flex-grow:1}.rosh-assistant .basis-48{flex-basis:12rem}.rosh-assistant .border-collapse{border-collapse:collapse}.rosh-assistant .rotate-90{rotate:90deg}.rosh-assistant .rotate-180{rotate:180deg}.rosh-assistant .cursor-pointer{cursor:pointer}.rosh-assistant .resize{resize:both}.rosh-assistant .resize-none{resize:none}.rosh-assistant .list-decimal{list-style-type:decimal}.rosh-assistant .list-disc{list-style-type:disc}.rosh-assistant .grid-cols-\[max-content_1fr\]{grid-template-columns:max-content 1fr}.rosh-assistant .flex-col{flex-direction:column}.rosh-assistant .flex-wrap{flex-wrap:wrap}.rosh-assistant .items-center{align-items:center}.rosh-assistant .items-end{align-items:flex-end}.rosh-assistant .items-start{align-items:flex-start}.rosh-assistant .justify-center{justify-content:center}.rosh-assistant .justify-end{justify-content:flex-end}.rosh-assistant .justify-start{justify-content:flex-start}.rosh-assistant .gap-0\.5{gap:.125rem}.rosh-assistant .gap-1{gap:.25rem}.rosh-assistant .gap-2{gap:.5rem}.rosh-assistant .gap-3{gap:.75rem}:where(.rosh-assistant .space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(.25rem * var(--tw-space-y-reverse));margin-block-end:calc(.25rem * calc(1 - var(--tw-space-y-reverse)))}:where(.rosh-assistant .space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(.25rem * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(.25rem * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.rosh-assistant .space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(.25rem * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(.25rem * 3) * calc(1 - var(--tw-space-y-reverse)))}.rosh-assistant .gap-x-2{column-gap:.5rem}.rosh-assistant .gap-x-3{column-gap:.75rem}.rosh-assistant .gap-y-1{row-gap:.25rem}.rosh-assistant .gap-y-2{row-gap:.5rem}.rosh-assistant .self-center{align-self:center}.rosh-assistant .truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.rosh-assistant .overflow-auto{overflow:auto}.rosh-assistant .overflow-hidden{overflow:hidden}.rosh-assistant .overflow-x-auto{overflow-x:auto}.rosh-assistant .rounded{border-radius:.25rem}.rosh-assistant .rounded-\(--radius-control\){border-radius:var(--radius-control)}.rosh-assistant .rounded-2xl{border-radius:1rem}.rosh-assistant .rounded-full{border-radius:3.40282e38px}.rosh-assistant .rounded-lg{border-radius:.5rem}.rosh-assistant .rounded-md{border-radius:.375rem}.rosh-assistant .rounded-xl{border-radius:.75rem}.rosh-assistant .rounded-r-lg{border-top-right-radius:.5rem;border-bottom-right-radius:.5rem}.rosh-assistant .border{border-style:var(--tw-border-style);border-width:1px}.rosh-assistant .border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.rosh-assistant .border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.rosh-assistant .border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.rosh-assistant .border-l-4{border-left-style:var(--tw-border-style);border-left-width:4px}.rosh-assistant .border-dashed{--tw-border-style:dashed;border-style:dashed}.rosh-assistant .border-\[color\:var\(--line\)\]{border-color:var(--line)}.rosh-assistant .border-\[color\:var\(--status-neutral-solid\)\]{border-color:var(--status-neutral-solid)}.rosh-assistant .border-amber-200{border-color:oklch(92.4% .12 95.746)}.rosh-assistant .border-amber-300{border-color:oklch(87.9% .169 91.605)}.rosh-assistant .border-amber-700{border-color:oklch(55.5% .163 48.998)}.rosh-assistant .border-blue-200{border-color:oklch(88.2% .059 254.128)}.rosh-assistant .border-blue-300{border-color:oklch(80.9% .105 251.813)}.rosh-assistant .border-blue-700{border-color:oklch(48.8% .243 264.376)}.rosh-assistant .border-gray-200{border-color:oklch(92.8% .006 264.531)}.rosh-assistant .border-gray-300{border-color:oklch(87.2% .01 258.338)}.rosh-assistant .border-green-200{border-color:oklch(92.5% .084 155.995)}.rosh-assistant .border-green-700{border-color:oklch(52.7% .154 150.069)}.rosh-assistant .border-red-200{border-color:oklch(88.5% .062 18.334)}.rosh-assistant .border-red-300{border-color:oklch(80.8% .114 19.571)}.rosh-assistant .border-red-700{border-color:oklch(50.5% .213 27.518)}.rosh-assistant .bg-\[var\(--assistant-launcher-bg\,var\(--color-blue-600\)\)\]{background-color:var(--assistant-launcher-bg,var(--color-blue-600))}.rosh-assistant .bg-\[var\(--status-neutral-soft\)\]{background-color:var(--status-neutral-soft)}.rosh-assistant .bg-\[var\(--status-neutral-solid\)\]{background-color:var(--status-neutral-solid)}.rosh-assistant .bg-amber-50{background-color:oklch(98.7% .022 95.277)}.rosh-assistant .bg-amber-700{background-color:oklch(55.5% .163 48.998)}.rosh-assistant .bg-blue-50{background-color:oklch(97% .014 254.604)}.rosh-assistant .bg-blue-50\/60{background-color:oklab(97% -.00371685 -.0134976/.6)}.rosh-assistant .bg-blue-600{background-color:oklch(54.6% .245 262.881)}.rosh-assistant .bg-blue-700{background-color:oklch(48.8% .243 264.376)}.rosh-assistant .bg-gray-50{background-color:oklch(98.5% .002 247.839)}.rosh-assistant .bg-gray-100{background-color:oklch(96.7% .003 264.542)}.rosh-assistant .bg-gray-200{background-color:oklch(92.8% .006 264.531)}.rosh-assistant .bg-green-50{background-color:oklch(98.2% .018 155.826)}.rosh-assistant .bg-green-700{background-color:oklch(52.7% .154 150.069)}.rosh-assistant .bg-red-50{background-color:oklch(97.1% .013 17.38)}.rosh-assistant .bg-red-600{background-color:oklch(57.7% .245 27.325)}.rosh-assistant .bg-red-700{background-color:oklch(50.5% .213 27.518)}.rosh-assistant .bg-white{background-color:#fff}.rosh-assistant .p-0{padding:0}.rosh-assistant .p-0\.5{padding:.125rem}.rosh-assistant .p-3{padding:.75rem}.rosh-assistant .px-1{padding-inline:.25rem}.rosh-assistant .px-2{padding-inline:.5rem}.rosh-assistant .px-3{padding-inline:.75rem}.rosh-assistant .px-4{padding-inline:1rem}.rosh-assistant .px-5{padding-inline:1.25rem}.rosh-assistant .px-6{padding-inline:1.5rem}.rosh-assistant .px-8{padding-inline:2rem}.rosh-assistant .py-0\.5{padding-block:.125rem}.rosh-assistant .py-1{padding-block:.25rem}.rosh-assistant .py-2{padding-block:.5rem}.rosh-assistant .py-3{padding-block:.75rem}.rosh-assistant .py-12{padding-block:3rem}.rosh-assistant .pt-1{padding-top:.25rem}.rosh-assistant .pt-3{padding-top:.75rem}.rosh-assistant .pr-1{padding-right:.25rem}.rosh-assistant .pl-1{padding-left:.25rem}.rosh-assistant .pl-2{padding-left:.5rem}.rosh-assistant .pl-3{padding-left:.75rem}.rosh-assistant .pl-5{padding-left:1.25rem}.rosh-assistant .text-center{text-align:center}.rosh-assistant .text-left{text-align:left}.rosh-assistant .align-top{vertical-align:top}.rosh-assistant .font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.rosh-assistant .text-2xl{font-size:1.5rem;line-height:var(--tw-leading,calc(2 / 1.5))}.rosh-assistant .text-base{font-size:1rem;line-height:var(--tw-leading,calc(1.5 / 1))}.rosh-assistant .text-lg{font-size:1.125rem;line-height:var(--tw-leading,calc(1.75 / 1.125))}.rosh-assistant .text-sm{font-size:.875rem;line-height:var(--tw-leading,calc(1.25 / .875))}.rosh-assistant .text-xs{font-size:.75rem;line-height:var(--tw-leading,calc(1 / .75))}.rosh-assistant .text-\[0\.85em\]{font-size:.85em}.rosh-assistant .leading-6{--tw-leading:calc(.25rem * 6);line-height:1.5rem}.rosh-assistant .leading-relaxed{--tw-leading:1.625;line-height:1.625}.rosh-assistant .font-medium{--tw-font-weight:500;font-weight:500}.rosh-assistant .font-semibold{--tw-font-weight:600;font-weight:600}.rosh-assistant .tracking-wide{--tw-tracking:.025em;letter-spacing:.025em}.rosh-assistant .break-words{overflow-wrap:break-word}.rosh-assistant .whitespace-pre-wrap{white-space:pre-wrap}.rosh-assistant .text-\[color\:var\(--status-neutral-soft-ink\)\]{color:var(--status-neutral-soft-ink)}.rosh-assistant .text-\[color\:var\(--status-on-solid\)\]{color:var(--status-on-solid)}.rosh-assistant .text-\[var\(--assistant-launcher-ink\,var\(--color-white\)\)\]{color:var(--assistant-launcher-ink,var(--color-white))}.rosh-assistant .text-amber-600{color:oklch(66.6% .179 58.318)}.rosh-assistant .text-amber-700{color:oklch(55.5% .163 48.998)}.rosh-assistant .text-blue-600{color:oklch(54.6% .245 262.881)}.rosh-assistant .text-blue-700{color:oklch(48.8% .243 264.376)}.rosh-assistant .text-gray-400{color:oklch(70.7% .022 261.325)}.rosh-assistant .text-gray-500{color:oklch(55.1% .027 264.364)}.rosh-assistant .text-gray-600{color:oklch(44.6% .03 256.802)}.rosh-assistant .text-gray-700{color:oklch(37.3% .034 259.733)}.rosh-assistant .text-gray-800{color:oklch(27.8% .033 256.848)}.rosh-assistant .text-gray-900{color:oklch(21% .034 264.665)}.rosh-assistant .text-green-600{color:oklch(62.7% .194 149.214)}.rosh-assistant .text-inherit{color:inherit}.rosh-assistant .text-red-600{color:oklch(57.7% .245 27.325)}.rosh-assistant .text-red-700{color:oklch(50.5% .213 27.518)}.rosh-assistant .text-white{color:#fff}.rosh-assistant .uppercase{text-transform:uppercase}.rosh-assistant .italic{font-style:italic}.rosh-assistant .tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.rosh-assistant .no-underline{text-decoration-line:none}.rosh-assistant .underline{text-decoration-line:underline}.rosh-assistant .underline-offset-4{text-underline-offset:4px}.rosh-assistant .opacity-80{opacity:.8}.rosh-assistant .shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a), 0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a), 0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .ring{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .outline{outline-style:var(--tw-outline-style);outline-width:1px}.rosh-assistant .transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,cubic-bezier(.4, 0, .2, 1));transition-duration:var(--tw-duration,.15s)}.rosh-assistant .select-none{-webkit-user-select:none;user-select:none}.rosh-assistant .marker\:text-gray-400 ::marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .marker\:text-gray-400::marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .marker\:text-gray-400 ::-webkit-details-marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .marker\:text-gray-400::-webkit-details-marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .even\:bg-gray-50\/50:nth-child(2n){background-color:oklab(98.5% -.00075442 -.00185226/.5)}@media (hover:hover){.rosh-assistant .hover\:border-blue-300:hover{border-color:oklch(80.9% .105 251.813)}.rosh-assistant .hover\:bg-\[var\(--assistant-launcher-bg-hover\,var\(--color-blue-700\)\)\]:hover{background-color:var(--assistant-launcher-bg-hover,var(--color-blue-700))}.rosh-assistant .hover\:bg-blue-50:hover{background-color:oklch(97% .014 254.604)}.rosh-assistant .hover\:bg-gray-50:hover{background-color:oklch(98.5% .002 247.839)}.rosh-assistant .hover\:bg-gray-200:hover{background-color:oklch(92.8% .006 264.531)}.rosh-assistant .hover\:text-gray-600:hover{color:oklch(44.6% .03 256.802)}.rosh-assistant .hover\:text-gray-700:hover{color:oklch(37.3% .034 259.733)}.rosh-assistant .hover\:underline:hover{text-decoration-line:underline}.rosh-assistant .hover\:opacity-100:hover{opacity:1}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-amber-800:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(47.3% .137 46.201)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-blue-100:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(93.2% .032 255.585)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-gray-100:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(96.7% .003 264.542)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-red-50:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(97.1% .013 17.38)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-red-700:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(50.5% .213 27.518)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:underline:not(:disabled):not([aria-disabled=true]):hover{text-decoration-line:underline}}.rosh-assistant .focus\:outline-none:focus{--tw-outline-style:none;outline-style:none}.rosh-assistant .focus-visible\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring-invalid\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring-invalid)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring-invalid-strong\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring-invalid-strong)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring-strong\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring-strong)}.rosh-assistant .focus-visible\:ring-blue-500:focus-visible{--tw-ring-color:oklch(62.3% .214 259.815)}.rosh-assistant .focus-visible\:outline:focus-visible{outline-style:var(--tw-outline-style);outline-width:1px}.rosh-assistant .focus-visible\:outline-2:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px}.rosh-assistant .focus-visible\:outline-offset-2:focus-visible{outline-offset:2px}.rosh-assistant .focus-visible\:outline-\[var\(--assistant-launcher-bg\,var\(--color-blue-600\)\)\]:focus-visible{outline-color:var(--assistant-launcher-bg,var(--color-blue-600))}.rosh-assistant .focus-visible\:outline-blue-600:focus-visible{outline-color:oklch(54.6% .245 262.881)}.rosh-assistant .disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.rosh-assistant .disabled\:opacity-60:disabled{opacity:.6}.rosh-assistant .aria-disabled\:cursor-not-allowed[aria-disabled=true]{cursor:not-allowed}.rosh-assistant .aria-disabled\:opacity-60[aria-disabled=true]{opacity:.6}@media (prefers-reduced-motion:no-preference){.rosh-assistant .motion-safe\:transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,cubic-bezier(.4, 0, .2, 1));transition-duration:var(--tw-duration,.15s)}}@media (prefers-reduced-motion:reduce){.rosh-assistant .motion-reduce\:animate-none{animation:none}}@media (min-width:40rem){.rosh-assistant .sm\:inset-x-auto{inset-inline:auto}.rosh-assistant .sm\:right-4{right:1rem}.rosh-assistant .sm\:w-96{width:24rem}}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}
2
+ @layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-space-y-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid}}}@layer theme{:root,:host{--color-blue-600:oklch(54.6% .245 262.881);--color-blue-700:oklch(48.8% .243 264.376);--color-white:#fff}}.rosh-assistant .sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.rosh-assistant .fixed{position:fixed}.rosh-assistant .sticky{position:sticky}.rosh-assistant .inset-x-2{inset-inline:.5rem}.rosh-assistant .top-0{top:0}.rosh-assistant .right-4{right:1rem}.rosh-assistant .bottom-4{bottom:1rem}.rosh-assistant .bottom-20{bottom:5rem}.rosh-assistant .z-30{z-index:30}.rosh-assistant .z-\[var\(--z-window\,1000\)\]{z-index:var(--z-window,1000)}.rosh-assistant .container{width:100%}@media (min-width:40rem){.rosh-assistant .container{max-width:40rem}}@media (min-width:48rem){.rosh-assistant .container{max-width:48rem}}@media (min-width:64rem){.rosh-assistant .container{max-width:64rem}}@media (min-width:80rem){.rosh-assistant .container{max-width:80rem}}@media (min-width:96rem){.rosh-assistant .container{max-width:96rem}}.rosh-assistant .m-auto{margin:auto}.rosh-assistant .my-1{margin-block:.25rem}.rosh-assistant .mt-0\.5{margin-top:.125rem}.rosh-assistant .mt-1{margin-top:.25rem}.rosh-assistant .mt-2{margin-top:.5rem}.rosh-assistant .mt-3{margin-top:.75rem}.rosh-assistant .ml-2{margin-left:.5rem}.rosh-assistant .ml-auto{margin-left:auto}.rosh-assistant .block{display:block}.rosh-assistant .contents{display:contents}.rosh-assistant .flex{display:flex}.rosh-assistant .grid{display:grid}.rosh-assistant .hidden{display:none}.rosh-assistant .inline{display:inline}.rosh-assistant .inline-flex{display:inline-flex}.rosh-assistant .table{display:table}.rosh-assistant .size-3{width:.75rem;height:.75rem}.rosh-assistant .size-3\.5{width:.875rem;height:.875rem}.rosh-assistant .h-3{height:.75rem}.rosh-assistant .h-3\.5{height:.875rem}.rosh-assistant .h-4{height:1rem}.rosh-assistant .h-5{height:1.25rem}.rosh-assistant .h-6{height:1.5rem}.rosh-assistant .h-8{height:2rem}.rosh-assistant .h-10{height:2.5rem}.rosh-assistant .h-11{height:2.75rem}.rosh-assistant .h-12{height:3rem}.rosh-assistant .h-14{height:3.5rem}.rosh-assistant .h-16{height:4rem}.rosh-assistant .h-20{height:5rem}.rosh-assistant .h-\[min\(34rem\,calc\(100dvh-6rem\)\)\]{height:min(34rem,100dvh - 6rem)}.rosh-assistant .h-full{height:100%}.rosh-assistant .max-h-32{max-height:8rem}.rosh-assistant .min-h-0{min-height:0}.rosh-assistant .w-3{width:.75rem}.rosh-assistant .w-3\.5{width:.875rem}.rosh-assistant .w-4{width:1rem}.rosh-assistant .w-5{width:1.25rem}.rosh-assistant .w-6{width:1.5rem}.rosh-assistant .w-8{width:2rem}.rosh-assistant .w-10{width:2.5rem}.rosh-assistant .w-11{width:2.75rem}.rosh-assistant .w-12{width:3rem}.rosh-assistant .w-14{width:3.5rem}.rosh-assistant .w-16{width:4rem}.rosh-assistant .w-20{width:5rem}.rosh-assistant .w-full{width:100%}.rosh-assistant .max-w-\[85\%\]{max-width:85%}.rosh-assistant .max-w-\[92\%\]{max-width:92%}.rosh-assistant .max-w-full{max-width:100%}.rosh-assistant .max-w-sm{max-width:24rem}.rosh-assistant .min-w-0{min-width:0}.rosh-assistant .flex-1{flex:1}.rosh-assistant .shrink-0{flex-shrink:0}.rosh-assistant .grow{flex-grow:1}.rosh-assistant .basis-48{flex-basis:12rem}.rosh-assistant .border-collapse{border-collapse:collapse}.rosh-assistant .rotate-90{rotate:90deg}.rosh-assistant .rotate-180{rotate:180deg}.rosh-assistant .cursor-pointer{cursor:pointer}.rosh-assistant .resize{resize:both}.rosh-assistant .resize-none{resize:none}.rosh-assistant .list-decimal{list-style-type:decimal}.rosh-assistant .list-disc{list-style-type:disc}.rosh-assistant .grid-cols-\[max-content_1fr\]{grid-template-columns:max-content 1fr}.rosh-assistant .flex-col{flex-direction:column}.rosh-assistant .flex-wrap{flex-wrap:wrap}.rosh-assistant .items-center{align-items:center}.rosh-assistant .items-end{align-items:flex-end}.rosh-assistant .items-start{align-items:flex-start}.rosh-assistant .justify-center{justify-content:center}.rosh-assistant .justify-end{justify-content:flex-end}.rosh-assistant .justify-start{justify-content:flex-start}.rosh-assistant .gap-0\.5{gap:.125rem}.rosh-assistant .gap-1{gap:.25rem}.rosh-assistant .gap-2{gap:.5rem}.rosh-assistant .gap-3{gap:.75rem}:where(.rosh-assistant .space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(.25rem * var(--tw-space-y-reverse));margin-block-end:calc(.25rem * calc(1 - var(--tw-space-y-reverse)))}:where(.rosh-assistant .space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(.25rem * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(.25rem * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.rosh-assistant .space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(.25rem * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(.25rem * 3) * calc(1 - var(--tw-space-y-reverse)))}.rosh-assistant .gap-x-2{column-gap:.5rem}.rosh-assistant .gap-x-3{column-gap:.75rem}.rosh-assistant .gap-y-1{row-gap:.25rem}.rosh-assistant .gap-y-2{row-gap:.5rem}.rosh-assistant .self-center{align-self:center}.rosh-assistant .truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.rosh-assistant .overflow-auto{overflow:auto}.rosh-assistant .overflow-hidden{overflow:hidden}.rosh-assistant .overflow-x-auto{overflow-x:auto}.rosh-assistant .rounded{border-radius:.25rem}.rosh-assistant .rounded-\(--radius-control\){border-radius:var(--radius-control)}.rosh-assistant .rounded-2xl{border-radius:1rem}.rosh-assistant .rounded-full{border-radius:3.40282e38px}.rosh-assistant .rounded-lg{border-radius:.5rem}.rosh-assistant .rounded-md{border-radius:.375rem}.rosh-assistant .rounded-xl{border-radius:.75rem}.rosh-assistant .rounded-r-lg{border-top-right-radius:.5rem;border-bottom-right-radius:.5rem}.rosh-assistant .border{border-style:var(--tw-border-style);border-width:1px}.rosh-assistant .border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.rosh-assistant .border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.rosh-assistant .border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.rosh-assistant .border-l-4{border-left-style:var(--tw-border-style);border-left-width:4px}.rosh-assistant .border-dashed{--tw-border-style:dashed;border-style:dashed}.rosh-assistant .border-\[color\:var\(--line\)\]{border-color:var(--line)}.rosh-assistant .border-\[color\:var\(--status-neutral-solid\)\]{border-color:var(--status-neutral-solid)}.rosh-assistant .border-amber-200{border-color:oklch(92.4% .12 95.746)}.rosh-assistant .border-amber-300{border-color:oklch(87.9% .169 91.605)}.rosh-assistant .border-amber-700{border-color:oklch(55.5% .163 48.998)}.rosh-assistant .border-blue-200{border-color:oklch(88.2% .059 254.128)}.rosh-assistant .border-blue-300{border-color:oklch(80.9% .105 251.813)}.rosh-assistant .border-blue-700{border-color:oklch(48.8% .243 264.376)}.rosh-assistant .border-gray-200{border-color:oklch(92.8% .006 264.531)}.rosh-assistant .border-gray-300{border-color:oklch(87.2% .01 258.338)}.rosh-assistant .border-green-200{border-color:oklch(92.5% .084 155.995)}.rosh-assistant .border-green-700{border-color:oklch(52.7% .154 150.069)}.rosh-assistant .border-red-200{border-color:oklch(88.5% .062 18.334)}.rosh-assistant .border-red-300{border-color:oklch(80.8% .114 19.571)}.rosh-assistant .border-red-700{border-color:oklch(50.5% .213 27.518)}.rosh-assistant .bg-\[var\(--assistant-launcher-bg\,var\(--color-blue-600\)\)\]{background-color:var(--assistant-launcher-bg,var(--color-blue-600))}.rosh-assistant .bg-\[var\(--status-neutral-soft\)\]{background-color:var(--status-neutral-soft)}.rosh-assistant .bg-\[var\(--status-neutral-solid\)\]{background-color:var(--status-neutral-solid)}.rosh-assistant .bg-amber-50{background-color:oklch(98.7% .022 95.277)}.rosh-assistant .bg-amber-700{background-color:oklch(55.5% .163 48.998)}.rosh-assistant .bg-blue-50{background-color:oklch(97% .014 254.604)}.rosh-assistant .bg-blue-50\/60{background-color:oklab(97% -.00371685 -.0134976/.6)}.rosh-assistant .bg-blue-600{background-color:oklch(54.6% .245 262.881)}.rosh-assistant .bg-blue-700{background-color:oklch(48.8% .243 264.376)}.rosh-assistant .bg-gray-50{background-color:oklch(98.5% .002 247.839)}.rosh-assistant .bg-gray-100{background-color:oklch(96.7% .003 264.542)}.rosh-assistant .bg-gray-200{background-color:oklch(92.8% .006 264.531)}.rosh-assistant .bg-green-50{background-color:oklch(98.2% .018 155.826)}.rosh-assistant .bg-green-700{background-color:oklch(52.7% .154 150.069)}.rosh-assistant .bg-red-50{background-color:oklch(97.1% .013 17.38)}.rosh-assistant .bg-red-600{background-color:oklch(57.7% .245 27.325)}.rosh-assistant .bg-red-700{background-color:oklch(50.5% .213 27.518)}.rosh-assistant .bg-white{background-color:#fff}.rosh-assistant .p-0{padding:0}.rosh-assistant .p-0\.5{padding:.125rem}.rosh-assistant .p-3{padding:.75rem}.rosh-assistant .px-1{padding-inline:.25rem}.rosh-assistant .px-2{padding-inline:.5rem}.rosh-assistant .px-3{padding-inline:.75rem}.rosh-assistant .px-4{padding-inline:1rem}.rosh-assistant .px-5{padding-inline:1.25rem}.rosh-assistant .px-6{padding-inline:1.5rem}.rosh-assistant .px-8{padding-inline:2rem}.rosh-assistant .py-0\.5{padding-block:.125rem}.rosh-assistant .py-1{padding-block:.25rem}.rosh-assistant .py-2{padding-block:.5rem}.rosh-assistant .py-3{padding-block:.75rem}.rosh-assistant .py-12{padding-block:3rem}.rosh-assistant .pt-1{padding-top:.25rem}.rosh-assistant .pt-2{padding-top:.5rem}.rosh-assistant .pt-3{padding-top:.75rem}.rosh-assistant .pr-1{padding-right:.25rem}.rosh-assistant .pl-1{padding-left:.25rem}.rosh-assistant .pl-2{padding-left:.5rem}.rosh-assistant .pl-3{padding-left:.75rem}.rosh-assistant .pl-5{padding-left:1.25rem}.rosh-assistant .text-center{text-align:center}.rosh-assistant .text-left{text-align:left}.rosh-assistant .align-top{vertical-align:top}.rosh-assistant .font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.rosh-assistant .text-2xl{font-size:1.5rem;line-height:var(--tw-leading,calc(2 / 1.5))}.rosh-assistant .text-base{font-size:1rem;line-height:var(--tw-leading,calc(1.5 / 1))}.rosh-assistant .text-lg{font-size:1.125rem;line-height:var(--tw-leading,calc(1.75 / 1.125))}.rosh-assistant .text-sm{font-size:.875rem;line-height:var(--tw-leading,calc(1.25 / .875))}.rosh-assistant .text-xs{font-size:.75rem;line-height:var(--tw-leading,calc(1 / .75))}.rosh-assistant .text-\[0\.85em\]{font-size:.85em}.rosh-assistant .leading-6{--tw-leading:calc(.25rem * 6);line-height:1.5rem}.rosh-assistant .leading-relaxed{--tw-leading:1.625;line-height:1.625}.rosh-assistant .font-medium{--tw-font-weight:500;font-weight:500}.rosh-assistant .font-semibold{--tw-font-weight:600;font-weight:600}.rosh-assistant .tracking-wide{--tw-tracking:.025em;letter-spacing:.025em}.rosh-assistant .break-words{overflow-wrap:break-word}.rosh-assistant .whitespace-pre-wrap{white-space:pre-wrap}.rosh-assistant .text-\[color\:var\(--status-neutral-soft-ink\)\]{color:var(--status-neutral-soft-ink)}.rosh-assistant .text-\[color\:var\(--status-on-solid\)\]{color:var(--status-on-solid)}.rosh-assistant .text-\[var\(--assistant-launcher-ink\,var\(--color-white\)\)\]{color:var(--assistant-launcher-ink,var(--color-white))}.rosh-assistant .text-amber-600{color:oklch(66.6% .179 58.318)}.rosh-assistant .text-amber-700{color:oklch(55.5% .163 48.998)}.rosh-assistant .text-blue-600{color:oklch(54.6% .245 262.881)}.rosh-assistant .text-blue-700{color:oklch(48.8% .243 264.376)}.rosh-assistant .text-gray-400{color:oklch(70.7% .022 261.325)}.rosh-assistant .text-gray-500{color:oklch(55.1% .027 264.364)}.rosh-assistant .text-gray-600{color:oklch(44.6% .03 256.802)}.rosh-assistant .text-gray-700{color:oklch(37.3% .034 259.733)}.rosh-assistant .text-gray-800{color:oklch(27.8% .033 256.848)}.rosh-assistant .text-gray-900{color:oklch(21% .034 264.665)}.rosh-assistant .text-green-600{color:oklch(62.7% .194 149.214)}.rosh-assistant .text-inherit{color:inherit}.rosh-assistant .text-red-600{color:oklch(57.7% .245 27.325)}.rosh-assistant .text-red-700{color:oklch(50.5% .213 27.518)}.rosh-assistant .text-white{color:#fff}.rosh-assistant .uppercase{text-transform:uppercase}.rosh-assistant .italic{font-style:italic}.rosh-assistant .tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.rosh-assistant .no-underline{text-decoration-line:none}.rosh-assistant .underline{text-decoration-line:underline}.rosh-assistant .underline-offset-4{text-underline-offset:4px}.rosh-assistant .opacity-80{opacity:.8}.rosh-assistant .shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a), 0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a), 0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .ring{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .outline{outline-style:var(--tw-outline-style);outline-width:1px}.rosh-assistant .transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,cubic-bezier(.4, 0, .2, 1));transition-duration:var(--tw-duration,.15s)}.rosh-assistant .select-none{-webkit-user-select:none;user-select:none}.rosh-assistant .marker\:text-gray-400 ::marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .marker\:text-gray-400::marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .marker\:text-gray-400 ::-webkit-details-marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .marker\:text-gray-400::-webkit-details-marker{color:oklch(70.7% .022 261.325)}.rosh-assistant .even\:bg-gray-50\/50:nth-child(2n){background-color:oklab(98.5% -.00075442 -.00185226/.5)}@media (hover:hover){.rosh-assistant .hover\:border-blue-300:hover{border-color:oklch(80.9% .105 251.813)}.rosh-assistant .hover\:bg-\[var\(--assistant-launcher-bg-hover\,var\(--color-blue-700\)\)\]:hover{background-color:var(--assistant-launcher-bg-hover,var(--color-blue-700))}.rosh-assistant .hover\:bg-blue-50:hover{background-color:oklch(97% .014 254.604)}.rosh-assistant .hover\:bg-gray-50:hover{background-color:oklch(98.5% .002 247.839)}.rosh-assistant .hover\:bg-gray-200:hover{background-color:oklch(92.8% .006 264.531)}.rosh-assistant .hover\:text-gray-600:hover{color:oklch(44.6% .03 256.802)}.rosh-assistant .hover\:text-gray-700:hover{color:oklch(37.3% .034 259.733)}.rosh-assistant .hover\:underline:hover{text-decoration-line:underline}.rosh-assistant .hover\:opacity-100:hover{opacity:1}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-amber-800:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(47.3% .137 46.201)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-blue-100:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(93.2% .032 255.585)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-gray-100:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(96.7% .003 264.542)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-red-50:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(97.1% .013 17.38)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:bg-red-700:not(:disabled):not([aria-disabled=true]):hover{background-color:oklch(50.5% .213 27.518)}.rosh-assistant .not-disabled\:not-aria-disabled\:hover\:underline:not(:disabled):not([aria-disabled=true]):hover{text-decoration-line:underline}}.rosh-assistant .focus\:outline-none:focus{--tw-outline-style:none;outline-style:none}.rosh-assistant .focus-visible\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring-invalid\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring-invalid)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring-invalid-strong\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring-invalid-strong)}.rosh-assistant .focus-visible\:ring-\[color\:var\(--rosh-focus-ring-strong\)\]:focus-visible{--tw-ring-color:var(--rosh-focus-ring-strong)}.rosh-assistant .focus-visible\:ring-blue-500:focus-visible{--tw-ring-color:oklch(62.3% .214 259.815)}.rosh-assistant .focus-visible\:outline:focus-visible{outline-style:var(--tw-outline-style);outline-width:1px}.rosh-assistant .focus-visible\:outline-2:focus-visible{outline-style:var(--tw-outline-style);outline-width:2px}.rosh-assistant .focus-visible\:outline-offset-2:focus-visible{outline-offset:2px}.rosh-assistant .focus-visible\:outline-\[var\(--assistant-launcher-bg\,var\(--color-blue-600\)\)\]:focus-visible{outline-color:var(--assistant-launcher-bg,var(--color-blue-600))}.rosh-assistant .focus-visible\:outline-blue-600:focus-visible{outline-color:oklch(54.6% .245 262.881)}.rosh-assistant .disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.rosh-assistant .disabled\:opacity-60:disabled{opacity:.6}.rosh-assistant .aria-disabled\:cursor-not-allowed[aria-disabled=true]{cursor:not-allowed}.rosh-assistant .aria-disabled\:opacity-60[aria-disabled=true]{opacity:.6}@media (prefers-reduced-motion:no-preference){.rosh-assistant .motion-safe\:transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,cubic-bezier(.4, 0, .2, 1));transition-duration:var(--tw-duration,.15s)}}@media (prefers-reduced-motion:reduce){.rosh-assistant .motion-reduce\:animate-none{animation:none}}@media (min-width:40rem){.rosh-assistant .sm\:inset-x-auto{inset-inline:auto}.rosh-assistant .sm\:right-4{right:1rem}.rosh-assistant .sm\:w-96{width:24rem}}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}