@xpert-ai/chatkit-ui 0.0.9 → 0.0.11

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 (283) hide show
  1. package/dist/app/assets/{abap-BOOdbI8N.js → abap-CWzFNSp-.js} +1 -1
  2. package/dist/app/assets/{abnf-hpd6RnDH.js → abnf-BxCFtB4s.js} +1 -1
  3. package/dist/app/assets/{actionscript-BRVe4Pjo.js → actionscript-BMVcZIWM.js} +1 -1
  4. package/dist/app/assets/{ada-CuhwlPJx.js → ada-dl2GoC8H.js} +1 -1
  5. package/dist/app/assets/{agda-CHnszNxI.js → agda-D4pBWumw.js} +1 -1
  6. package/dist/app/assets/{al-V_AuUpP1.js → al-DN0MgvqQ.js} +1 -1
  7. package/dist/app/assets/{antlr4-BBUVZW2_.js → antlr4-CGc7Ys0O.js} +1 -1
  8. package/dist/app/assets/{apacheconf-Kchdv_b9.js → apacheconf-CGJnbgp4.js} +1 -1
  9. package/dist/app/assets/{apex-BsgMLxsF.js → apex-ByEj4aCS.js} +1 -1
  10. package/dist/app/assets/{apl-B6Jhatja.js → apl-CZoiimft.js} +1 -1
  11. package/dist/app/assets/{applescript-OyM_2cGP.js → applescript-n8m_Jzeh.js} +1 -1
  12. package/dist/app/assets/{aql-Ccm-av3-.js → aql-BHYPVYEd.js} +1 -1
  13. package/dist/app/assets/{arduino-BM46BzsR.js → arduino-DOwjV1xr.js} +1 -1
  14. package/dist/app/assets/{arff-HWks5hsG.js → arff-DDAls7WH.js} +1 -1
  15. package/dist/app/assets/{asciidoc-C3gtU-NR.js → asciidoc-CDg0i7az.js} +1 -1
  16. package/dist/app/assets/{asm6502-qqZ83Rou.js → asm6502-gRZ7mYMo.js} +1 -1
  17. package/dist/app/assets/{asmatmel-BaIc523v.js → asmatmel-m61heT5k.js} +1 -1
  18. package/dist/app/assets/{aspnet-D3ZIS6MN.js → aspnet-C3LE21kz.js} +1 -1
  19. package/dist/app/assets/{autohotkey-B4VlVp0m.js → autohotkey-DzTDmePJ.js} +1 -1
  20. package/dist/app/assets/{autoit-DhZLXuQo.js → autoit-Cnhhv2qU.js} +1 -1
  21. package/dist/app/assets/{avisynth-DW9deQvZ.js → avisynth-BrJReYCb.js} +1 -1
  22. package/dist/app/assets/{avro-idl-CM7HJ7KK.js → avro-idl-CaBS_m5w.js} +1 -1
  23. package/dist/app/assets/{bash-PiRoH_t7.js → bash-Bg2wTUUd.js} +1 -1
  24. package/dist/app/assets/{basic-CHfsC11v.js → basic-DGW2DfId.js} +1 -1
  25. package/dist/app/assets/{batch-CWt7f6i_.js → batch-CFcNVGyG.js} +1 -1
  26. package/dist/app/assets/{bbcode-Dn-8nVro.js → bbcode-BqKfVTdS.js} +1 -1
  27. package/dist/app/assets/{bicep-3_L6CTcg.js → bicep-CSj7qJLn.js} +1 -1
  28. package/dist/app/assets/{birb-DgzUqARS.js → birb-CZ_UnLaE.js} +1 -1
  29. package/dist/app/assets/{bison-DIMcQtQ1.js → bison-AJPkLJ01.js} +1 -1
  30. package/dist/app/assets/{bnf-DIRtt7WF.js → bnf-C4wLUeiV.js} +1 -1
  31. package/dist/app/assets/{brainfuck-BVOoWr7i.js → brainfuck-CtynTwQW.js} +1 -1
  32. package/dist/app/assets/{brightscript-W89MRPEr.js → brightscript-6fcqU7un.js} +1 -1
  33. package/dist/app/assets/{bro-Dqa08XMt.js → bro-BHjD18jy.js} +1 -1
  34. package/dist/app/assets/{bsl-B4a0Z5Fl.js → bsl-u3z--w0F.js} +1 -1
  35. package/dist/app/assets/{c-BIfmB3Vo.js → c-BqSyeoF5.js} +1 -1
  36. package/dist/app/assets/{cfscript-j-Ij2fAD.js → cfscript-Ba3ohzJU.js} +1 -1
  37. package/dist/app/assets/{chaiscript-DvAfeorr.js → chaiscript-B1kf0tLX.js} +1 -1
  38. package/dist/app/assets/{cil-ClKB8nfZ.js → cil-Bbq_Pohc.js} +1 -1
  39. package/dist/app/assets/{clike-BAdh6tjY.js → clike-BQY1uX2J.js} +1 -1
  40. package/dist/app/assets/{clojure-Da76zIwr.js → clojure-CD5FzqN8.js} +1 -1
  41. package/dist/app/assets/{cmake-BnEJCZQu.js → cmake-E4O60FXO.js} +1 -1
  42. package/dist/app/assets/{cobol-suYo05eB.js → cobol-4mBujo3m.js} +1 -1
  43. package/dist/app/assets/{coffeescript-DG1GS6zS.js → coffeescript-CePI6Tdq.js} +1 -1
  44. package/dist/app/assets/{concurnas-DsoaPmUa.js → concurnas-uDjQZLaY.js} +1 -1
  45. package/dist/app/assets/{coq-CG_IMNYC.js → coq-CaOpj4UX.js} +1 -1
  46. package/dist/app/assets/{core-dkybuDI5.js → core-pu1AeMbV.js} +1 -1
  47. package/dist/app/assets/{cpp-B-3oGtO3.js → cpp-CcW-8rTc.js} +1 -1
  48. package/dist/app/assets/{crystal-BVAPYNDk.js → crystal-DRfBhOgf.js} +1 -1
  49. package/dist/app/assets/{csharp-CiRkIZzr.js → csharp-BEQdGJcF.js} +1 -1
  50. package/dist/app/assets/{cshtml-oPL8sLwS.js → cshtml-5ml03XNo.js} +1 -1
  51. package/dist/app/assets/{csp-Dw6hurTd.js → csp-Behk06iM.js} +1 -1
  52. package/dist/app/assets/{css-D1MReag7.js → css-DXGELfz6.js} +1 -1
  53. package/dist/app/assets/{css-extras-CgCLAXgz.js → css-extras-B_cNEgHi.js} +1 -1
  54. package/dist/app/assets/{csv-1_9UEuTk.js → csv-CVwcNBm7.js} +1 -1
  55. package/dist/app/assets/{cypher-CbFq-K8U.js → cypher-BcNVi6vJ.js} +1 -1
  56. package/dist/app/assets/{d-DW9F76gG.js → d-HttcRaBz.js} +1 -1
  57. package/dist/app/assets/{dart-CTBL5VfC.js → dart-BW2vioEe.js} +1 -1
  58. package/dist/app/assets/{dataweave-681PD294.js → dataweave-Bd5xMJuj.js} +1 -1
  59. package/dist/app/assets/{dax-D3qms7WZ.js → dax-DfpKP7XF.js} +1 -1
  60. package/dist/app/assets/{dhall-BMazBVci.js → dhall-BqQAmdDY.js} +1 -1
  61. package/dist/app/assets/{diff-Bs9SAwAT.js → diff-Q6gyzp1p.js} +1 -1
  62. package/dist/app/assets/{django-DCH4XadN.js → django-CBK6CHRd.js} +1 -1
  63. package/dist/app/assets/{dns-zone-file-CBrWvkr3.js → dns-zone-file-CNh7YnMq.js} +1 -1
  64. package/dist/app/assets/{docker-3hzIzCDF.js → docker-B_Q25cYf.js} +1 -1
  65. package/dist/app/assets/{dot-B8IqESyv.js → dot-CNzlgF5r.js} +1 -1
  66. package/dist/app/assets/{ebnf-tkIFOrs0.js → ebnf-CFKzKpl0.js} +1 -1
  67. package/dist/app/assets/{editorconfig-Bs8DmUyO.js → editorconfig-CiSrxVma.js} +1 -1
  68. package/dist/app/assets/{eiffel-DxWyTUS5.js → eiffel-BfApOLd3.js} +1 -1
  69. package/dist/app/assets/{ejs-CmtYGUmz.js → ejs-4Dd6gLZA.js} +1 -1
  70. package/dist/app/assets/{elixir-hTpP4Hug.js → elixir-DWUeUQTK.js} +1 -1
  71. package/dist/app/assets/{elm-KjVtmO4i.js → elm-BL5Cpktc.js} +1 -1
  72. package/dist/app/assets/{erb-BB5ArK6Q.js → erb-DUtgA_WM.js} +1 -1
  73. package/dist/app/assets/{erlang-DEGsEdcs.js → erlang-nZyH6Oo4.js} +1 -1
  74. package/dist/app/assets/{etlua-DL6kSwvE.js → etlua-BXUfGRLO.js} +1 -1
  75. package/dist/app/assets/{excel-formula-C4VsMU5R.js → excel-formula-DP8NQckB.js} +1 -1
  76. package/dist/app/assets/{factor-bX5Jr38g.js → factor-D9oMyJYq.js} +1 -1
  77. package/dist/app/assets/{false-BeadEBSU.js → false-C5KgjRg_.js} +1 -1
  78. package/dist/app/assets/{firestore-security-rules-DcXP0seN.js → firestore-security-rules-h4rD4BAP.js} +1 -1
  79. package/dist/app/assets/{flow-DabBGpic.js → flow-CtGPm__x.js} +1 -1
  80. package/dist/app/assets/{fortran-DWXL1k6O.js → fortran-JKmvOaKb.js} +1 -1
  81. package/dist/app/assets/{fsharp-C6AJyCl9.js → fsharp-CY-kWYXS.js} +1 -1
  82. package/dist/app/assets/{ftl-C63uaJbn.js → ftl-lDx2eN4b.js} +1 -1
  83. package/dist/app/assets/{gap-BneB0ypS.js → gap-CbzqI0Rg.js} +1 -1
  84. package/dist/app/assets/{gcode-B2QSsxHO.js → gcode-B0j0LQok.js} +1 -1
  85. package/dist/app/assets/{gdscript-Dx6tTjC7.js → gdscript-OeCrPajz.js} +1 -1
  86. package/dist/app/assets/{gedcom-d81Bo_9Q.js → gedcom-dvLxXwAu.js} +1 -1
  87. package/dist/app/assets/{gherkin-N9yoVI5N.js → gherkin-DKAe3RsJ.js} +1 -1
  88. package/dist/app/assets/{git-DMV8VpOW.js → git-DvC3-v9a.js} +1 -1
  89. package/dist/app/assets/{glsl-CP7wuzq7.js → glsl-Du_zalDB.js} +1 -1
  90. package/dist/app/assets/{gml-BwBOVdTF.js → gml-okrayOzA.js} +1 -1
  91. package/dist/app/assets/{gn-CT-mlMj3.js → gn-BRy21STB.js} +1 -1
  92. package/dist/app/assets/{go-1TgqKrwS.js → go-BoOL6e-2.js} +1 -1
  93. package/dist/app/assets/{go-module-DEemi7Lr.js → go-module-CreBO_WI.js} +1 -1
  94. package/dist/app/assets/{graphql-DFpRQClU.js → graphql-B8puKuqv.js} +1 -1
  95. package/dist/app/assets/{groovy-D_dQA08t.js → groovy-Rr-99oQa.js} +1 -1
  96. package/dist/app/assets/{haml-CYUUZ5_z.js → haml-B16TW3OA.js} +1 -1
  97. package/dist/app/assets/{handlebars-BvE6k-_0.js → handlebars-DJ35T0jG.js} +1 -1
  98. package/dist/app/assets/{haskell-E36X9467.js → haskell-CNmIr1qp.js} +1 -1
  99. package/dist/app/assets/{haxe-BUhKDzUo.js → haxe-BP0489Ny.js} +1 -1
  100. package/dist/app/assets/{hcl-XIe7gZuW.js → hcl-BZ0mKM4I.js} +1 -1
  101. package/dist/app/assets/{hlsl-TBOSSzO7.js → hlsl-BvuUfy9Y.js} +1 -1
  102. package/dist/app/assets/{hoon-CdaS7nTI.js → hoon-F9stahw9.js} +1 -1
  103. package/dist/app/assets/{hpkp-C2m98hac.js → hpkp-BTP6fPb6.js} +1 -1
  104. package/dist/app/assets/{hsts-CkdtUPhZ.js → hsts-B4iFfqi0.js} +1 -1
  105. package/dist/app/assets/{http-BnXH3XcS.js → http-BsKsFgBg.js} +1 -1
  106. package/dist/app/assets/{ichigojam-Bj_wlWy7.js → ichigojam-Br86wNcB.js} +1 -1
  107. package/dist/app/assets/{icon-CCK8c4HH.js → icon-DOq3L_9O.js} +1 -1
  108. package/dist/app/assets/{icu-message-format-DWORJMwJ.js → icu-message-format-D7BXTTd2.js} +1 -1
  109. package/dist/app/assets/{idris-CMWNy7hJ.js → idris-Cff7mPno.js} +1 -1
  110. package/dist/app/assets/{iecst-DCdek48s.js → iecst-kzhp9nKs.js} +1 -1
  111. package/dist/app/assets/{ignore-D3Tbfgls.js → ignore-DZYE9Szm.js} +1 -1
  112. package/dist/app/assets/{index-CNCi4lM0.js → index-BqfTSOoT.js} +92 -92
  113. package/dist/app/assets/index-BzKLI1qz.css +1 -0
  114. package/dist/app/assets/{inform7-DJgms9fm.js → inform7-Dz2gt0-c.js} +1 -1
  115. package/dist/app/assets/{ini-DiKxmvqB.js → ini-Btpvp4DT.js} +1 -1
  116. package/dist/app/assets/{io-vV8ovjdH.js → io-fpXGYgAV.js} +1 -1
  117. package/dist/app/assets/{j-BxcWYfUt.js → j-8UK359TD.js} +1 -1
  118. package/dist/app/assets/{java-BoWzj7G9.js → java-CcEYgaqi.js} +1 -1
  119. package/dist/app/assets/{javadoc-BUS6Mkpk.js → javadoc-BYWdVRGr.js} +1 -1
  120. package/dist/app/assets/{javadoclike-CdHalVvd.js → javadoclike-DZIZZJFp.js} +1 -1
  121. package/dist/app/assets/{javascript-CFpr-JXS.js → javascript-BFsnARZD.js} +1 -1
  122. package/dist/app/assets/{javastacktrace-DooqGSOQ.js → javastacktrace-B8IM8tv1.js} +1 -1
  123. package/dist/app/assets/{jexl-DPZC5Lhe.js → jexl-C6vnzKaQ.js} +1 -1
  124. package/dist/app/assets/{jolie-CoGGjJJ2.js → jolie-J-E5Gc-W.js} +1 -1
  125. package/dist/app/assets/{jq-CR8BpDks.js → jq-CeMWQPPn.js} +1 -1
  126. package/dist/app/assets/{js-extras-BD3aF7Vg.js → js-extras-DT1ht6Uf.js} +1 -1
  127. package/dist/app/assets/{js-templates-CFDk8BFJ.js → js-templates-DweuRIjv.js} +1 -1
  128. package/dist/app/assets/{jsdoc-C7x7sdxG.js → jsdoc-CdaRjYMn.js} +1 -1
  129. package/dist/app/assets/{json-BsAE4ISB.js → json-DJXtscC1.js} +1 -1
  130. package/dist/app/assets/{json5-Dib204y1.js → json5-BoYaK0oG.js} +1 -1
  131. package/dist/app/assets/{jsonp-GX9nRKJm.js → jsonp-Bqin8zpD.js} +1 -1
  132. package/dist/app/assets/{jsstacktrace-DkcboMW3.js → jsstacktrace-C_x2X0wP.js} +1 -1
  133. package/dist/app/assets/{jsx-85kpxv_e.js → jsx-R36Hja1Z.js} +1 -1
  134. package/dist/app/assets/{julia-QEAzaZkA.js → julia-DadwWMMU.js} +1 -1
  135. package/dist/app/assets/{keepalived-XKuJ2vAg.js → keepalived-Bn7I7eeZ.js} +1 -1
  136. package/dist/app/assets/{keyman-D9LyzR20.js → keyman-BsLy49b_.js} +1 -1
  137. package/dist/app/assets/{kotlin-C4qdVbJq.js → kotlin-DAec6q-r.js} +1 -1
  138. package/dist/app/assets/{kumir-CgtXBoJ-.js → kumir-Clgy4fig.js} +1 -1
  139. package/dist/app/assets/{kusto-D_9GkUoi.js → kusto-B8r6qF-j.js} +1 -1
  140. package/dist/app/assets/{latex-BRhdFDny.js → latex-BiuC2wkP.js} +1 -1
  141. package/dist/app/assets/{latte-DDHbka3c.js → latte-Cla5OXcC.js} +1 -1
  142. package/dist/app/assets/{less-BVxcXkW9.js → less-D_ikeydS.js} +1 -1
  143. package/dist/app/assets/{lilypond-_cTdtLbn.js → lilypond--YpFjBez.js} +1 -1
  144. package/dist/app/assets/{liquid-Bg2wI-rc.js → liquid-CPV4dMvO.js} +1 -1
  145. package/dist/app/assets/{lisp-BoUlSGMq.js → lisp-DOFH1l-q.js} +1 -1
  146. package/dist/app/assets/{livescript-BN2i_yEF.js → livescript-JB55yErK.js} +1 -1
  147. package/dist/app/assets/{llvm-O-XH8epz.js → llvm-jN3Ev1En.js} +1 -1
  148. package/dist/app/assets/{log-DZ0F1EPj.js → log-DQQCNEql.js} +1 -1
  149. package/dist/app/assets/{lolcode-XV7JzUmM.js → lolcode-ksN5f-yb.js} +1 -1
  150. package/dist/app/assets/{lua-DEcJvcqG.js → lua-DC9DJI9p.js} +1 -1
  151. package/dist/app/assets/{magma-hdi8hw36.js → magma-DrubqNTB.js} +1 -1
  152. package/dist/app/assets/{makefile-o6OP7S5t.js → makefile-B5k684cb.js} +1 -1
  153. package/dist/app/assets/{markdown-siLQPPGn.js → markdown-DFVUIKIi.js} +1 -1
  154. package/dist/app/assets/{markup-BbNBlM88.js → markup-CjoPL6K5.js} +1 -1
  155. package/dist/app/assets/{markup-templating-Shmbkqzj.js → markup-templating-CiwYkdhY.js} +1 -1
  156. package/dist/app/assets/{matlab-DVJ_smJf.js → matlab-ERqXPSns.js} +1 -1
  157. package/dist/app/assets/{maxscript-nGL-ry_i.js → maxscript-D5ySF-hZ.js} +1 -1
  158. package/dist/app/assets/{mel-Co_r0q3M.js → mel-DcinxC8_.js} +1 -1
  159. package/dist/app/assets/{mermaid-CsIgpPUe.js → mermaid-CC9wRo1N.js} +1 -1
  160. package/dist/app/assets/{mizar-zjqLGDQJ.js → mizar-FpXRzvKF.js} +1 -1
  161. package/dist/app/assets/{mongodb-DanHVmrI.js → mongodb-BKjEps6Z.js} +1 -1
  162. package/dist/app/assets/{monkey-D-peWLXU.js → monkey-DTH2komu.js} +1 -1
  163. package/dist/app/assets/{moonscript-CMhSz8kh.js → moonscript-CJ-TUmDO.js} +1 -1
  164. package/dist/app/assets/{n1ql-BTY5F8bq.js → n1ql-DuVTgQ4i.js} +1 -1
  165. package/dist/app/assets/{n4js--bjAQgOL.js → n4js-C1kvC1iR.js} +1 -1
  166. package/dist/app/assets/{nand2tetris-hdl-YlnDahsg.js → nand2tetris-hdl-BD55HVds.js} +1 -1
  167. package/dist/app/assets/{naniscript-bRKxnqLI.js → naniscript-hvAS8R5k.js} +1 -1
  168. package/dist/app/assets/{nasm-FPiTETTA.js → nasm-BN4tkUGd.js} +1 -1
  169. package/dist/app/assets/{neon-BCuOKo87.js → neon-Cwa4bFMz.js} +1 -1
  170. package/dist/app/assets/{nevod-Dt6fbTd6.js → nevod-7tUWkcxU.js} +1 -1
  171. package/dist/app/assets/{nginx-CxrzKIG2.js → nginx-BQNWmJeC.js} +1 -1
  172. package/dist/app/assets/{nim-BBU9M8OW.js → nim-VFG-pALN.js} +1 -1
  173. package/dist/app/assets/{nix-BW83HATP.js → nix-ryTFWbv-.js} +1 -1
  174. package/dist/app/assets/{nsis-MduL_Fpi.js → nsis-csuADrZa.js} +1 -1
  175. package/dist/app/assets/{objectivec-CQY6v1kY.js → objectivec-CSGhR-Vw.js} +1 -1
  176. package/dist/app/assets/{ocaml-qJRe7Ows.js → ocaml-D0LmaOuS.js} +1 -1
  177. package/dist/app/assets/{opencl-CCwhgYqS.js → opencl-DAUuuIMo.js} +1 -1
  178. package/dist/app/assets/{openqasm-OYkQJic1.js → openqasm-DG7a1Exg.js} +1 -1
  179. package/dist/app/assets/{oz-CZ7N5qG8.js → oz-Ca36DgAF.js} +1 -1
  180. package/dist/app/assets/{parigp-CaHSQc4i.js → parigp-DLpf5jtK.js} +1 -1
  181. package/dist/app/assets/{parser-C74fZLsc.js → parser-BK0LebkS.js} +1 -1
  182. package/dist/app/assets/{pascal-9GyyQIA7.js → pascal-BElfvk70.js} +1 -1
  183. package/dist/app/assets/{pascaligo-C4UEpgMV.js → pascaligo-iZXFGeX_.js} +1 -1
  184. package/dist/app/assets/{pcaxis-BJP0X_1k.js → pcaxis-CRNF94Ci.js} +1 -1
  185. package/dist/app/assets/{peoplecode-CFS8Z8oG.js → peoplecode-Dw92XHF9.js} +1 -1
  186. package/dist/app/assets/{perl-Bej005D2.js → perl-CdfnIJMq.js} +1 -1
  187. package/dist/app/assets/{php-CA_2CQ-0.js → php-Dln42vSU.js} +1 -1
  188. package/dist/app/assets/{php-extras-CL-FD-Xj.js → php-extras-0UIOyCNY.js} +1 -1
  189. package/dist/app/assets/{phpdoc-xKRPjShF.js → phpdoc-K_FSRCrz.js} +1 -1
  190. package/dist/app/assets/{plsql-BGhKllJx.js → plsql-CDziRovj.js} +1 -1
  191. package/dist/app/assets/{powerquery-DmGYYgVZ.js → powerquery-hRIv-7HY.js} +1 -1
  192. package/dist/app/assets/{powershell-BDkWofIi.js → powershell-Cvsi-Ajt.js} +1 -1
  193. package/dist/app/assets/{processing-q6219PSx.js → processing-BzBfl4pu.js} +1 -1
  194. package/dist/app/assets/{prolog-BPgFzC0c.js → prolog-Bu6-Dx5E.js} +1 -1
  195. package/dist/app/assets/{promql-CLV-AGNP.js → promql-DDaoibvE.js} +1 -1
  196. package/dist/app/assets/{properties-C7tpr3V_.js → properties-DMGmO8LS.js} +1 -1
  197. package/dist/app/assets/{protobuf-DM_1aWha.js → protobuf-DIALiUNt.js} +1 -1
  198. package/dist/app/assets/{psl-9aBtqmb-.js → psl-ONY-TRz1.js} +1 -1
  199. package/dist/app/assets/{pug-DNGzHExn.js → pug-ChphTcM1.js} +1 -1
  200. package/dist/app/assets/{puppet-C4ZYXzEw.js → puppet-BE8IkE_0.js} +1 -1
  201. package/dist/app/assets/{pure-Cf5jhQHm.js → pure-G57DkT8U.js} +1 -1
  202. package/dist/app/assets/{purebasic-CzZAsCyB.js → purebasic-CeNwW-mm.js} +1 -1
  203. package/dist/app/assets/{purescript-BbBwR-JE.js → purescript-Bcq77YFD.js} +1 -1
  204. package/dist/app/assets/{q-DoeIwhvd.js → q-FBi2WGZw.js} +1 -1
  205. package/dist/app/assets/{qml-DctvPfpD.js → qml-CtkX8OgF.js} +1 -1
  206. package/dist/app/assets/{qore-B_Et8fJg.js → qore-SnoYykD8.js} +1 -1
  207. package/dist/app/assets/{qsharp-DLro2Xo1.js → qsharp-_B9KOx9k.js} +1 -1
  208. package/dist/app/assets/{r-D3p8QNRp.js → r-DSG5NIOe.js} +1 -1
  209. package/dist/app/assets/{racket-DMGy7uH6.js → racket-BeUDpNfX.js} +1 -1
  210. package/dist/app/assets/{reason-y0tl9m8h.js → reason-BgOolNCf.js} +1 -1
  211. package/dist/app/assets/{regex-Dio92Yso.js → regex-Bk1oSl4f.js} +1 -1
  212. package/dist/app/assets/{rego-DSOdVVVu.js → rego-CIWDsMqH.js} +1 -1
  213. package/dist/app/assets/{renpy-BRV1F5eA.js → renpy-_kbcmpNF.js} +1 -1
  214. package/dist/app/assets/{rest-B2erpSNM.js → rest-DIpQJ-do.js} +1 -1
  215. package/dist/app/assets/{rip-B5y6BSQj.js → rip-BSoWq6Xg.js} +1 -1
  216. package/dist/app/assets/{roboconf-CKPmi68x.js → roboconf-CvqHeFcy.js} +1 -1
  217. package/dist/app/assets/{robotframework-ebV64Zlg.js → robotframework-BJhVx5AC.js} +1 -1
  218. package/dist/app/assets/{ruby-DuXzQVUQ.js → ruby-BvQRDxMJ.js} +1 -1
  219. package/dist/app/assets/{rust-CRvRr4aQ.js → rust-kh79P-sj.js} +1 -1
  220. package/dist/app/assets/{sas-C07DynOQ.js → sas-P8RLNFXd.js} +1 -1
  221. package/dist/app/assets/{sass-D8rLDJKB.js → sass-B46x_1bU.js} +1 -1
  222. package/dist/app/assets/{scala-B0wlQtVe.js → scala-ChFXl2Pu.js} +1 -1
  223. package/dist/app/assets/{scheme-BNc7s0_f.js → scheme-BLb7t4HS.js} +1 -1
  224. package/dist/app/assets/{scss-CijVCKC4.js → scss-B9yekGw_.js} +1 -1
  225. package/dist/app/assets/{shell-session-B71DBCoS.js → shell-session-DmLv8D3v.js} +1 -1
  226. package/dist/app/assets/{smali-CPLXAl-o.js → smali-Blke27la.js} +1 -1
  227. package/dist/app/assets/{smalltalk-mVv-82zW.js → smalltalk-tw6G9Dzq.js} +1 -1
  228. package/dist/app/assets/{smarty-BPLRDzBS.js → smarty-CkUQxAfl.js} +1 -1
  229. package/dist/app/assets/{sml-CIQXnOtw.js → sml-BwHXlh6a.js} +1 -1
  230. package/dist/app/assets/{solidity-DOJz_cyA.js → solidity-C75eGiBN.js} +1 -1
  231. package/dist/app/assets/{solution-file-CopsE5id.js → solution-file-CSQS8iUg.js} +1 -1
  232. package/dist/app/assets/{soy-BbdMzJwp.js → soy-BTvUPYjh.js} +1 -1
  233. package/dist/app/assets/{sparql-IlQwU97T.js → sparql-CNBLBifn.js} +1 -1
  234. package/dist/app/assets/{splunk-spl-i1QLh14y.js → splunk-spl-Nfz25S75.js} +1 -1
  235. package/dist/app/assets/{sqf-YyBfuega.js → sqf-D61wR7ps.js} +1 -1
  236. package/dist/app/assets/{sql-DEB2Tw40.js → sql-ziUJYpp6.js} +1 -1
  237. package/dist/app/assets/{squirrel-Ci9UORlv.js → squirrel-DPmSQoXL.js} +1 -1
  238. package/dist/app/assets/{stan-B-08pUX4.js → stan-VYGTpgHk.js} +1 -1
  239. package/dist/app/assets/{stylus-BNOwAOE9.js → stylus-CNUEtGJh.js} +1 -1
  240. package/dist/app/assets/{swift-C6X-rtkr.js → swift-oZWKuYsC.js} +1 -1
  241. package/dist/app/assets/{systemd-Bu2yyhr3.js → systemd-CAFNmTIP.js} +1 -1
  242. package/dist/app/assets/{t4-cs-emBOL3Cd.js → t4-cs-C-wJS3Mm.js} +1 -1
  243. package/dist/app/assets/{t4-templating-ROROGKDI.js → t4-templating-Dda8pWdO.js} +1 -1
  244. package/dist/app/assets/{t4-vb-D3IC63bP.js → t4-vb-CBaRFyZF.js} +1 -1
  245. package/dist/app/assets/{tap-BrCtP8W8.js → tap-Bq_3zqFc.js} +1 -1
  246. package/dist/app/assets/{tcl-BvlT0PV9.js → tcl-BiRGOESK.js} +1 -1
  247. package/dist/app/assets/{textile-BG-COqh6.js → textile-ChcIaDjR.js} +1 -1
  248. package/dist/app/assets/{toml-BZ5GFxZq.js → toml-DLsGEGKj.js} +1 -1
  249. package/dist/app/assets/{tremor-C_BIHJs-.js → tremor-Ckrp0S7o.js} +1 -1
  250. package/dist/app/assets/{tt2-CKRkDC1_.js → tt2-B_3AORYq.js} +1 -1
  251. package/dist/app/assets/{turtle-DdXYAcwE.js → turtle-CwHHk8_t.js} +1 -1
  252. package/dist/app/assets/{twig-BpQOQJc_.js → twig-DlTuzPmO.js} +1 -1
  253. package/dist/app/assets/{typescript-BMBESBWw.js → typescript-f2B3Jfpo.js} +1 -1
  254. package/dist/app/assets/{typoscript-CGs3DTqm.js → typoscript-DnIUY4GA.js} +1 -1
  255. package/dist/app/assets/{unrealscript-DEiRyr99.js → unrealscript-D-gdymGH.js} +1 -1
  256. package/dist/app/assets/{uorazor-zcF2_Enm.js → uorazor-C62OEYTZ.js} +1 -1
  257. package/dist/app/assets/{uri-DZPODbW-.js → uri-bzMacUn_.js} +1 -1
  258. package/dist/app/assets/{v-BhSnlzT4.js → v-D50xccVa.js} +1 -1
  259. package/dist/app/assets/{vala-CS2NfZMD.js → vala-V-KAAqYe.js} +1 -1
  260. package/dist/app/assets/{vbnet-Cxc1UK1i.js → vbnet-D04Q9ev9.js} +1 -1
  261. package/dist/app/assets/{velocity-DQ2fxqC3.js → velocity-Cgya3_aZ.js} +1 -1
  262. package/dist/app/assets/{verilog-DCIUD_6a.js → verilog-ChFGSA3K.js} +1 -1
  263. package/dist/app/assets/{vhdl-BM-v3rbq.js → vhdl-BSU5cUGk.js} +1 -1
  264. package/dist/app/assets/{vim-Ce7nvxAD.js → vim-KeffaP4E.js} +1 -1
  265. package/dist/app/assets/{visual-basic-D4CwhPu8.js → visual-basic-Cxu4K2zU.js} +1 -1
  266. package/dist/app/assets/{warpscript-CwLOX2cg.js → warpscript-CLjny6tr.js} +1 -1
  267. package/dist/app/assets/{wasm-Be7P2udT.js → wasm-CpefXmbi.js} +1 -1
  268. package/dist/app/assets/{web-idl-DPWuNXV9.js → web-idl-Bj5qae8A.js} +1 -1
  269. package/dist/app/assets/{wiki-Da4SZpN0.js → wiki-BI1zVW5V.js} +1 -1
  270. package/dist/app/assets/{wolfram-CtMmIWks.js → wolfram-BLawAZSW.js} +1 -1
  271. package/dist/app/assets/{wren-8t5n-bNL.js → wren-Z79FVuvr.js} +1 -1
  272. package/dist/app/assets/{xeora-BrPfCrCy.js → xeora-D5SMpUiE.js} +1 -1
  273. package/dist/app/assets/{xml-doc-DkQ3GS_U.js → xml-doc-Dyd5ZrR3.js} +1 -1
  274. package/dist/app/assets/{xojo-CmzdxZC5.js → xojo-DGsUoypx.js} +1 -1
  275. package/dist/app/assets/{xquery-BVmhAXvQ.js → xquery-BvMyVlg9.js} +1 -1
  276. package/dist/app/assets/{yaml-De2NpHB8.js → yaml-BR4wSo8s.js} +1 -1
  277. package/dist/app/assets/{yang-d4KK0Mr6.js → yang-VGMETllk.js} +1 -1
  278. package/dist/app/assets/{zig-Cl86OQQZ.js → zig-eOsQLEGa.js} +1 -1
  279. package/dist/app/index.html +2 -2
  280. package/dist/index.cjs +347 -100
  281. package/dist/index.js +347 -100
  282. package/package.json +2 -2
  283. package/dist/app/assets/index-BY2VQKWk.css +0 -1
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  // src/components/chat.tsx
2
- import * as React17 from "react";
2
+ import * as React18 from "react";
3
3
  import { FileText as FileText2, Loader2 as Loader22, Pencil as Pencil3, RefreshCw as RefreshCw2, X as X2 } from "lucide-react";
4
4
 
5
5
  // src/lib/utils.ts
@@ -338,7 +338,7 @@ var buttonVariants = cva(
338
338
  function Button({
339
339
  className,
340
340
  variant = "default",
341
- size = "default",
341
+ size: size2 = "default",
342
342
  asChild = false,
343
343
  ...props
344
344
  }) {
@@ -348,8 +348,8 @@ function Button({
348
348
  {
349
349
  "data-slot": "button",
350
350
  "data-variant": variant,
351
- "data-size": size,
352
- className: cn(buttonVariants({ variant, size, className })),
351
+ "data-size": size2,
352
+ className: cn(buttonVariants({ variant, size: size2, className })),
353
353
  ...props
354
354
  }
355
355
  );
@@ -414,6 +414,11 @@ var en_US_default = {
414
414
  loadMessages: "Failed to load thread messages",
415
415
  createThread: "Failed to create thread",
416
416
  deleteThread: "Failed to delete thread"
417
+ },
418
+ contextUsage: {
419
+ label: "Context window",
420
+ full: "{{usedPercent}}% used ({{remainingPercent}}% left)",
421
+ tokensUsed: "{{used}} / {{max}} tokens used"
417
422
  }
418
423
  },
419
424
  history: {
@@ -467,6 +472,11 @@ var zh_CN_default = {
467
472
  loadMessages: "\u52A0\u8F7D\u7EBF\u7A0B\u6D88\u606F\u5931\u8D25",
468
473
  createThread: "\u521B\u5EFA\u7EBF\u7A0B\u5931\u8D25",
469
474
  deleteThread: "\u5220\u9664\u7EBF\u7A0B\u5931\u8D25"
475
+ },
476
+ contextUsage: {
477
+ label: "\u4E0A\u4E0B\u6587\u7A97\u53E3",
478
+ full: "\u5DF2\u4F7F\u7528 {{usedPercent}}%\uFF08\u5269\u4F59 {{remainingPercent}}%\uFF09",
479
+ tokensUsed: "\u5DF2\u4F7F\u7528 {{used}} / {{max}} tokens"
470
480
  }
471
481
  },
472
482
  history: {
@@ -1683,7 +1693,7 @@ var defaultComponents = {
1683
1693
  ol: ({ className, ...props }) => /* @__PURE__ */ jsx17(
1684
1694
  "ol",
1685
1695
  {
1686
- className: cn("my-5 list-outside list-decimal pl-7 [&>li]:mt-2", className),
1696
+ className: cn("my-5 list-outside list-decimal pl-8 [&>li]:mt-2", className),
1687
1697
  ...props
1688
1698
  }
1689
1699
  ),
@@ -1745,7 +1755,7 @@ var defaultComponents = {
1745
1755
  "pre",
1746
1756
  {
1747
1757
  className: cn(
1748
- "max-w-4xl overflow-x-auto rounded-lg bg-black text-white",
1758
+ "max-w-4xl overflow-x-auto rounded-lg text-sm bg-black text-white dark:bg-zinc-800 ",
1749
1759
  className
1750
1760
  ),
1751
1761
  ...props
@@ -2146,6 +2156,8 @@ var toThreadItem = (threadRecord) => ({
2146
2156
  id: threadRecord.threadId ?? threadRecord.id,
2147
2157
  recordId: threadRecord.id,
2148
2158
  title: getThreadTitle(threadRecord),
2159
+ status: threadRecord.status || "idle",
2160
+ error: threadRecord.error,
2149
2161
  lastMessageAt: toDate(threadRecord.updatedAt)
2150
2162
  });
2151
2163
  var sortThreadRecords = (threadRecords) => {
@@ -2156,7 +2168,13 @@ var sortThreadRecords = (threadRecords) => {
2156
2168
  });
2157
2169
  };
2158
2170
  function useThreads(limit = DEFAULT_LIMIT) {
2159
- const { client, threadId, assistantId, isReady } = useStreamContext();
2171
+ const {
2172
+ client,
2173
+ threadId,
2174
+ assistantId,
2175
+ isReady,
2176
+ isLoading: isStreamLoading
2177
+ } = useStreamContext();
2160
2178
  const [threadRecords, setThreadRecords] = React16.useState([]);
2161
2179
  const [isLoading, setIsLoading] = React16.useState(false);
2162
2180
  const [error, setError] = React16.useState(null);
@@ -2218,16 +2236,39 @@ function useThreads(limit = DEFAULT_LIMIT) {
2218
2236
  void refreshThreads();
2219
2237
  }, [refreshThreads, isReady]);
2220
2238
  React16.useEffect(() => {
2221
- if (!isReady) return;
2222
- if (!threadId) return;
2223
- if (threadRecords.some((item) => item.threadId === threadId)) return;
2239
+ if (!threadId || !isStreamLoading) return;
2240
+ const now = (/* @__PURE__ */ new Date()).toISOString();
2241
+ setThreadRecords((prev) => {
2242
+ let changed = false;
2243
+ const next = prev.map((item) => {
2244
+ const isCurrentThread = item.threadId === threadId || item.id === threadId;
2245
+ if (!isCurrentThread) return item;
2246
+ if (item.status === "busy" && !item.error) return item;
2247
+ changed = true;
2248
+ return {
2249
+ ...item,
2250
+ status: "busy",
2251
+ error: void 0,
2252
+ updatedAt: now
2253
+ };
2254
+ });
2255
+ return changed ? sortThreadRecords(next) : prev;
2256
+ });
2257
+ }, [threadId, isStreamLoading]);
2258
+ React16.useEffect(() => {
2259
+ if (!isReady || !threadId || isStreamLoading) return;
2260
+ let cancelled = false;
2224
2261
  void client.conversations.search({ where: { threadId }, limit: 1 }).then((result) => {
2262
+ if (cancelled) return;
2225
2263
  const found = result.items?.[0];
2226
2264
  if (found) upsertThreadRecord(found);
2227
2265
  }).catch((err) => {
2228
- setError(err);
2266
+ if (!cancelled) setError(err);
2229
2267
  });
2230
- }, [client, threadId, threadRecords, upsertThreadRecord, isReady]);
2268
+ return () => {
2269
+ cancelled = true;
2270
+ };
2271
+ }, [client, threadId, upsertThreadRecord, isReady, isStreamLoading]);
2231
2272
  const threads = React16.useMemo(
2232
2273
  () => threadRecords.map((threadRecord) => toThreadItem(threadRecord)),
2233
2274
  [threadRecords]
@@ -2244,8 +2285,201 @@ function useThreads(limit = DEFAULT_LIMIT) {
2244
2285
  };
2245
2286
  }
2246
2287
 
2288
+ // src/components/thread/context-usage-indicator.tsx
2289
+ import * as React17 from "react";
2290
+
2291
+ // src/components/ui/progress-circle.tsx
2292
+ import { jsx as jsx22, jsxs as jsxs11 } from "react/jsx-runtime";
2293
+ function clamp(input, a, b) {
2294
+ return Math.max(Math.min(input, Math.max(a, b)), Math.min(a, b));
2295
+ }
2296
+ var size = 24;
2297
+ var strokeWidth = 4;
2298
+ var total = 100;
2299
+ var ProgressCircle = ({ value, className, ...restSvgProps }) => {
2300
+ const normalizedValue = clamp(value, 0, total);
2301
+ const radius = (size - strokeWidth) / 2;
2302
+ const circumference = 2 * Math.PI * radius;
2303
+ const progress = normalizedValue / total * circumference;
2304
+ const halfSize = size / 2;
2305
+ const commonParams = {
2306
+ cx: halfSize,
2307
+ cy: halfSize,
2308
+ r: radius,
2309
+ fill: "none",
2310
+ strokeWidth
2311
+ };
2312
+ return (
2313
+ // biome-ignore lint/a11y/useFocusableInteractive: false positive (progress + progressbar are not focusable interactives)
2314
+ // biome-ignore lint/nursery/useAriaPropsSupportedByRole: biome rule at odds with mdn docs (presumed nursary bug with rule)
2315
+ /* @__PURE__ */ jsxs11(
2316
+ "svg",
2317
+ {
2318
+ role: "progressbar",
2319
+ viewBox: `0 0 ${size} ${size}`,
2320
+ className: cn("size-6", className),
2321
+ "aria-valuenow": normalizedValue,
2322
+ "aria-valuemin": 0,
2323
+ "aria-valuemax": 100,
2324
+ ...restSvgProps,
2325
+ children: [
2326
+ /* @__PURE__ */ jsx22("circle", { ...commonParams, className: "stroke-current/25" }),
2327
+ /* @__PURE__ */ jsx22(
2328
+ "circle",
2329
+ {
2330
+ ...commonParams,
2331
+ stroke: "currentColor",
2332
+ strokeDasharray: circumference,
2333
+ strokeDashoffset: circumference - progress,
2334
+ strokeLinecap: "round",
2335
+ transform: `rotate(-90 ${halfSize} ${halfSize})`,
2336
+ className: "stroke-current"
2337
+ }
2338
+ )
2339
+ ]
2340
+ }
2341
+ )
2342
+ );
2343
+ };
2344
+
2345
+ // src/components/thread/context-usage-indicator.tsx
2346
+ import { jsx as jsx23, jsxs as jsxs12 } from "react/jsx-runtime";
2347
+ var kNumberFormatter = new Intl.NumberFormat("en-US", {
2348
+ minimumFractionDigits: 0,
2349
+ maximumFractionDigits: 1
2350
+ });
2351
+ function normalizeContextSize(value) {
2352
+ if (typeof value === "number" && Number.isFinite(value) && value >= 0) {
2353
+ return Math.floor(value);
2354
+ }
2355
+ if (typeof value === "string") {
2356
+ const parsed = Number.parseInt(value, 10);
2357
+ if (Number.isFinite(parsed) && parsed >= 0) {
2358
+ return parsed;
2359
+ }
2360
+ }
2361
+ return null;
2362
+ }
2363
+ function normalizeAgentKey(value) {
2364
+ if (typeof value !== "string") {
2365
+ return null;
2366
+ }
2367
+ const normalized = value.trim();
2368
+ return normalized ? normalized : null;
2369
+ }
2370
+ function resolveAssistantContextSize(assistant) {
2371
+ return normalizeContextSize(assistant.metadata?.context_size) ?? normalizeContextSize(assistant.config?.configurable?.context_size);
2372
+ }
2373
+ function resolveAssistantAgentKey(assistant) {
2374
+ return normalizeAgentKey(assistant.metadata?.agent_key) ?? normalizeAgentKey(assistant.config?.configurable?.agentKey);
2375
+ }
2376
+ function clampUsage(value, max) {
2377
+ if (typeof value !== "number" || !Number.isFinite(value) || value < 0) {
2378
+ return 0;
2379
+ }
2380
+ return Math.min(Math.floor(value), max);
2381
+ }
2382
+ function formatCountInK(value) {
2383
+ return `${kNumberFormatter.format(value / 1e3)}k`;
2384
+ }
2385
+ function ContextUsageIndicator({
2386
+ label,
2387
+ className
2388
+ }) {
2389
+ const { t } = useChatkitTranslation();
2390
+ const stream = useStreamContext();
2391
+ const [maxContextSize, setMaxContextSize] = React17.useState(null);
2392
+ const [usedContextSize, setUsedContextSize] = React17.useState(null);
2393
+ const [assistantAgentKey, setAssistantAgentKey] = React17.useState(null);
2394
+ React17.useEffect(() => {
2395
+ if (!stream.client || !stream.assistantId) {
2396
+ setMaxContextSize(null);
2397
+ setAssistantAgentKey(null);
2398
+ return;
2399
+ }
2400
+ let cancelled = false;
2401
+ stream.client.assistants.get(stream.assistantId).then((assistant) => {
2402
+ if (cancelled || !assistant) return;
2403
+ setMaxContextSize(resolveAssistantContextSize(assistant));
2404
+ setAssistantAgentKey(resolveAssistantAgentKey(assistant));
2405
+ }).catch((err) => {
2406
+ if (cancelled) return;
2407
+ console.warn("[Chat] Failed to load assistant context size:", err);
2408
+ setAssistantAgentKey(null);
2409
+ });
2410
+ return () => {
2411
+ cancelled = true;
2412
+ };
2413
+ }, [stream.client, stream.assistantId]);
2414
+ React17.useEffect(() => {
2415
+ if (!stream.client) {
2416
+ setUsedContextSize(null);
2417
+ return;
2418
+ }
2419
+ if (!stream.threadId) {
2420
+ setUsedContextSize(0);
2421
+ return;
2422
+ }
2423
+ if (stream.isLoading) return;
2424
+ let cancelled = false;
2425
+ stream.client.threads.getContextUsage(
2426
+ stream.threadId,
2427
+ assistantAgentKey ? { agentKey: assistantAgentKey } : void 0
2428
+ ).then((result) => normalizeContextSize(result?.usage?.context_tokens)).then((result) => {
2429
+ if (cancelled) return;
2430
+ setUsedContextSize(result ?? 0);
2431
+ }).catch((err) => {
2432
+ if (cancelled) return;
2433
+ console.warn("[Chat] Failed to load thread context usage:", err);
2434
+ });
2435
+ return () => {
2436
+ cancelled = true;
2437
+ };
2438
+ }, [assistantAgentKey, stream.apiKey, stream.apiUrl, stream.client, stream.threadId, stream.isLoading]);
2439
+ if (typeof maxContextSize !== "number" || !Number.isFinite(maxContextSize) || maxContextSize <= 0) {
2440
+ return null;
2441
+ }
2442
+ const max = Math.floor(maxContextSize);
2443
+ const used = clampUsage(usedContextSize, max);
2444
+ const percent = Math.max(0, Math.min(100, used / max * 100));
2445
+ const roundedPercent = Math.round(percent);
2446
+ const remainingPercent = Math.max(0, 100 - roundedPercent);
2447
+ const formattedUsed = formatCountInK(used);
2448
+ const formattedMax = formatCountInK(max);
2449
+ const usageLabel = label ?? t("chat.contextUsage.label");
2450
+ const usageFullLabel = t("chat.contextUsage.full", {
2451
+ usedPercent: roundedPercent,
2452
+ remainingPercent
2453
+ });
2454
+ const usageTokensLabel = t("chat.contextUsage.tokensUsed", {
2455
+ used: formattedUsed,
2456
+ max: formattedMax
2457
+ });
2458
+ const usageLabelWithSuffix = usageLabel.endsWith(":") ? usageLabel : `${usageLabel}:`;
2459
+ const progressClassName = percent >= 90 ? "text-destructive" : percent >= 75 ? "text-amber-500" : "text-primary dark:text-zinc-300";
2460
+ return /* @__PURE__ */ jsxs12(Tooltip, { children: [
2461
+ /* @__PURE__ */ jsx23(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx23(
2462
+ "button",
2463
+ {
2464
+ type: "button",
2465
+ className: cn(
2466
+ "inline-flex items-center justify-center rounded-full focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 ring-offset-background",
2467
+ className
2468
+ ),
2469
+ "aria-label": `${usageLabelWithSuffix} ${usageFullLabel}. ${usageTokensLabel}`,
2470
+ children: /* @__PURE__ */ jsx23(ProgressCircle, { value: percent, className: cn("size-3.5", progressClassName) })
2471
+ }
2472
+ ) }),
2473
+ /* @__PURE__ */ jsxs12(TooltipContent, { side: "top", sideOffset: 6, className: "space-y-0.5 px-3 py-2 text-center", children: [
2474
+ /* @__PURE__ */ jsx23("div", { className: "text-primary-foreground/70", children: usageLabelWithSuffix }),
2475
+ /* @__PURE__ */ jsx23("div", { className: "font-medium text-primary-foreground/80", children: usageFullLabel }),
2476
+ /* @__PURE__ */ jsx23("div", { className: "text-sm font-semibold", children: usageTokensLabel })
2477
+ ] })
2478
+ ] });
2479
+ }
2480
+
2247
2481
  // src/components/chat.tsx
2248
- import { Fragment as Fragment3, jsx as jsx22, jsxs as jsxs11 } from "react/jsx-runtime";
2482
+ import { Fragment as Fragment3, jsx as jsx24, jsxs as jsxs13 } from "react/jsx-runtime";
2249
2483
  var defaultApiUrl2 = import.meta.env.VITE_XPERTAI_API_URL;
2250
2484
  function formatMessageContent(content) {
2251
2485
  if (typeof content === "string") {
@@ -2284,16 +2518,16 @@ function Chat({
2284
2518
  const apiUrl = options?.api?.apiUrl || defaultApiUrl2;
2285
2519
  const { setStream } = useStreamManager();
2286
2520
  const stream = useStreamContext();
2287
- const [isHistoryLoading, setIsHistoryLoading] = React17.useState(false);
2288
- const [historyError, setHistoryError] = React17.useState(null);
2289
- const [assistantName, setAssistantName] = React17.useState(null);
2521
+ const [isHistoryLoading, setIsHistoryLoading] = React18.useState(false);
2522
+ const [historyError, setHistoryError] = React18.useState(null);
2523
+ const [assistantName, setAssistantName] = React18.useState(null);
2290
2524
  const LOADING_DOTS_MIN_DURATION = 800;
2291
- const [showLoadingDots, setShowLoadingDots] = React17.useState(false);
2292
- const loadingStartTimeRef = React17.useRef(null);
2293
- React17.useEffect(() => {
2525
+ const [showLoadingDots, setShowLoadingDots] = React18.useState(false);
2526
+ const loadingStartTimeRef = React18.useRef(null);
2527
+ React18.useEffect(() => {
2294
2528
  setStream(stream);
2295
2529
  }, [setStream, stream]);
2296
- React17.useEffect(() => {
2530
+ React18.useEffect(() => {
2297
2531
  if (stream.isLoading) {
2298
2532
  if (!loadingStartTimeRef.current) {
2299
2533
  loadingStartTimeRef.current = Date.now();
@@ -2316,23 +2550,23 @@ function Chat({
2316
2550
  }
2317
2551
  }
2318
2552
  }, [stream.isLoading]);
2319
- const [draft, setDraft] = React17.useState("");
2320
- const [selectedTool, setSelectedTool] = React17.useState(null);
2321
- const [attachments, setAttachments] = React17.useState([]);
2553
+ const [draft, setDraft] = React18.useState("");
2554
+ const [selectedTool, setSelectedTool] = React18.useState(null);
2555
+ const [attachments, setAttachments] = React18.useState([]);
2322
2556
  const {
2323
2557
  threads,
2324
2558
  deleteThread,
2325
2559
  refreshThreads,
2326
2560
  isLoading: isThreadsLoading
2327
2561
  } = useThreads();
2328
- const viewportRef = React17.useRef(null);
2329
- const fileInputRef = React17.useRef(null);
2562
+ const viewportRef = React18.useRef(null);
2563
+ const fileInputRef = React18.useRef(null);
2330
2564
  const resolvedTitle = title ?? t("chat.title");
2331
2565
  const resolvedPlaceholder = placeholder ?? t("chat.placeholder");
2332
2566
  const inputPlaceholder = selectedTool?.placeholderOverride ?? composer?.placeholder ?? resolvedPlaceholder;
2333
2567
  const messages = stream.messages ?? [];
2334
2568
  const trimmedDraft = draft.trim();
2335
- const scrollToBottom = React17.useCallback((smooth = false) => {
2569
+ const scrollToBottom = React18.useCallback((smooth = false) => {
2336
2570
  requestAnimationFrame(() => {
2337
2571
  const viewport = viewportRef.current;
2338
2572
  if (viewport) {
@@ -2343,10 +2577,10 @@ function Chat({
2343
2577
  }
2344
2578
  });
2345
2579
  }, []);
2346
- React17.useEffect(() => {
2580
+ React18.useEffect(() => {
2347
2581
  scrollToBottom();
2348
2582
  }, [messages.length, scrollToBottom]);
2349
- React17.useEffect(() => {
2583
+ React18.useEffect(() => {
2350
2584
  if (stream.isLoading) {
2351
2585
  scrollToBottom();
2352
2586
  }
@@ -2357,11 +2591,11 @@ function Chat({
2357
2591
  const showMissingConfig = !isClientSecretInitializing && missingConfig;
2358
2592
  const hasUploadingFiles = attachments.some((a) => a.status === "uploading");
2359
2593
  const isSendDisabled = !trimmedDraft || stream.isLoading || missingConfig || isHistoryLoading || hasUploadingFiles;
2360
- React17.useEffect(() => {
2594
+ React18.useEffect(() => {
2361
2595
  if (missingConfig) return;
2362
2596
  void refreshThreads();
2363
2597
  }, [missingConfig, refreshThreads]);
2364
- React17.useEffect(() => {
2598
+ React18.useEffect(() => {
2365
2599
  if (missingConfig || !stream.client || !stream.assistantId) return;
2366
2600
  stream.client.assistants.get(stream.assistantId).then((assistant) => {
2367
2601
  if (assistant) {
@@ -2414,7 +2648,7 @@ function Chat({
2414
2648
  const handleAttachmentClick = () => {
2415
2649
  fileInputRef.current?.click();
2416
2650
  };
2417
- const uploadFile = React17.useCallback(async (localId, file) => {
2651
+ const uploadFile = React18.useCallback(async (localId, file) => {
2418
2652
  try {
2419
2653
  const result = await stream.client.contexts.uploadFile(file);
2420
2654
  setAttachments(
@@ -2434,7 +2668,7 @@ function Chat({
2434
2668
  );
2435
2669
  }
2436
2670
  }, [stream.client]);
2437
- const handleRetryUpload = React17.useCallback((localId) => {
2671
+ const handleRetryUpload = React18.useCallback((localId) => {
2438
2672
  const attachment = attachments.find((a) => a.localId === localId);
2439
2673
  if (!attachment || attachment.status !== "error") return;
2440
2674
  setAttachments(
@@ -2509,7 +2743,7 @@ function Chat({
2509
2743
  );
2510
2744
  scrollToBottom(true);
2511
2745
  };
2512
- const loadConversationMessages = React17.useCallback(
2746
+ const loadConversationMessages = React18.useCallback(
2513
2747
  async (recordId) => {
2514
2748
  if (missingConfig) {
2515
2749
  setHistoryError(t("chat.missingConfigShort"));
@@ -2590,8 +2824,17 @@ function Chat({
2590
2824
  }
2591
2825
  };
2592
2826
  const acceptMimes = composer?.attachments?.accept ? Object.entries(composer.attachments.accept).map(([mime, exts]) => [mime, ...exts.map((e) => `.${e}`)].join(",")).join(",") : void 0;
2827
+ const currentThread = React18.useMemo(
2828
+ () => threads.find((item) => item.id === stream.threadId),
2829
+ [threads, stream.threadId]
2830
+ );
2593
2831
  const errorMessage = stream.error instanceof Error ? stream.error.message : void 0;
2594
- return /* @__PURE__ */ jsxs11(
2832
+ const threadErrorMessage = React18.useMemo(() => {
2833
+ if (currentThread?.status !== "error") return void 0;
2834
+ const message = currentThread.error?.trim();
2835
+ return message || t("thread.errorToast");
2836
+ }, [currentThread, t]);
2837
+ return /* @__PURE__ */ jsxs13(
2595
2838
  "div",
2596
2839
  {
2597
2840
  ref: viewportRef,
@@ -2600,16 +2843,16 @@ function Chat({
2600
2843
  className
2601
2844
  ),
2602
2845
  children: [
2603
- /* @__PURE__ */ jsxs11("div", { className: "flex items-center justify-between border-b px-4 py-2 sticky top-0 z-10 bg-background", children: [
2604
- /* @__PURE__ */ jsxs11("div", { className: "flex items-center gap-3", children: [
2605
- /* @__PURE__ */ jsx22("div", { className: "h-2 w-2 rounded-full bg-green-500" }),
2606
- /* @__PURE__ */ jsxs11("div", { children: [
2607
- /* @__PURE__ */ jsx22("h2", { className: "text-lg font-semibold", children: assistantName || resolvedTitle }),
2608
- /* @__PURE__ */ jsx22("p", { className: "text-xs text-muted-foreground", children: t("chat.statusOnline") })
2846
+ /* @__PURE__ */ jsxs13("div", { className: "flex items-center justify-between border-b px-4 py-2 sticky top-0 z-10 bg-background", children: [
2847
+ /* @__PURE__ */ jsxs13("div", { className: "flex items-center gap-3", children: [
2848
+ /* @__PURE__ */ jsx24("div", { className: "h-2 w-2 rounded-full bg-green-500" }),
2849
+ /* @__PURE__ */ jsxs13("div", { children: [
2850
+ /* @__PURE__ */ jsx24("h2", { className: "text-lg font-semibold", children: assistantName || resolvedTitle }),
2851
+ /* @__PURE__ */ jsx24("p", { className: "text-xs text-muted-foreground", children: t("chat.statusOnline") })
2609
2852
  ] })
2610
2853
  ] }),
2611
- history?.enabled !== false && /* @__PURE__ */ jsxs11("div", { className: "flex items-center gap-1", children: [
2612
- /* @__PURE__ */ jsx22(
2854
+ history?.enabled !== false && /* @__PURE__ */ jsxs13("div", { className: "flex items-center gap-1", children: [
2855
+ /* @__PURE__ */ jsx24(
2613
2856
  "button",
2614
2857
  {
2615
2858
  type: "button",
@@ -2622,10 +2865,10 @@ function Chat({
2622
2865
  "disabled:opacity-50 disabled:cursor-not-allowed"
2623
2866
  ),
2624
2867
  title: t("history.newThread"),
2625
- children: /* @__PURE__ */ jsx22(Pencil3, { size: 16 })
2868
+ children: /* @__PURE__ */ jsx24(Pencil3, { size: 16 })
2626
2869
  }
2627
2870
  ),
2628
- /* @__PURE__ */ jsx22(
2871
+ /* @__PURE__ */ jsx24(
2629
2872
  HistorySidebar,
2630
2873
  {
2631
2874
  threads,
@@ -2639,23 +2882,23 @@ function Chat({
2639
2882
  )
2640
2883
  ] })
2641
2884
  ] }),
2642
- /* @__PURE__ */ jsxs11("div", { className: "flex-1 p-4", children: [
2643
- errorMessage && /* @__PURE__ */ jsx22("div", { className: "mb-4 rounded-lg border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive", children: errorMessage }),
2644
- historyError && /* @__PURE__ */ jsx22("div", { className: "mb-4 rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-900", children: historyError }),
2645
- showMissingConfig && /* @__PURE__ */ jsx22("div", { className: "mb-4 rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-900", children: t("chat.missingConfigDetail") }),
2646
- isHistoryLoading && /* @__PURE__ */ jsx22("div", { className: "mb-4 rounded-lg border border-muted px-3 py-2 text-sm text-muted-foreground", children: t("chat.loadingThread") }),
2647
- messages.length === 0 ? /* @__PURE__ */ jsx22(
2885
+ /* @__PURE__ */ jsxs13("div", { className: "flex-1 p-4", children: [
2886
+ errorMessage && /* @__PURE__ */ jsx24("div", { className: "mb-4 rounded-lg border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive", children: errorMessage }),
2887
+ historyError && /* @__PURE__ */ jsx24("div", { className: "mb-4 rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-900", children: historyError }),
2888
+ showMissingConfig && /* @__PURE__ */ jsx24("div", { className: "mb-4 rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-900", children: t("chat.missingConfigDetail") }),
2889
+ isHistoryLoading && /* @__PURE__ */ jsx24("div", { className: "mb-4 rounded-lg border border-muted px-3 py-2 text-sm text-muted-foreground", children: t("chat.loadingThread") }),
2890
+ messages.length === 0 ? /* @__PURE__ */ jsx24(
2648
2891
  StartScreen,
2649
2892
  {
2650
2893
  startScreen,
2651
2894
  onPromptClick: handlePromptClick
2652
2895
  }
2653
- ) : /* @__PURE__ */ jsxs11("div", { className: "space-y-4", children: [
2896
+ ) : /* @__PURE__ */ jsxs13("div", { className: "space-y-4", children: [
2654
2897
  messages.map((message, index) => {
2655
2898
  const messageType = String(message.type);
2656
2899
  const isAssistantMessage = messageType === "assistant" || messageType === "ai";
2657
2900
  const messageContent = typeof message.content === "string" ? message.content : Array.isArray(message.content) ? message.content.map((part) => formatMessageContent(part)).join("") : formatMessageContent(message.content);
2658
- return /* @__PURE__ */ jsx22(
2901
+ return /* @__PURE__ */ jsx24(
2659
2902
  "div",
2660
2903
  {
2661
2904
  className: cn(
@@ -2663,8 +2906,8 @@ function Chat({
2663
2906
  message.type === "human" ? "justify-end" : "justify-start -ml-1"
2664
2907
  // AI messages: slightly closer to left
2665
2908
  ),
2666
- children: /* @__PURE__ */ jsxs11("div", { className: "flex flex-col px-2 overflow-visible", children: [
2667
- /* @__PURE__ */ jsx22(
2909
+ children: /* @__PURE__ */ jsxs13("div", { className: "flex flex-col px-3 overflow-hidden", children: [
2910
+ /* @__PURE__ */ jsx24(
2668
2911
  "div",
2669
2912
  {
2670
2913
  className: cn(
@@ -2672,7 +2915,7 @@ function Chat({
2672
2915
  message.type === "human" ? "bg-primary text-primary-foreground px-4 py-2.5" : message.type === "system" ? "bg-muted text-muted-foreground text-xs px-4 py-2.5" : "py-1 text-chat-foreground"
2673
2916
  // AI messages: use chat-specific foreground color
2674
2917
  ),
2675
- children: isAssistantMessage ? /* @__PURE__ */ jsx22(
2918
+ children: isAssistantMessage ? /* @__PURE__ */ jsx24(
2676
2919
  AssistantMessage,
2677
2920
  {
2678
2921
  message: {
@@ -2681,30 +2924,30 @@ function Chat({
2681
2924
  },
2682
2925
  isStreaming: stream.isLoading && index === messages.length - 1
2683
2926
  }
2684
- ) : /* @__PURE__ */ jsxs11(Fragment3, { children: [
2685
- message.type === "human" && message.attachments?.length > 0 && /* @__PURE__ */ jsx22("div", { className: "flex flex-wrap gap-1.5 mb-2", children: message.attachments.map((file, fileIndex) => /* @__PURE__ */ jsxs11(
2927
+ ) : /* @__PURE__ */ jsxs13(Fragment3, { children: [
2928
+ message.type === "human" && message.attachments?.length > 0 && /* @__PURE__ */ jsx24("div", { className: "flex flex-wrap gap-1.5 mb-2", children: message.attachments.map((file, fileIndex) => /* @__PURE__ */ jsxs13(
2686
2929
  "div",
2687
2930
  {
2688
2931
  className: "flex items-center gap-1.5 rounded-md bg-primary-foreground/20 px-2 py-1 text-xs",
2689
2932
  children: [
2690
- /* @__PURE__ */ jsx22(FileText2, { size: 12 }),
2691
- /* @__PURE__ */ jsx22("span", { className: "max-w-[100px] truncate", children: file.originalName })
2933
+ /* @__PURE__ */ jsx24(FileText2, { size: 12 }),
2934
+ /* @__PURE__ */ jsx24("span", { className: "max-w-[100px] truncate", children: file.originalName })
2692
2935
  ]
2693
2936
  },
2694
2937
  fileIndex
2695
2938
  )) }),
2696
- Array.isArray(message.content) ? message.content.map((part, partIndex) => /* @__PURE__ */ jsx22(
2939
+ Array.isArray(message.content) ? message.content.map((part, partIndex) => /* @__PURE__ */ jsx24(
2697
2940
  "p",
2698
2941
  {
2699
2942
  className: "wrap-break-word text-sm leading-relaxed",
2700
2943
  children: formatMessageContent(part)
2701
2944
  },
2702
2945
  `${part.type}-${partIndex}`
2703
- )) : /* @__PURE__ */ jsx22("span", { className: "wrap-break-word text-sm leading-relaxed", children: formatMessageContent(message.content) })
2946
+ )) : /* @__PURE__ */ jsx24("span", { className: "wrap-break-word text-sm leading-relaxed", children: formatMessageContent(message.content) })
2704
2947
  ] })
2705
2948
  }
2706
2949
  ),
2707
- /* @__PURE__ */ jsx22(
2950
+ /* @__PURE__ */ jsx24(
2708
2951
  MessageActions,
2709
2952
  {
2710
2953
  content: messageContent,
@@ -2725,16 +2968,17 @@ function Chat({
2725
2968
  const lastMsgContent = lastMessage?.content;
2726
2969
  const hasSubstantialContent = isLastMessageFromAI && (typeof lastMsgContent === "string" && lastMsgContent.length > 10 || Array.isArray(lastMsgContent) && lastMsgContent.length > 0);
2727
2970
  if (hasSubstantialContent) return null;
2728
- return /* @__PURE__ */ jsx22("div", { className: "flex justify-start gap-3 -ml-2", children: /* @__PURE__ */ jsx22("div", { className: "max-w-full rounded-2xl py-2.5", children: /* @__PURE__ */ jsxs11("div", { className: "flex gap-1.5", children: [
2729
- /* @__PURE__ */ jsx22("div", { className: "h-2 w-2 animate-bounce rounded-full bg-muted-foreground/60 [animation-delay:-0.3s]" }),
2730
- /* @__PURE__ */ jsx22("div", { className: "h-2 w-2 animate-bounce rounded-full bg-muted-foreground/60 [animation-delay:-0.15s]" }),
2731
- /* @__PURE__ */ jsx22("div", { className: "h-2 w-2 animate-bounce rounded-full bg-muted-foreground/60" })
2971
+ return /* @__PURE__ */ jsx24("div", { className: "flex justify-start gap-3 -ml-2", children: /* @__PURE__ */ jsx24("div", { className: "max-w-full rounded-2xl py-2.5", children: /* @__PURE__ */ jsxs13("div", { className: "flex gap-1.5", children: [
2972
+ /* @__PURE__ */ jsx24("div", { className: "h-2 w-2 animate-bounce rounded-full bg-muted-foreground/60 [animation-delay:-0.3s]" }),
2973
+ /* @__PURE__ */ jsx24("div", { className: "h-2 w-2 animate-bounce rounded-full bg-muted-foreground/60 [animation-delay:-0.15s]" }),
2974
+ /* @__PURE__ */ jsx24("div", { className: "h-2 w-2 animate-bounce rounded-full bg-muted-foreground/60" })
2732
2975
  ] }) }) });
2733
2976
  })()
2734
2977
  ] })
2735
2978
  ] }),
2736
- /* @__PURE__ */ jsxs11("div", { className: "p-2 sticky bottom-0 z-10 bg-background", children: [
2737
- /* @__PURE__ */ jsx22(
2979
+ /* @__PURE__ */ jsxs13("div", { className: "p-2 sticky bottom-0 z-10 bg-background", children: [
2980
+ threadErrorMessage && /* @__PURE__ */ jsx24("div", { className: "mb-3 rounded-lg border border-destructive/30 bg-destructive/10 px-3 py-2 text-sm text-destructive", children: threadErrorMessage }),
2981
+ /* @__PURE__ */ jsx24(
2738
2982
  "input",
2739
2983
  {
2740
2984
  ref: fileInputRef,
@@ -2745,7 +2989,7 @@ function Chat({
2745
2989
  className: "hidden"
2746
2990
  }
2747
2991
  ),
2748
- attachments.length > 0 && /* @__PURE__ */ jsx22("div", { className: "mb-3 flex flex-wrap gap-2", children: attachments.map((item) => /* @__PURE__ */ jsxs11(
2992
+ attachments.length > 0 && /* @__PURE__ */ jsx24("div", { className: "mb-3 flex flex-wrap gap-2", children: attachments.map((item) => /* @__PURE__ */ jsxs13(
2749
2993
  "div",
2750
2994
  {
2751
2995
  className: cn(
@@ -2753,24 +2997,24 @@ function Chat({
2753
2997
  item.status === "error" ? "bg-destructive/10 border border-destructive/30" : "bg-muted"
2754
2998
  ),
2755
2999
  children: [
2756
- item.status === "uploading" && /* @__PURE__ */ jsx22(Loader22, { size: 14, className: "animate-spin text-muted-foreground" }),
2757
- item.status === "success" && /* @__PURE__ */ jsx22(FileText2, { size: 14, className: "text-muted-foreground" }),
2758
- item.status === "error" && /* @__PURE__ */ jsx22(FileText2, { size: 14, className: "text-destructive" }),
2759
- /* @__PURE__ */ jsx22("span", { className: cn(
3000
+ item.status === "uploading" && /* @__PURE__ */ jsx24(Loader22, { size: 14, className: "animate-spin text-muted-foreground" }),
3001
+ item.status === "success" && /* @__PURE__ */ jsx24(FileText2, { size: 14, className: "text-muted-foreground" }),
3002
+ item.status === "error" && /* @__PURE__ */ jsx24(FileText2, { size: 14, className: "text-destructive" }),
3003
+ /* @__PURE__ */ jsx24("span", { className: cn(
2760
3004
  "max-w-30 truncate",
2761
3005
  item.status === "error" && "text-destructive"
2762
3006
  ), children: item.file.name }),
2763
- item.status === "error" && /* @__PURE__ */ jsx22(
3007
+ item.status === "error" && /* @__PURE__ */ jsx24(
2764
3008
  "button",
2765
3009
  {
2766
3010
  type: "button",
2767
3011
  onClick: () => handleRetryUpload(item.localId),
2768
3012
  className: "ml-1 rounded-full p-0.5 text-destructive hover:bg-destructive/20",
2769
3013
  title: t("chat.retryUpload"),
2770
- children: /* @__PURE__ */ jsx22(RefreshCw2, { size: 12 })
3014
+ children: /* @__PURE__ */ jsx24(RefreshCw2, { size: 12 })
2771
3015
  }
2772
3016
  ),
2773
- /* @__PURE__ */ jsx22(
3017
+ /* @__PURE__ */ jsx24(
2774
3018
  "button",
2775
3019
  {
2776
3020
  type: "button",
@@ -2779,26 +3023,26 @@ function Chat({
2779
3023
  "ml-1 rounded-full p-0.5",
2780
3024
  item.status === "error" ? "text-destructive hover:bg-destructive/20" : "hover:bg-muted-foreground/20"
2781
3025
  ),
2782
- children: /* @__PURE__ */ jsx22(X2, { size: 12 })
3026
+ children: /* @__PURE__ */ jsx24(X2, { size: 12 })
2783
3027
  }
2784
3028
  )
2785
3029
  ]
2786
3030
  },
2787
3031
  item.localId
2788
3032
  )) }),
2789
- selectedTool && /* @__PURE__ */ jsxs11("div", { className: "mb-2 flex items-center gap-2", children: [
2790
- /* @__PURE__ */ jsx22("span", { className: "rounded-full bg-primary/10 px-2 py-0.5 text-xs font-medium text-primary", children: selectedTool.shortLabel ?? selectedTool.label }),
2791
- /* @__PURE__ */ jsx22(
3033
+ selectedTool && /* @__PURE__ */ jsxs13("div", { className: "mb-2 flex items-center gap-2", children: [
3034
+ /* @__PURE__ */ jsx24("span", { className: "rounded-full bg-primary/10 px-2 py-0.5 text-xs font-medium text-primary", children: selectedTool.shortLabel ?? selectedTool.label }),
3035
+ /* @__PURE__ */ jsx24(
2792
3036
  "button",
2793
3037
  {
2794
3038
  type: "button",
2795
3039
  onClick: () => setSelectedTool(null),
2796
3040
  className: "rounded-full p-0.5 text-muted-foreground hover:bg-muted",
2797
- children: /* @__PURE__ */ jsx22(X2, { size: 12 })
3041
+ children: /* @__PURE__ */ jsx24(X2, { size: 12 })
2798
3042
  }
2799
3043
  )
2800
3044
  ] }),
2801
- /* @__PURE__ */ jsx22("form", { className: "flex items-center", onSubmit: handleSubmit, children: /* @__PURE__ */ jsxs11(
3045
+ /* @__PURE__ */ jsx24("form", { className: "flex items-center", onSubmit: handleSubmit, children: /* @__PURE__ */ jsxs13(
2802
3046
  "div",
2803
3047
  {
2804
3048
  className: cn(
@@ -2809,7 +3053,7 @@ function Chat({
2809
3053
  "transition-shadow duration-200"
2810
3054
  ),
2811
3055
  children: [
2812
- /* @__PURE__ */ jsx22(
3056
+ /* @__PURE__ */ jsx24(
2813
3057
  ComposerMenu,
2814
3058
  {
2815
3059
  composer,
@@ -2819,7 +3063,7 @@ function Chat({
2819
3063
  disabled: stream.isLoading || missingConfig || isHistoryLoading
2820
3064
  }
2821
3065
  ),
2822
- /* @__PURE__ */ jsx22(
3066
+ /* @__PURE__ */ jsx24(
2823
3067
  "input",
2824
3068
  {
2825
3069
  type: "text",
@@ -2835,7 +3079,7 @@ function Chat({
2835
3079
  autoComplete: "off"
2836
3080
  }
2837
3081
  ),
2838
- /* @__PURE__ */ jsx22(
3082
+ /* @__PURE__ */ jsx24(
2839
3083
  SendButton,
2840
3084
  {
2841
3085
  disabled: isSendDisabled,
@@ -2848,7 +3092,7 @@ function Chat({
2848
3092
  ]
2849
3093
  }
2850
3094
  ) }),
2851
- disclaimer?.text && /* @__PURE__ */ jsx22(
3095
+ disclaimer?.text && /* @__PURE__ */ jsx24(
2852
3096
  "p",
2853
3097
  {
2854
3098
  className: cn(
@@ -2858,7 +3102,10 @@ function Chat({
2858
3102
  children: disclaimer.text
2859
3103
  }
2860
3104
  ),
2861
- /* @__PURE__ */ jsx22("p", { className: "mt-2 text-center text-xs text-muted-foreground", children: t("chat.poweredBy") })
3105
+ /* @__PURE__ */ jsxs13("div", { className: "mt-2 flex items-center justify-center gap-2 text-xs text-muted-foreground", children: [
3106
+ /* @__PURE__ */ jsx24("span", { children: t("chat.poweredBy") }),
3107
+ /* @__PURE__ */ jsx24(ContextUsageIndicator, { className: "absolute right-4" })
3108
+ ] })
2862
3109
  ] })
2863
3110
  ]
2864
3111
  }
@@ -2866,11 +3113,11 @@ function Chat({
2866
3113
  }
2867
3114
 
2868
3115
  // src/components/ui/input.tsx
2869
- import * as React18 from "react";
2870
- import { jsx as jsx23 } from "react/jsx-runtime";
2871
- var Input = React18.forwardRef(
3116
+ import * as React19 from "react";
3117
+ import { jsx as jsx25 } from "react/jsx-runtime";
3118
+ var Input = React19.forwardRef(
2872
3119
  ({ className, type, ...props }, ref) => {
2873
- return /* @__PURE__ */ jsx23(
3120
+ return /* @__PURE__ */ jsx25(
2874
3121
  "input",
2875
3122
  {
2876
3123
  ref,
@@ -2887,10 +3134,10 @@ var Input = React18.forwardRef(
2887
3134
  Input.displayName = "Input";
2888
3135
 
2889
3136
  // src/components/ui/avatar.tsx
2890
- import * as React19 from "react";
3137
+ import * as React20 from "react";
2891
3138
  import * as AvatarPrimitive from "@radix-ui/react-avatar";
2892
- import { jsx as jsx24 } from "react/jsx-runtime";
2893
- var Avatar = React19.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx24(
3139
+ import { jsx as jsx26 } from "react/jsx-runtime";
3140
+ var Avatar = React20.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx26(
2894
3141
  AvatarPrimitive.Root,
2895
3142
  {
2896
3143
  ref,
@@ -2902,7 +3149,7 @@ var Avatar = React19.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
2902
3149
  }
2903
3150
  ));
2904
3151
  Avatar.displayName = AvatarPrimitive.Root.displayName;
2905
- var AvatarImage = React19.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx24(
3152
+ var AvatarImage = React20.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx26(
2906
3153
  AvatarPrimitive.Image,
2907
3154
  {
2908
3155
  ref,
@@ -2911,7 +3158,7 @@ var AvatarImage = React19.forwardRef(({ className, ...props }, ref) => /* @__PUR
2911
3158
  }
2912
3159
  ));
2913
3160
  AvatarImage.displayName = AvatarPrimitive.Image.displayName;
2914
- var AvatarFallback = React19.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx24(
3161
+ var AvatarFallback = React20.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx26(
2915
3162
  AvatarPrimitive.Fallback,
2916
3163
  {
2917
3164
  ref,
@@ -2925,10 +3172,10 @@ var AvatarFallback = React19.forwardRef(({ className, ...props }, ref) => /* @__
2925
3172
  AvatarFallback.displayName = AvatarPrimitive.Fallback.displayName;
2926
3173
 
2927
3174
  // src/components/ui/separator.tsx
2928
- import * as React20 from "react";
2929
- import { jsx as jsx25 } from "react/jsx-runtime";
2930
- var Separator = React20.forwardRef(
2931
- ({ className, orientation = "horizontal", ...props }, ref) => /* @__PURE__ */ jsx25(
3175
+ import * as React21 from "react";
3176
+ import { jsx as jsx27 } from "react/jsx-runtime";
3177
+ var Separator = React21.forwardRef(
3178
+ ({ className, orientation = "horizontal", ...props }, ref) => /* @__PURE__ */ jsx27(
2932
3179
  "div",
2933
3180
  {
2934
3181
  ref,