@forsion/unit 2.13.2 → 2.13.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/main.mjs +3 -3
- package/package.json +1 -1
- package/release.json +5 -5
- package/web/assets/{ArtificialView-Bs_6B211.js → ArtificialView-DS97zlMg.js} +1 -1
- package/web/assets/{AutomationBuilder-C-IFaaBp.js → AutomationBuilder-BsJc8wuC.js} +1 -1
- package/web/assets/{CalendarConfigView-DEsNvVkD.js → CalendarConfigView-BN8mraSo.js} +1 -1
- package/web/assets/{CalendarView-D7ZUE_dr.js → CalendarView-D55PA1vn.js} +1 -1
- package/web/assets/{CapabilityMenu-CrsaTtDe.js → CapabilityMenu-BVrokPpT.js} +1 -1
- package/web/assets/{CheckboxInput-DVO2-1J7.js → CheckboxInput-BuJ3HPm_.js} +1 -1
- package/web/assets/{Chrome-BvpbCvo1.js → Chrome-amTcZNE4.js} +1 -1
- package/web/assets/{CodeView-CB4kG7Y6.js → CodeView-DRVh13k9.js} +3 -3
- package/web/assets/DashboardGridView-D9s9pez_.css +1 -0
- package/web/assets/{DashboardGridView-tgaj9-SM.js → DashboardGridView-DlFyYfUh.js} +2 -2
- package/web/assets/{EventCard-c6s4uGBu.js → EventCard-DUrn2krw.js} +1 -1
- package/web/assets/{ExcalidrawCanvas-NdV86AR3.js → ExcalidrawCanvas-TpbzBF-J.js} +1 -1
- package/web/assets/{FloatingToc-ldOYWe2C.js → FloatingToc-B1d4-5EL.js} +1 -1
- package/web/assets/HomepageView-DnQ_5Obe.css +1 -0
- package/web/assets/{HomepageView-4joJWYlg.js → HomepageView-nzKfbHM-.js} +1 -1
- package/web/assets/{ImageStudioPanels-DgMYAsHj.js → ImageStudioPanels-B2PTq6Yb.js} +1 -1
- package/web/assets/{ImageStudioView-_CYHoOoG.js → ImageStudioView-Cawr6pGW.js} +1 -1
- package/web/assets/{InlineFiles-BIfsx3R-.js → InlineFiles-DKPH5JHz.js} +1 -1
- package/web/assets/{MarkdownBlock-wYEaBBOr.js → MarkdownBlock-BHpDy2qQ.js} +1 -1
- package/web/assets/{ModelPill-DveHcLqq.js → ModelPill-ChzAM3z1.js} +1 -1
- package/web/assets/{MuseLibraryView-Do9RnKiq.js → MuseLibraryView-DLuQ_jyV.js} +2 -2
- package/web/assets/{MuseView-3GL4Ltoj.js → MuseView-CDDwV6SR.js} +2 -2
- package/web/assets/{PageHistoryPanel-BMQC-V_l.js → PageHistoryPanel-BbdXpjJM.js} +2 -2
- package/web/assets/{PdfAnnotator-CyAw8sgq.js → PdfAnnotator-CW0wPWRB.js} +1 -1
- package/web/assets/{PenRow-BSB-h5Pb.js → PenRow-BY-MZLDQ.js} +1 -1
- package/web/assets/{ProductView-B96OeHOP.js → ProductView-0ieVL3rY.js} +1 -1
- package/web/assets/{RightPanel-BgSeCLnw.js → RightPanel-BRexwQ3W.js} +1 -1
- package/web/assets/RunLocationPicker-BrDfOu8-.css +1 -0
- package/web/assets/RunLocationPicker-CadYiE7C.js +43 -0
- package/web/assets/{SketchCard-DAD0jR0i.js → SketchCard-BcXCdBAs.js} +1 -1
- package/web/assets/{StudioGuestSurface-DlUKXBXv.js → StudioGuestSurface-ZJFKnNYF.js} +1 -1
- package/web/assets/{TodoListView-_yFkPUrw.js → TodoListView-DuRdVFgB.js} +1 -1
- package/web/assets/{Tooltip-DXuy9-1_.js → Tooltip-DtDUL18W.js} +1 -1
- package/web/assets/{UnifiedPage-EJNWKzxN.js → UnifiedPage-D7JTfABH.js} +3 -3
- package/web/assets/{amadeus-manual.en-DzRWr4BL.js → amadeus-manual.en-B8J-svqq.js} +1 -1
- package/web/assets/{amadeus-manual.zh-DW32DkL7.js → amadeus-manual.zh-CkCOFnrg.js} +1 -1
- package/web/assets/appStore-ClD7vq5L.css +1 -0
- package/web/assets/{appStore-CidPWYa0.js → appStore-affnJoin.js} +155 -117
- package/web/assets/{arrow-up-right-KPFbRA41.js → arrow-up-right-R4P9Mmxz.js} +1 -1
- package/web/assets/{astryxBridge-Bupzouso.js → astryxBridge-CT2wZJXs.js} +3 -3
- package/web/assets/{automationListSource-1aOVKBLw.js → automationListSource-JVBMsMbC.js} +1 -1
- package/web/assets/{boardSurface-BHuMoQN-.js → boardSurface-Ce0_vf9f.js} +1 -1
- package/web/assets/{book-open-CBeNsIpo.js → book-open-CcXCToyx.js} +1 -1
- package/web/assets/{calendarNavStore-Duyhbmm_.js → calendarNavStore-tQJRVpum.js} +1 -1
- package/web/assets/{canvasPrefs-CxfyDTMT.js → canvasPrefs-CSuX9aLF.js} +1 -1
- package/web/assets/{chatBoxSurface-OBzO1Z5E.js → chatBoxSurface-IG6Vu4Dz.js} +1 -1
- package/web/assets/{circle-question-mark-M8QUJJYk.js → circle-question-mark-O8AhUz35.js} +1 -1
- package/web/assets/{circle-x-Szwop5L_.js → circle-x-AV2ZWulM.js} +1 -1
- package/web/assets/{client-CPUljePZ.js → client-BqhpYbYL.js} +1 -1
- package/web/assets/{code-xml-n9mgGgkv.js → code-xml-DdR58F83.js} +1 -1
- package/web/assets/{codeStudioStore-DXMQwRzG.js → codeStudioStore-Dq5i8nbE.js} +1 -1
- package/web/assets/codingNavigation-CxdCK78-.js +53 -0
- package/web/assets/codingNavigation-_tOR0ell.css +1 -0
- package/web/assets/{create-C19zqt5N.js → create-BgJN5qsj.js} +2 -2
- package/web/assets/{dashboardSurface-BwcH16Qc.js → dashboardSurface-BY-AFB-r.js} +1 -1
- package/web/assets/{deskCapture-B_LKZSPt.js → deskCapture-BD2qD6NI.js} +1 -1
- package/web/assets/{diff2html-DrCCWvpR.js → diff2html-OoRdHZ_O.js} +1 -1
- package/web/assets/{docx-preview-Bi7wekSM.js → docx-preview-B43XC8Cn.js} +1 -1
- package/web/assets/{emoji-DczIG8SO.js → emoji-BPdA62d7.js} +1 -1
- package/web/assets/{floatingTocSurface-rc1ZC7-I.js → floatingTocSurface-BM2SYE_u.js} +1 -1
- package/web/assets/{foldActions-BGocXE-o.js → foldActions-BcyvNVBs.js} +1 -1
- package/web/assets/{folder-CoOsfQ64.js → folder-CCZqnwRc.js} +1 -1
- package/web/assets/{folder-plus-d5MwIMlf.js → folder-plus-BJKT1Pqg.js} +1 -1
- package/web/assets/{gestures-CXFaEydn.js → gestures-BwPbZDkU.js} +1 -1
- package/web/assets/{hand-fuehbnkI.js → hand-DRu7IJdU.js} +1 -1
- package/web/assets/{hard-drive-Bh1DmZg0.js → hard-drive-CXNJUCXw.js} +1 -1
- package/web/assets/i18n-BMo19xaR.css +1 -0
- package/web/assets/i18n.generated-DvY59Zq3.js +15 -0
- package/web/assets/{imageStudio-Dgl1wZNB.js → imageStudio-Axwmd4GW.js} +2 -2
- package/web/assets/imageStudio-DZ0qGU2s.css +1 -0
- package/web/assets/{index-e-MxdHFO.js → index-B1rE_NwA.js} +1 -1
- package/web/assets/{index-lfow5R3O.js → index-BFTY79aq.js} +1 -1
- package/web/assets/{index-38xsQSS9.js → index-BGEkZBs2.js} +1 -1
- package/web/assets/{index-YRWOePBS.js → index-BO2XJc36.js} +1 -1
- package/web/assets/{index-B5UW6SaE.js → index-BYUntVIZ.js} +2 -2
- package/web/assets/{index-2tD0kijW.js → index-C65u4fXd.js} +1 -1
- package/web/assets/{index-BCG8Wnc4.js → index-C_Ohi-I3.js} +1 -1
- package/web/assets/{index-Dff-DL1v.js → index-CkMhazev.js} +1 -1
- package/web/assets/{index-Dc8iMctf.js → index-CobUnTcv.js} +1 -1
- package/web/assets/{index-Dy07SBfH.js → index-D102FOuM.js} +1 -1
- package/web/assets/{index-B8Co6KG3.js → index-D3CYvMpl.js} +1 -1
- package/web/assets/{index-QjVOA7QM.js → index-D78izbLA.js} +1 -1
- package/web/assets/{index-BPqoEOV_.js → index-DDMXVG0h.js} +1 -1
- package/web/assets/{index-CPLtf9Vc.js → index-DY0M_dpd.js} +1 -1
- package/web/assets/{index-7kdR1oL8.js → index-DcbZwhpE.js} +1 -1
- package/web/assets/{index-D4CSH-v1.js → index-Dlkq7gkE.js} +1 -1
- package/web/assets/{index-Ch0FIsJX.js → index-HqmJW2np.js} +1 -1
- package/web/assets/{index-DcRyQ3eU.js → index-LxlyPm0_.js} +1 -1
- package/web/assets/{index-Ce1sNSS8.js → index-Uq4J2aoW.js} +1 -1
- package/web/assets/{index-DvOrTnw2.js → index-WbVt2P8R.js} +1 -1
- package/web/assets/{index-Df9jregv.js → index-XyjIhkPw.js} +1 -1
- package/web/assets/{index-BqGpbntz.js → index-Y2kzYlZq.js} +1 -1
- package/web/assets/{index-CnDAYLti.js → index-mB0EQkyZ.js} +1 -1
- package/web/assets/{index-fViJsYjM.js → index-pJh7JN7_.js} +1 -1
- package/web/assets/{index-Dx9aIoyo.js → index-taRxNsbp.js} +1 -1
- package/web/assets/{invitePage-Dgl3-c_m.js → invitePage-BW0BH8Ac.js} +1 -1
- package/web/assets/{ipc-CNlIRMtU.js → ipc-D7yENkjV.js} +1 -1
- package/web/assets/{jszip.min-tyV0GaJg.js → jszip.min-UE5d5vPJ.js} +1 -1
- package/web/assets/{layout-grid-DFmwM9NU.js → layout-grid-Hs3eDA07.js} +1 -1
- package/web/assets/{linkFollow-iP2zfbA3.js → linkFollow-Msu1XH9v.js} +4 -4
- package/web/assets/{list-tree-i07HsP3D.js → list-tree-DmuRb-p9.js} +1 -1
- package/web/assets/{listFold-Aea6I0Sa.js → listFold-CKxjyY5_.js} +1 -1
- package/web/assets/{lock-TSDKuCod.js → lock-kffGfeHt.js} +1 -1
- package/web/assets/{log-out-DK84lW5n.js → log-out-B5gEP0tF.js} +1 -1
- package/web/assets/main-DIyFlyfK.js +20 -0
- package/web/assets/markdownEditorSurface-Cx2rqFAY.js +3 -0
- package/web/assets/{message-square-plus-3wFslIMY.js → message-square-plus-DxBPIhPS.js} +1 -1
- package/web/assets/{messages-DEAGRsC3.js → messages-4w1Khzm1.js} +1 -1
- package/web/assets/minus-CfoZ4oxr.js +1 -0
- package/web/assets/{mobileEntry-5UaAITwY.js → mobileEntry-B8JwR53-.js} +1 -1
- package/web/assets/{nativeDownload-B3JGkABw.js → nativeDownload-Udrv_tmU.js} +1 -1
- package/web/assets/{pageChrome-DFi9zs6F.js → pageChrome-D-9npbUE.js} +1 -1
- package/web/assets/{pageChrome-BDHHmRnt.css → pageChrome-eO9pb2fH.css} +1 -1
- package/web/assets/{pageTree-DZ7Eiro-.js → pageTree-CIXFRCLk.js} +2 -2
- package/web/assets/{pen-tool-ChGmX6g_.js → pen-tool-D_Y9We9x.js} +1 -1
- package/web/assets/{pencil-CJsJD7M_.js → pencil-DGiTRzW1.js} +1 -1
- package/web/assets/phoneList-BQfCJwKF.css +1 -0
- package/web/assets/{phoneList-DrxIwJxQ.js → phoneList-DHUia6HT.js} +1 -1
- package/web/assets/{pluginChat-0QI9a8Q1.js → pluginChat-BXuJiMYi.js} +1 -1
- package/web/assets/{redo-2-CI57sDFr.js → redo-2-QgiKEg9T.js} +1 -1
- package/web/assets/{rotate-ccw-xgT_0UN9.js → rotate-ccw-BLoH5er1.js} +1 -1
- package/web/assets/{sharePage-C2Yqx0NQ.js → sharePage-DYYN5usb.js} +2 -2
- package/web/assets/{shareViewer-DKPWhTJv.js → shareViewer-BzuSyJv_.js} +1 -1
- package/web/assets/{star-C9KTji9N.js → star-BmywYD3u.js} +1 -1
- package/web/assets/{tableSurface-cYs6dX6B.js → tableSurface-21LDYY_G.js} +1 -1
- package/web/assets/{terminal-DPZazOQ2.js → terminal-BlmA_Z1C.js} +1 -1
- package/web/assets/{terminalView-CsJmxE_m.js → terminalView-SAxITnRW.js} +1 -1
- package/web/assets/{type-C5J875vb.js → type-DmIL6FB-.js} +1 -1
- package/web/assets/{undo-2-BOUt5qks.js → undo-2-yMeXc8Wi.js} +1 -1
- package/web/assets/{unitAccount-BIAIxKNp.js → unitAccount-BPYRAa3m.js} +1 -1
- package/web/assets/{unitBridge-b2C6zb3a.js → unitBridge-BNVzai6X.js} +1 -1
- package/web/assets/{unitCloudTransport-NGtDDKWo.js → unitCloudTransport-iFweA1xk.js} +1 -1
- package/web/assets/{unitOwnerAccess-CwH9ApZT.js → unitOwnerAccess-Bggl7bDP.js} +1 -1
- package/web/assets/{unitShim-CY8EVkKD.js → unitShim-BP2nBO_k.js} +3 -3
- package/web/assets/{upload-CrbEAW8C.js → upload-D20PZHXc.js} +1 -1
- package/web/assets/userSpaces-CrLrKklx.js +1 -0
- package/web/assets/{viewportLock-Bi3orrUs.css → viewportLock-DO1lzA2N.css} +1 -1
- package/web/assets/viewportLock-tlT6H_Hc.js +629 -0
- package/web/assets/{workflow-DY2Cnaei.js → workflow-Bd6xBHiT.js} +1 -1
- package/web/assets/{zoom-in-BcuPvIYd.js → zoom-in-_TgFOpyv.js} +1 -1
- package/web/index.html +2 -2
- package/web/assets/DashboardGridView-hpRmBr9B.css +0 -1
- package/web/assets/HomepageView-Cxf3AWBu.css +0 -1
- package/web/assets/RunLocationPicker-CEmFio4n.css +0 -1
- package/web/assets/RunLocationPicker-M1UoJyjf.js +0 -38
- package/web/assets/appStore-DeaC1U32.css +0 -1
- package/web/assets/codingNavigation-CCjs1kon.js +0 -53
- package/web/assets/codingNavigation-yp19w6uu.css +0 -1
- package/web/assets/i18n-DjziAw8r.css +0 -1
- package/web/assets/i18n.generated-BiQFRL2U.js +0 -15
- package/web/assets/imageStudio--KF9gwHA.css +0 -1
- package/web/assets/main-D7CEGndC.js +0 -20
- package/web/assets/markdownEditorSurface-DISu_twy.js +0 -3
- package/web/assets/minus-BBdfT_sc.js +0 -1
- package/web/assets/phoneList-DvpzD3zT.css +0 -1
- package/web/assets/userSpaces-B_Njvel_.js +0 -1
- package/web/assets/viewportLock-DZ927PNz.js +0 -629
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./appStore-affnJoin.js","./index-BYUntVIZ.js","./nativeDownload-Udrv_tmU.js","./ipc-D7yENkjV.js","./client-BqhpYbYL.js","./appStore-ClD7vq5L.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{d as c,j as t,r as Qe,u as ge,t as Nn,_ as Te,f as gs,L as bs}from"./index-BYUntVIZ.js";import{c as ws}from"./client-BqhpYbYL.js";import{f as vs,g as ks,L as In,T as xs,C as on,W as ys,h as Ss,u as js,j as Cs,s as Es,k as Ns,a as Is,b as Tn,D as Ts,A as Ln,F as Le,S as Mn,M as Rn,c as Dn,B as Ls,P as Pn,d as Ms,N as Rs,l as Ds,m as Ps,i as As,e as zs}from"./viewportLock-tlT6H_Hc.js";import{G as ie,M as Os,I as Fs,J as _s,K as $s,L as Bs,P as Ws,N as Vs,R as qs,T as Hs,U as Ys,V as Us,W as Ks,X as Xs,Y as Gs,Z as Zs,_ as vt,$ as Js,a0 as Qs,a1 as ea,a2 as ta,a3 as An,a4 as na,a5 as sa,m as te,a6 as oe,a7 as aa,a8 as oa,a9 as zn,aa as ia,ab as et,ac as rn,ad as ra,ae as ca,af as fe,ag as ft,ah as kt,ai as cn,aj as la,ak as ln,al as da,am as Ue,an as dn,ao as ua,ap as je,aq as ma,ar as pa,as as fa,at as On,au as ha,av as ga,aw as ba,ax as wa,ay as Fn,S as va,az as Ae,aA as tt,aB as Me,aC as Pe,aD as ka,aE as xa,aF as yt,aG as _n,aH as Ze,aI as St,u as C,aJ as un,aK as ya,aL as Sa,aM as ja,aN as mn,aO as Ca,aP as $n,aQ as Ea,q as $,aR as Na,aS as jt,t as Ct,i as nt,j as Ia,aT as Bn,aU as Ta,aV as pn,aW as Wn,g as La,aX as Ma,Q as Ra,aY as Vn,O as Da,aZ as fn,a_ as Pa,a$ as hn,b0 as Aa,h as Et,b1 as za,b2 as Je,b3 as Oa,b4 as Fa,b5 as _a,b6 as $a,b7 as Ba,b8 as Wa,b9 as Va,ba as qa,x as Ha,y as Ya,z as Ua,A as Ka,bb as Xa,C as Ga,D as Za,E as Ja,F as Qa}from"./appStore-affnJoin.js";import{P as eo}from"./pen-tool-D_Y9We9x.js";import{T as to,R as no,M as so,V as ao,a as oo,C as io,H as ro,f as co}from"./userSpaces-CrLrKklx.js";import{C as lo,P as uo,H as mo,A as Se,m as po}from"./phoneList-DHUia6HT.js";import{M as fo}from"./Chrome-amTcZNE4.js";import{T as ho}from"./terminal-BlmA_Z1C.js";import{B as go}from"./AutomationBuilder-BsJc8wuC.js";import{S as bo}from"./star-BmywYD3u.js";import{F as qn}from"./folder-CCZqnwRc.js";import{F as Hn}from"./UnifiedPage-D7JTfABH.js";import{i as wo,q as vo,o as gn,a as ko,c as xo,A as yo,p as So,d as jo,E as Co}from"./codingNavigation-CxdCK78-.js";import"./i18n.generated-DvY59Zq3.js";import{S as Eo,C as No}from"./RunLocationPicker-CadYiE7C.js";import{R as Io}from"./RightPanel-BRexwQ3W.js";import{n as To}from"./codeStudioStore-Dq5i8nbE.js";import"./ModelPill-ChzAM3z1.js";import"./rotate-ccw-BLoH5er1.js";import"./upload-D20PZHXc.js";import"./hard-drive-CXNJUCXw.js";import"./CapabilityMenu-BVrokPpT.js";import"./book-open-CcXCToyx.js";import"./folder-plus-BJKT1Pqg.js";import"./circle-x-AV2ZWulM.js";import"./layout-grid-Hs3eDA07.js";import"./nativeDownload-Udrv_tmU.js";import"./DashboardGridView-DlFyYfUh.js";import"./FloatingToc-B1d4-5EL.js";import"./MarkdownBlock-BHpDy2qQ.js";import"./index-Y2kzYlZq.js";import"./linkFollow-Msu1XH9v.js";import"./emoji-BPdA62d7.js";import"./listFold-CKxjyY5_.js";import"./pageChrome-D-9npbUE.js";import"./pageTree-CIXFRCLk.js";import"./pluginExt-Byb64tQO.js";import"./list-tree-DmuRb-p9.js";import"./pencil-DGiTRzW1.js";import"./type-DmIL6FB-.js";import"./undo-2-yMeXc8Wi.js";import"./redo-2-QgiKEg9T.js";import"./code-xml-DdR58F83.js";import"./lock-kffGfeHt.js";import"./ipc-D7yENkjV.js";import"./InlineFiles-DKPH5JHz.js";import"./workflow-Bd6xBHiT.js";import"./canvasPrefs-CSuX9aLF.js";import"./circle-question-mark-O8AhUz35.js";import"./gestures-BwPbZDkU.js";import"./MuseView-CDDwV6SR.js";import"./automationListSource-JVBMsMbC.js";import"./messages-4w1Khzm1.js";import"./approvalText-Cy2UAUAQ.js";import"./message-square-plus-DxBPIhPS.js";import"./log-out-B5gEP0tF.js";import"./arrow-up-right-R4P9Mmxz.js";import"./index-DY0M_dpd.js";/* empty css */import"./StudioGuestSurface-ZJFKnNYF.js";import"./minus-CfoZ4oxr.js";import"./SketchCard-BcXCdBAs.js";import"./hand-DRu7IJdU.js";import"./foldActions-BcyvNVBs.js";import"./create-BgJN5qsj.js";import"./pdf.worker.min-CGb3BKV9.js";import"./zoom-in-_TgFOpyv.js";const Lo=[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]],Mo=ie("box",Lo);const Ro=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],Do=ie("calendar",Ro);const Po=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],Ao=ie("chevron-up",Po);const zo=[["path",{d:"m11 17-5-5 5-5",key:"13zhaf"}],["path",{d:"m18 17-5-5 5-5",key:"h8a8et"}]],Oo=ie("chevrons-left",zo);const Fo=[["path",{d:"m6 17 5-5-5-5",key:"xnjwq"}],["path",{d:"m13 17 5-5-5-5",key:"17xmmf"}]],_o=ie("chevrons-right",Fo);const $o=[["path",{d:"M4 22V4a1 1 0 0 1 .4-.8A6 6 0 0 1 8 2c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10a1 1 0 0 1-.4.8A6 6 0 0 1 16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528",key:"1jaruq"}]],Bo=ie("flag",$o);const Wo=[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]],Vo=ie("tag",Wo);const qo=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],Ho=ie("user",qo),Yn={folder:qn,"folder-open":sa,star:bo,heart:ro,home:na,zap:An,bookmark:ta,bell:go,tag:Vo,flag:Bo,pin:uo,box:Mo,package:ea,settings:Qs,wrench:Js,terminal:ho,code:io,"file-text":vt,image:Zs,music:oo,video:ao,camera:Gs,globe:Xs,compass:Ks,map:fo,calendar:Do,clock:lo,mail:so,"message-circle":Us,users:Ys,user:Ho,search:Hs,filter:qs,sparkles:Vs,rocket:no,target:to,trophy:xs,lightbulb:In,coffee:ks,palette:Ws,layers:Bs,database:$s,"pen-tool":eo,inbox:_s,bot:Fs,command:vs,moon:Os},Yo=Object.keys(Yn),ht=n=>n?Yn[n]:void 0;function Uo(n,s,o){const m=n.target.closest("button")??s;let i=!1,v=!1,p,f;const w=parseFloat(getComputedStyle(document.body).zoom)||1,d=n.clientX,g=n.clientY;m.setPointerCapture(n.pointerId);const b=(S=!1)=>{if(v=!0,window.removeEventListener("pointermove",I,!0),window.removeEventListener("pointerup",N,!0),window.removeEventListener("pointercancel",h,!0),window.removeEventListener("keydown",y,!0),window.removeEventListener("blur",h),m.removeEventListener("lostpointercapture",h),m.hasPointerCapture(n.pointerId)&&m.releasePointerCapture(n.pointerId),document.documentElement.classList.remove("rb-pointer-dragging"),p?.remove(),f?.remove(),i){const M=T=>{T.preventDefault(),T.stopImmediatePropagation(),j()},z=()=>{clearTimeout(L),L=window.setTimeout(j,0)},j=()=>{window.removeEventListener("click",M,!0),window.removeEventListener("pointerup",z,!0),clearTimeout(L)};window.addEventListener("click",M,!0),S||window.addEventListener("pointerup",z,{capture:!0,once:!0});let L=window.setTimeout(j,S?0:1e4)}},h=()=>{v||(b(),i&&o.cancel())},y=S=>{S.key==="Escape"&&(S.preventDefault(),S.stopImmediatePropagation(),h())},I=S=>{if(!(S.pointerId!==n.pointerId||v)){if(!(S.buttons&1)){h();return}if(!(!i&&Math.hypot(S.clientX-d,S.clientY-g)<6)){i||(i=!0,document.documentElement.classList.add("rb-pointer-dragging"),f=document.createElement("div"),f.className="rb-pointer-shield",f.style.width=`${window.innerWidth/w}px`,f.style.height=`${window.innerHeight/w}px`,f.setAttribute("aria-hidden","true"),document.body.appendChild(f),p=s.cloneNode(!0),p.removeAttribute("data-id"),p.querySelectorAll("[id]").forEach(M=>M.removeAttribute("id")),p.className="rb-pointer-ghost",p.setAttribute("aria-hidden","true"),p.style.width=`${s.getBoundingClientRect().width/w}px`,document.body.appendChild(p),o.start()),S.preventDefault(),p.style.left=`${(S.clientX+12)/w}px`,p.style.top=`${(S.clientY+12)/w}px`,f.style.pointerEvents="none";try{o.move(S)}finally{f.style.pointerEvents=""}}}},N=S=>{S.pointerId!==n.pointerId||S.button!==0||v||(b(!0),i&&(S.preventDefault(),o.drop(S)))};return window.addEventListener("pointermove",I,!0),window.addEventListener("pointerup",N,!0),window.addEventListener("pointercancel",h,!0),window.addEventListener("keydown",y,!0),window.addEventListener("blur",h),m.addEventListener("lostpointercapture",h),h}const gt=4,bn=5,wn=5,Ko=1e3,Xo=100;function vn(n){if(n>=9)return"";const s=ha({id:`space-slot-${n+1}`,hotkey:`mod+${n+1}`});return s?ga(s,ba()):""}function Re({item:n,expanded:s}){if(n.component){const i=n.component;return t.jsx(i,{expanded:s})}const o=n.icon,m=n.tooltip?je(n.tooltip):"";return t.jsxs("button",{className:"rb-btn","aria-label":m||void 0,"data-rb-tip":s?void 0:m||void 0,onClick:n.onClick,children:[o&&t.jsx(o,{size:18}),s&&t.jsx("span",{className:"rb-label",children:m})]})}function Go({cmd:n,expanded:s,overrideIcon:o}){const[,m]=c.useReducer(f=>f+1,0),i=o??n.icon??An,v=je(n.title);let p;if(n.checked)try{p=!!n.checked()}catch{p=void 0}return t.jsxs("button",{className:`rb-btn${p?" is-on":""}`,"aria-pressed":p,"aria-label":v,"data-rb-tip":s?void 0:v,onMouseEnter:n.checked?m:void 0,onMouseLeave:n.checked?m:void 0,onClick:()=>{const f=n.run();n.checked&&(m(),f&&typeof f.then=="function"&&f.then(m,m))},children:[t.jsx(i,{size:18}),s&&t.jsx("span",{className:"rb-label",children:v})]})}const Ke=24,De=n=>n.startsWith("space:")?n.slice(6):null,Zo=600;function Jo(){const n=te(e=>e.items),s=te(e=>e.expanded),o=te(e=>e.order),m=te(e=>e.bottomOrder),i=te(e=>e.folders),v=te(e=>e.commandItems),p=te(e=>e.commandIcons),f=te(e=>e.recentCount),w=oe(e=>e.recent),d=aa(e=>e.commands);oa(e=>e.overrides);const{t:g}=zn(),b=()=>te.getState(),[h,y]=c.useState(null),I=c.useRef(void 0);c.useEffect(()=>()=>I.current?.(),[]);const[N,S]=c.useState(null),[M,z]=c.useState(null),[j,L]=c.useState(null),[T,G]=c.useState(null),[Y,B]=c.useState(null),[W,V]=c.useState(null),[_,re]=c.useState(99),O=c.useRef(null),U=c.useRef(null),ce=c.useRef(null),le=c.useRef(null),K=c.useRef(null),R=c.useRef(null),de=c.useRef(void 0),ne=c.useRef(null),[se,ue]=c.useState({top:0,bottom:0}),[P,st]=c.useState(null),[be,we]=c.useState({}),k=c.useRef({}),A=c.useRef({});c.useEffect(()=>()=>{for(const e of Object.values(k.current))window.clearTimeout(e?.timer)},[]);const[Oe,q]=c.useState(!1),me=c.useRef(void 0);c.useEffect(()=>()=>window.clearTimeout(me.current),[]);const ve=e=>{for(const r of["top","bottom"]){const u=k.current[r];if(!u)continue;window.clearTimeout(u.timer);const l=A.current[r];l&&(l.style.transform=u.from?`translateY(${-u.from*D}px)`:""),delete k.current[r]}we({}),window.clearTimeout(me.current);const a=!window.matchMedia("(prefers-reduced-motion: reduce)").matches;q(a),a&&(me.current=window.setTimeout(()=>q(!1),240)),st(e)},[ke,Fe]=c.useState(null),Ce=c.useRef(null),at=c.useRef(void 0),_e=c.useRef(!1),Nt=c.useRef(0),Ee=()=>{window.clearTimeout(at.current),Ce.current=null,_e.current&&(_e.current=!1,Nt.current=Date.now()),Fe(null)},ot=!!h||!!Y||!!W||!!T;c.useEffect(()=>{(ot||s)&&Ee()},[ot,s]),c.useEffect(()=>()=>window.clearTimeout(at.current),[]);const ns=e=>{const a=e.target.closest("[data-rb-tip]");if(a===Ce.current)return;const r=_e.current||Date.now()-Nt.current<=Xo;if(Ee(),!a||ot||s)return;Ce.current=a;const u=()=>{if(Ce.current!==a||!a.isConnected||!a.dataset.rbTip)return;const l=a.getBoundingClientRect();_e.current=!0,Fe({text:a.dataset.rbTip,mid:l.top+l.height/2})};r?u():at.current=window.setTimeout(u,Ko)},ss=new Set(i.flatMap(e=>e.items)),$e=new Map,It=e=>{const a=[];for(const u of n)(u.side??"top")===e&&!u.pinned&&a.push({kind:"item",id:u.id,item:u});if(e==="bottom")for(const u of v){const l=d.find(x=>x.id===u);l&&a.push({kind:"cmd",id:`cmd:${u}`,cmd:l})}for(const u of i)u.zone===e&&a.push({kind:"folder",id:u.id,folder:u});for(const u of a)$e.set(u.id,u);return la(a.map(u=>u.id),e==="top"?o:m).map(u=>$e.get(u)).filter(u=>!ss.has(u.id))},Z=It("top"),J=It("bottom"),Tt=e=>e.items.reduce((a,r)=>a+($e.has(r)?1:0),0),as=n.filter(e=>e.side==="bottom"&&e.pinned),os=n.filter(e=>e.side==="head"),is=n.filter(e=>e.side==="home"),D=(s?34:32)+gt;c.useLayoutEffect(()=>{const e=O.current;if(!e)return;const a=()=>{const u=getComputedStyle(e),l=(U.current?.offsetHeight??0)+(le.current?.offsetHeight??0),x=e.clientHeight-parseFloat(u.paddingTop)-parseFloat(u.paddingBottom)-l-(ce.current?.offsetHeight??0)-2*D-48;re(Math.max(2,Math.floor(x/D)))};a();const r=new ResizeObserver(a);return r.observe(e),le.current&&r.observe(le.current),()=>r.disconnect()},[s,D,n.length,i.length,v.length,P]);const Lt=(e,a)=>e<=a?e:a+1,Mt=Lt(Z.length,bn),it=Lt(J.length,wn);let ae=Mt,pe=it;if(P)P==="top"?ae=_:pe=_;else if(ae+pe>_)if(Z.length===0)ae=0,pe=_;else if(J.length===0)ae=_,pe=0;else{const e=Math.floor(_/2);ae=Math.max(1,Math.min(Mt,Math.max(e,_-it))),pe=Math.max(1,Math.min(it,_-ae))}const Rt=(e,a,r,u,l)=>{if(e.length<=a&&e.length<=l)return{shown:e,tail:[],start:0,max:0};const x=Math.max(0,a-1),E=e.length-x,F=Math.min(Math.max(0,u),E),ee=r?e.length-x-F:F;return{shown:e.slice(ee,ee+x),tail:[...e.slice(0,ee),...e.slice(ee+x)],start:ee,max:E}},Be=Rt(Z,ae,!1,se.top,P==="top"?1/0:bn),We=Rt(J,pe,!0,se.bottom,P==="bottom"?1/0:wn),Dt=w.map(e=>n.find(a=>a.id===`space:${e}`)).filter(e=>!!e).slice(0,ia(f,_,ae,pe,!!P)),rs=(e,a)=>r=>{const u=A.current[e];if(!a.max||h||!r.deltaY||!u)return;window.clearTimeout(de.current);let l=k.current[e];l||(l=k.current[e]={px:a.start*D,from:a.start,timer:0},we(E=>({...E,[e]:!0}))),window.clearTimeout(l.timer);const x=r.deltaMode?Math.sign(r.deltaY)*D:Math.max(-D,Math.min(D,r.deltaY));l.px=Math.max(0,Math.min(a.max*D,l.px+x)),u.style.transform=`translateY(${-l.px}px)`,l.timer=window.setTimeout(()=>cs(e,a),120)},cs=(e,a)=>{const r=k.current[e],u=A.current[e];if(!r||!u)return;const l=r.at??r.from,x=r.px-l*D;let E=Math.round(r.px/D);E===l&&x&&(E+=Math.sign(x)),Pt(e,a,Math.max(0,Math.min(a.max,E)))},Pt=(e,a,r)=>{const u=A.current[e];if(!u)return;let l=k.current[e];l||(l=k.current[e]={px:a.start*D,from:a.start,timer:0},we(x=>({...x,[e]:!0}))),window.clearTimeout(l.timer),l.px=r*D,l.at=r,u.style.transform=r?`translateY(${-r*D}px)`:"",l.timer=window.setTimeout(()=>{delete k.current[e],we(x=>({...x,[e]:!1})),ue(x=>({...x,[e]:e==="top"?r:a.max-r}))},240)};c.useEffect(()=>()=>window.clearTimeout(de.current),[]);const At=c.useRef(()=>{});At.current=()=>{if(!h)for(const[e,a]of[["top",Be],["bottom",We]])se[e]&&(a.max&&A.current[e]?Pt(e,a,e==="top"?0:a.max):ue(r=>({...r,[e]:0})))};const zt=!!(se.top||se.bottom||be.top||be.bottom);c.useEffect(()=>{if(!zt)return;const e=()=>{ln()&&(window.clearTimeout(de.current),de.current=window.setTimeout(()=>{ln()&&At.current()},Zo))},a=r=>{const u=r.target;r.button!==0||u?.closest?.(".rb-menu, .rb-iconpick, [data-rb-overlay]")||u&&(O.current?.contains(u)||u.closest(".rb-fly"))&&!u.closest(".rb-btn:not(.rb-more, .rb-plus, .rb-toggle, .rb-folder)")||e()};return window.addEventListener("click",a,!0),window.addEventListener("blur",e),()=>{window.removeEventListener("click",a,!0),window.removeEventListener("blur",e)}},[zt]);const Q=T?.folderId?i.find(e=>e.id===T.folderId):void 0,Ve=()=>{R.current&&(window.clearTimeout(R.current),R.current=null)},Ot=()=>{Ve(),R.current=window.setTimeout(()=>{h||G(null)},150)},rt=(e,a,r,u)=>{Ve(),G({key:e,zone:a,folderId:u,top:r.getBoundingClientRect().top})};c.useLayoutEffect(()=>{const e=K.current;if(!e||!T)return;const a=e.getBoundingClientRect().bottom-(window.innerHeight-8);a>0&&G({...T,top:Math.max(8,T.top-a)})},[T?.key,Q?.items.length]);const Ft=!!T;c.useEffect(()=>{if(!Ft)return;const e=r=>{r.key==="Escape"&&G(null)},a=r=>{const u=r.target;!K.current?.contains(u)&&!O.current?.contains(u)&&G(null)};return window.addEventListener("keydown",e),window.addEventListener("mousedown",a),()=>{window.removeEventListener("keydown",e),window.removeEventListener("mousedown",a)}},[Ft]),c.useEffect(()=>{if(!P)return;const e=()=>ve(null),a=u=>{if(u.button!==0)return;const l=u.target;l?.closest?.(".rb-menu, .rb-iconpick, .rb-fly, [data-rb-overlay]")||l&&O.current?.contains(l)&&l.closest("button")||e()},r=u=>{u.key==="Escape"&&e()};return window.addEventListener("pointerdown",a,!0),window.addEventListener("keydown",r),window.addEventListener("blur",e),()=>{window.removeEventListener("pointerdown",a,!0),window.removeEventListener("keydown",r),window.removeEventListener("blur",e)}},[P,D]);const ct=c.useRef(new Map),_t=c.useRef(()=>{});c.useEffect(()=>{_t.current=e=>{const a=Z[e];if(a){if(a.kind==="folder"){const r=ct.current.get(a.id)??O.current;r&&rt(a.id,"top",r,a.id);return}G(null),a.kind==="cmd"?a.cmd.run():a.id.startsWith("space:")?et(a.id.slice(6)):a.item.onClick?.()}}});const $t=Math.min(9,Z.length);c.useEffect(()=>{for(let e=1;e<=9;e++){if(e>$t){rn(`space-slot-${e}`);continue}ra({id:`space-slot-${e}`,title:()=>ca("lcl.ribbon.switchSpace",{n:e}),keywords:`space switch ${e} 切换 空间`,hotkey:`mod+${e}`,run:()=>_t.current(e-1)})}return()=>{for(let e=1;e<=9;e++)rn(`space-slot-${e}`)}},[$t]);const Bt=(e,a,r,u)=>{e.dataTransfer.effectAllowed="move";const l=e.currentTarget.getBoundingClientRect();e.dataTransfer.setDragImage(e.currentTarget,e.clientX-l.left,e.clientY-l.top),y({id:a,zone:r,from:u})},xe=()=>{ne.current=null,y(null),S(null),z(null),L(null)},Ne=h&&fe()?.openSpace?De(h.id):null,Wt=c.useRef({dropped:!1,gone:!1}),lt=(e,a)=>{const r=O.current?.getBoundingClientRect();if(!r)return!0;const u=x=>e>=x.left-Ke&&e<=x.right+Ke&&a>=x.top-Ke&&a<=x.bottom+Ke,l=K.current?.getBoundingClientRect();return u(r)||!!l&&u(l)},Vt=e=>{const a=e.target;return!!a&&(!!O.current?.contains(a)||!!K.current?.contains(a))};c.useLayoutEffect(()=>{if(!Ne)return;const e={dropped:!1,gone:!1};Wt.current=e;const a=l=>{e.gone=!1,!Vt(l)&&(l.preventDefault(),l.stopPropagation(),l.dataTransfer&&(l.dataTransfer.dropEffect="move"),z(x=>x&&null),L(x=>x&&null))},r=l=>{e.dropped=!0,!Vt(l)&&(l.preventDefault(),l.stopPropagation(),lt(l.clientX,l.clientY)||fe()?.openSpace?.(Ne,{screenX:l.screenX,screenY:l.screenY}))},u=l=>{(l.clientX<=0||l.clientY<=0||l.clientX>=window.innerWidth||l.clientY>=window.innerHeight)&&(e.gone=!0)};return window.addEventListener("dragover",a,!0),window.addEventListener("drop",r,!0),window.addEventListener("dragleave",u,!0),()=>{window.removeEventListener("dragover",a,!0),window.removeEventListener("drop",r,!0),window.removeEventListener("dragleave",u,!0)}},[Ne]);const qt=e=>{const a=Wt.current;if(Ne&&!a.dropped){const{clientX:r,clientY:u}=e,l=r<0||u<0||r>window.innerWidth||u>window.innerHeight,x=!l&&/^(IFRAME|WEBVIEW)$/.test(document.elementFromPoint(r,u)?.tagName??"");(l||!lt(r,u)&&(a.gone||x))&&fe()?.openSpace?.(Ne,e.screenX||e.screenY?{screenX:e.screenX,screenY:e.screenY}:void 0)}xe()},ye=(e,a,r)=>{a&&(e.preventDefault(),e.stopPropagation(),e.dataTransfer.dropEffect="move",r?.())},Ht=(e,a)=>{const r=e.querySelectorAll(".rb-slot"),u=r[0]?.getBoundingClientRect().top??0,l=r.length>1?r[1].getBoundingClientRect().top-u:0;return{top:u,pitch:l,grabDy:a??l/2}},Yt=(e,a,r)=>ua(a,r,ne.current??Ht(e)),Ut=(e,a)=>{const r=e.parentElement;r&&(ne.current=Ht(r,a-e.getBoundingClientRect().top))},qe=(e,a,r=h)=>{const u=r;if(xe(),!u||u.zone!==e||u.id===a)return;u.from&&b().moveOutOfFolder(u.id);const l=e==="top"?b().order:b().bottomOrder,x=da(l,(e==="top"?Z:J).map(F=>F.id)),E=a?x.indexOf(a):-1;b().setZoneOrder(e,Ue(x,u.id,E>=0?E:x.length))},He=(e,a,r=h)=>{const u=r;if(xe(),!(!u||u.zone!==e.zone||u.id.startsWith("folder:"))){if(u.from===e.id)b().setFolderItems(e.id,Ue(e.items,u.id,a??e.items.length));else if(b().moveIntoFolder(e.id,u.id),u.from||b().setZoneOrder(e.zone,dn(e.zone==="top"?b().order:b().bottomOrder,(e.zone==="top"?Z:J).map(l=>l.id),u.id)),a!==void 0){const l=b().folders.find(x=>x.id===e.id);l&&b().setFolderItems(e.id,Ue(l.items,u.id,a))}}},dt=c.useRef(null);dt.current={target:(e,a)=>{const r=document.elementFromPoint(e.clientX,e.clientY),u=!!r&&(!!O.current?.contains(r)||!!K.current?.contains(r));if(u){const x=r.closest("[data-rb-folder]")?.dataset.rbFolder,E=i.find(H=>H.id===x);if(E&&E.zone===a.zone){const H=r.closest("[data-rb-folder-index]");return z(null),L(E.id),S(H?.dataset.id??null),H||rt(E.id,E.zone,r.closest("[data-rb-folder]"),E.id),{kind:"folder",folder:E,at:H?Number(H.dataset.rbFolderIndex):void 0}}const F=r.closest("[data-rb-more]")?.dataset.rbMore;if(F===a.zone)return z(null),L(`more:${F}`),{kind:"bar",zone:a.zone,id:a.zone==="bottom"?J[0]?.id??null:null};const ee=r.closest(".rb-top, .rb-bottom");if(ee){const H=ee.classList.contains("rb-top")?"top":"bottom";if(H!==a.zone)return{kind:"cancel"};const an=(H==="top"?Be:We).shown.map(Ie=>Ie.id),pt=Yt(ee,e.clientY,an.length);return L(null),S(null),z(Ie=>Ie?.zone===H&&Ie.index===pt?Ie:{zone:H,index:pt}),{kind:"bar",zone:H,id:an[pt]??null}}}return z(null),L(null),S(null),{kind:e.clientX<0||e.clientY<0||e.clientX>=window.innerWidth||e.clientY>=window.innerHeight||!u&&!lt(e.clientX,e.clientY)?"tear":"cancel"}},drop:(e,a,r)=>{if(r.kind==="bar")qe(r.zone,r.id,a);else if(r.kind==="folder")He(r.folder,r.at,a);else if(xe(),r.kind==="tear"){const u=fe(),l=De(a.id);l&&u?.openSpace?.(l,u.cursorScreenPoint?.()??{screenX:e.screenX,screenY:e.screenY})}}};const Kt=(e,a,r,u)=>{if(!fe()?.ribbonPointerDrag||!De(a)||e.button!==0||!e.isPrimary)return;e.stopPropagation(),I.current?.();const l=e.currentTarget,x={id:a,zone:r,from:u};u||Ut(l,e.clientY);let E={kind:"cancel"};I.current=Uo(e.nativeEvent,l,{start:()=>{Ee(),Ve(),y(x)},move:F=>{E=dt.current.target(F,x)},drop:F=>{dt.current.drop(F,x,E)},cancel:xe})},Xt=e=>!(fe()?.ribbonPointerDrag&&De(e)),Gt=ft.prompt??((e,a)=>Promise.resolve(window.prompt(e,a))),ls=e=>{Gt(g("lcl.ribbon.newFolder"),g("lcl.ribbon.folderDefaultName")).then(a=>{const r=a?.trim();r&&b().addFolder(e,r)})},Ye=e=>[...e==="top"&&ft.newSpace?[{label:g("lcl.ribbon.newSpace"),onClick:ft.newSpace}]:[],...e==="bottom"?[{label:g("lcl.ribbon.addCommand"),onClick:()=>ma(a=>b().addCommandItem(a))}]:[],{label:g(e==="top"?"lcl.ribbon.newFolderSpaces":"lcl.ribbon.newFolderCommands"),onClick:()=>ls(e)}],ds=e=>a=>{a.defaultPrevented||(a.preventDefault(),B({x:a.clientX,y:a.clientY,entries:Ye(e)}))},us=e=>{e.defaultPrevented||(e.preventDefault(),B({x:e.clientX,y:e.clientY,entries:[...Ye("top"),...Ye("bottom")]}))},Zt=(e,a,r,u)=>{B(null),V({x:e,y:a,current:r,apply:u})},ms=e=>a=>{a.preventDefault(),a.stopPropagation();const r=a.clientX,u=a.clientY;B({x:r,y:u,entries:[{label:g("lcl.ribbon.changeIcon"),onClick:()=>Zt(r,u,e.icon,l=>b().setFolderIcon(e.id,l))},{label:g("lcl.ribbon.rename"),onClick:()=>{Gt(g("lcl.ribbon.renameFolder"),e.name).then(l=>{const x=l?.trim();x&&b().renameFolder(e.id,x)})}},{label:g("lcl.ribbon.dissolveFolder"),onClick:()=>b().removeFolder(e.id)}]})},Jt=e=>{const a=De(e.id),r=fe()?.openSpace;return[...a&&r?[{label:g("lcl.ribbon.openInNewWindow"),onClick:()=>r(a)}]:[],...e.menu?.()??[]]},Qt=e=>a=>{if(a.defaultPrevented)return;const r=Jt(e);r.length&&(a.preventDefault(),a.stopPropagation(),B({x:a.clientX,y:a.clientY,entries:r}))},en=e=>a=>{a.preventDefault(),a.stopPropagation();const r=a.clientX,u=a.clientY;B({x:r,y:u,entries:[{label:g("lcl.ribbon.setIcon"),onClick:()=>Zt(r,u,b().commandIcons[e],l=>b().setCommandIcon(e,l))},{label:g("lcl.ribbon.removeCommand"),onClick:()=>b().removeCommandItem(e)}]})},ps=e=>{const a=ht(e.icon)??qn;return t.jsxs("button",{ref:r=>{r?ct.current.set(e.id,r):ct.current.delete(e.id)},className:`rb-btn rb-folder${j===e.id?" drag-into":""}`,"data-rb-folder":e.id,"aria-label":`${e.name} (${Tt(e)})`,onMouseEnter:r=>rt(e.id,e.zone,r.currentTarget,e.id),onMouseLeave:Ot,onContextMenu:ms(e),onDragOver:r=>ye(r,!!h&&h.zone===e.zone&&!h.id.startsWith("folder:"),()=>{z(null),L(e.id)}),onDragLeave:()=>{j===e.id&&L(null)},onDrop:r=>{!h||h.id.startsWith("folder:")||(r.preventDefault(),r.stopPropagation(),He(e))},children:[t.jsx(a,{size:18}),s&&t.jsx("span",{className:"rb-label",children:e.name})]})},tn=e=>{const a=P===e,r=g(a?"lcl.ribbon.less":"lcl.ribbon.more"),u=a?e==="top"?Ao:On:fa;return t.jsxs("button",{className:`rb-btn rb-more${a?" is-open":""}${j===`more:${e}`?" drag-into":""}`,"data-rb-more":e,"aria-label":r,"aria-expanded":a,"data-rb-tip":s?void 0:r,onClick:()=>ve(a?null:e),onDragOver:l=>ye(l,!!h&&h.zone===e,()=>{z(null),L(`more:${e}`)}),onDragLeave:()=>{j===`more:${e}`&&L(null)},onDrop:l=>{l.preventDefault(),l.stopPropagation(),qe(e,e==="bottom"?J[0]?.id??null:null)},children:[t.jsx(u,{size:18}),s&&t.jsx("span",{className:"rb-label",children:r})]})},ut=(e,a)=>{const r=a??s;return e.kind==="item"?t.jsx(Re,{item:e.item,expanded:r}):e.kind==="cmd"?t.jsx(Go,{cmd:e.cmd,expanded:r,overrideIcon:ht(p[e.cmd.id])}):ps(e.folder)},fs=(e,a,r,u,l,x)=>{const E=u?u.indexOf(e.id):r;return t.jsxs("div",{"data-id":e.id,className:`rb-slot${h?.id===e.id?" dragging":""}${l?" drag-over":""}`,style:E!==r?{transform:`translateY(${(E-r)*D}px)`}:void 0,draggable:Xt(e.id),onPointerDown:F=>Kt(F,e.id,a,null),onDragStart:F=>{Ut(F.currentTarget,F.clientY),Bt(F,e.id,a,null)},onDragEnd:qt,onContextMenu:e.kind==="cmd"?en(e.cmd.id):e.kind==="item"?Qt(e.item):void 0,children:[ut(e),a==="top"&&s&&vn(x)&&t.jsx("span",{className:"rb-key",children:vn(x)})]},e.id)},mt=e=>g(e==="top"?"lcl.ribbon.addSpaceOrFolder":"lcl.ribbon.addCommand"),nn=e=>t.jsxs("button",{className:"rb-btn rb-plus","aria-label":mt(e),"data-rb-tip":s?void 0:mt(e),onClick:a=>{const r=a.currentTarget.getBoundingClientRect();B({x:r.right+6,y:r.top,entries:Ye(e)})},children:[t.jsx(pa,{size:16}),s&&t.jsx("span",{className:"rb-label",children:mt(e)})]}),sn=(e,a)=>{const r=a.shown.map(l=>l.id),u=h&&M?.zone===e&&r.includes(h.id)?Ue(r,h.id,M.index):null;return t.jsxs("div",{className:`rb-group rb-${e}`,onContextMenu:ds(e),onWheel:rs(e,a),onDragOver:l=>{const x=Yt(l.currentTarget,l.clientY,r.length);ye(l,!!h&&h.zone===e,()=>{L(null),z(E=>E?.zone===e&&E.index===x?E:{zone:e,index:x})})},onDrop:l=>{l.preventDefault(),l.stopPropagation(),qe(e,(M?.zone===e?r[M.index]:null)??null)},children:[e==="bottom"&&t.jsxs(t.Fragment,{children:[nn(e),(a.tail.length>0||P===e)&&tn(e)]}),t.jsx("div",{className:"rb-strip",style:{height:Math.max(0,a.shown.length*D-gt)},children:t.jsx("div",{ref:l=>{A.current[e]=l},className:"rb-strip-in",style:a.start?{transform:`translateY(${-a.start*D}px)`}:void 0,children:(e==="top"?Z:J).map((l,x)=>{const E=x-a.start;return E>=0&&E<a.shown.length?fs(l,e,E,u,!u&&M?.zone===e&&M.index===E,x):t.jsx("div",{className:"rb-cell","aria-hidden":!0,inert:!0,style:{height:D-gt},children:(be[e]||Oe)&&ut(l)},l.id)})})}),e==="top"&&t.jsxs(t.Fragment,{children:[(a.tail.length>0||P===e)&&tn(e),nn(e)]})]})},hs=(e,a,r,u)=>t.jsx("div",{"data-id":e.id,className:`rb-fly-row${h?.id===e.id?" dragging":""}${N===e.id&&h?.id!==e.id?` drag-over${h&&u.indexOf(h.id)>=0&&u.indexOf(h.id)<r?" below":""}`:""}`,"data-rb-folder":a.id,"data-rb-folder-index":r,draggable:Xt(e.id),onPointerDown:l=>Kt(l,e.id,a.zone,a.id),onDragStart:l=>{l.stopPropagation(),Bt(l,e.id,a.zone,a.id)},onDragOver:l=>ye(l,!!h&&h.zone===a.zone&&h.id!==e.id&&!h.id.startsWith("folder:"),()=>S(e.id)),onDragLeave:()=>{N===e.id&&S(null)},onDrop:l=>{l.preventDefault(),l.stopPropagation(),He(a,r)},onDragEnd:qt,onContextMenu:e.kind==="cmd"?en(e.cmd.id):l=>{l.preventDefault(),l.stopPropagation(),B({x:l.clientX,y:l.clientY,entries:[...e.kind==="item"?Jt(e.item):[],{label:g("lcl.ribbon.moveOut"),onClick:()=>{b().moveOutOfFolder(e.id);const x=a.zone==="top"?b().order:b().bottomOrder;b().setZoneOrder(a.zone,[...dn(x,(a.zone==="top"?Z:J).map(E=>E.id),e.id),e.id])}}]})},children:ut(e,!0)},e.id);return t.jsxs("div",{ref:O,className:`rb${s?" rb-expanded":""}${h?" rb-dragging":""}${P?` rb-open-${P}`:""}`,onContextMenu:us,onMouseOver:ns,onMouseLeave:Ee,onMouseDownCapture:e=>{Ee(),Ce.current=e.target.closest("[data-rb-tip]")},onDragOver:e=>ye(e,!!h),onDrop:e=>{if(!h)return;e.preventDefault();const a=h.zone,r=M?.zone===a?(a==="top"?Be:We).shown[M.index]?.id:void 0;if(r===void 0){xe();return}qe(a,r)},children:[t.jsxs("div",{ref:U,className:"rb-head",children:[t.jsxs("button",{className:"rb-btn rb-toggle","aria-label":g(s?"lcl.ribbon.iconsOnly":"lcl.ribbon.showLabels"),"aria-expanded":s,"data-rb-tip":s?void 0:g("lcl.ribbon.showLabels"),onClick:()=>b().toggleExpanded(),children:[s?t.jsx(Oo,{size:18}):t.jsx(_o,{size:18}),s&&t.jsx("span",{className:"rb-label",children:g("lcl.ribbon.iconsOnly")})]}),os.map(e=>t.jsx(Re,{item:e,expanded:s},e.id))]}),t.jsx("div",{ref:ce,className:"rb-group rb-home",children:is.map(e=>t.jsx(Re,{item:e,expanded:s},e.id))}),P!=="bottom"&&sn("top",Be),Dt.length>0&&t.jsx("div",{className:"rb-group rb-recent",role:"group","aria-label":g("lcl.ribbon.recentSpaces"),children:Dt.map(e=>t.jsx("div",{className:"rb-recent-slot","data-recent-id":e.id,onContextMenu:Qt(e),children:t.jsx(Re,{item:e,expanded:s})},e.id))}),P!=="top"&&sn("bottom",We),t.jsx("div",{ref:le,className:"rb-group rb-pinned",children:as.map(e=>t.jsx(Re,{item:e,expanded:s},e.id))}),T&&Q&&t.jsxs("div",{ref:K,className:"rb-fly","data-rb-folder":Q.id,style:(()=>{const e=kt(O.current);return{left:((O.current?.getBoundingClientRect().right??44)+4)/e,top:T.top/e}})(),onMouseEnter:Ve,onMouseLeave:Ot,onDragOver:e=>ye(e,!!h&&h.zone===T.zone&&!h.id.startsWith("folder:")&&e.target===e.currentTarget),onDrop:e=>{e.target===e.currentTarget&&(e.preventDefault(),He(Q))},children:[t.jsx("div",{className:"rb-fly-head",children:Q.name}),Tt(Q)===0&&t.jsx("div",{className:"rb-fly-empty",children:g("lcl.ribbon.folderEmpty")}),Q.items.map((e,a)=>{const r=$e.get(e);return r?hs(r,Q,a,Q.items):null})]}),ke&&!s&&t.jsx("div",{className:"rb-tip",role:"tooltip",style:(()=>{const e=kt(O.current);return{left:((O.current?.getBoundingClientRect().right??44)+6)/e,top:ke.mid/e}})(),children:ke.text}),Y&&t.jsx("div",{className:"rb-menu-backdrop",onMouseDown:()=>B(null),onContextMenu:e=>{e.preventDefault(),B(null)},children:t.jsx(cn,{className:"rb-menu",x:Y.x,y:Y.y,onMouseDown:e=>e.stopPropagation(),children:Y.entries.map((e,a)=>t.jsx("button",{onClick:()=>{B(null),e.onClick()},children:e.label},a))})}),W&&t.jsx("div",{className:"rb-menu-backdrop",onMouseDown:()=>V(null),onContextMenu:e=>{e.preventDefault(),V(null)},children:t.jsxs(cn,{className:"rb-iconpick",x:W.x,y:W.y,onMouseDown:e=>e.stopPropagation(),children:[t.jsx("button",{className:"rb-iconpick-reset",onClick:()=>{const e=W.apply;V(null),e("")},children:g("lcl.ribbon.defaultIcon")}),t.jsx("div",{className:"rb-iconpick-grid",children:Yo.map(e=>{const a=ht(e);return t.jsx("button",{className:`rb-iconpick-btn${W.current===e?" on":""}`,title:e,onClick:()=>{const r=W.apply;V(null),r(e)},children:t.jsx(a,{size:17})},e)})})]})})]})}const kn=8,Qo=n=>n.dataset.lclShift==="end"?kn:n.dataset.lclShift==="start"?-kn:0;function ei(){const n=Array.from(document.querySelectorAll(".dv-groupview")).map(o=>({r:o.getBoundingClientRect(),papery:!o.querySelector(".wb-tab--icon")})).filter(o=>o.r.width>0&&o.r.height>0),s=3;for(const o of document.querySelectorAll(".dv-sash")){const m=!!o.closest(".dv-split-view-container.dv-horizontal"),i=o.getBoundingClientRect();if(!i.width&&!i.height)continue;const v=m?i.left+i.width/2:i.top+i.height/2,[p,f]=m?[i.top,i.bottom]:[i.left,i.right];let w=null,d=null;for(const b of n){const[h,y,I,N]=m?[b.r.left,b.r.right,b.r.top,b.r.bottom]:[b.r.top,b.r.bottom,b.r.left,b.r.right];N<=p||I>=f||(w===null&&Math.abs(y-v)<=s&&(w=b.papery),d===null&&Math.abs(h-v)<=s&&(d=b.papery))}const g=w===!1&&d===!0?"end":w===!0&&d===!1?"start":"";g?o.dataset.lclShift=g:delete o.dataset.lclShift}}function ti(){const n=document.createElement("div");n.className="lcl-sash-tick",document.body.appendChild(n);let s=null,o=0;const m=(h,y)=>{const I=!!h.closest(".dv-split-view-container.dv-horizontal"),N=h.getBoundingClientRect(),S=Qo(h);cancelAnimationFrame(o),o=requestAnimationFrame(()=>{n.classList.add("show"),n.classList.toggle("h",!I);const M=kt(n);I?(n.style.left=`${(N.left+N.width/2+S)/M}px`,n.style.top=`${Math.min(Math.max(y.clientY,N.top),N.bottom)/M}px`):(n.style.left=`${Math.min(Math.max(y.clientX,N.left),N.right)/M}px`,n.style.top=`${(N.top+N.height/2+S)/M}px`)})},i=h=>h instanceof Element?h.closest(".dv-sash"):null,v=h=>{const y=s instanceof HTMLElement?s:i(h.target);y?m(y,h):n.classList.contains("show")&&(cancelAnimationFrame(o),n.classList.remove("show"))},p=h=>{s=i(h.target)},f=h=>{s&&(s=null,i(h.target)||(cancelAnimationFrame(o),n.classList.remove("show")))};let w=0;const d=()=>{window.clearTimeout(w),w=window.setTimeout(ei,120)},g=h=>h instanceof Element&&(h.matches(".dv-sash, .dv-view, .dv-groupview")||!!h.querySelector(".dv-sash, .dv-groupview")),b=new MutationObserver(h=>{for(const y of h)for(const I of[...y.addedNodes,...y.removedNodes])if(g(I)){d();return}});return b.observe(document.body,{childList:!0,subtree:!0}),d(),document.addEventListener("pointermove",v,{passive:!0}),document.addEventListener("pointerdown",p,{passive:!0}),document.addEventListener("pointerup",f,{passive:!0}),()=>{b.disconnect(),window.clearTimeout(w),cancelAnimationFrame(o),document.removeEventListener("pointermove",v),document.removeEventListener("pointerdown",p),document.removeEventListener("pointerup",f),n.remove()}}const Un=({dark:n,soft:s,buildDefault:o,header:m,noRibbon:i,footer:v})=>(c.useEffect(()=>wa(),[]),c.useEffect(()=>ti(),[]),Fn==="mobile"?t.jsxs(t.Fragment,{children:[t.jsx(va,{dark:n,soft:s,buildDefault:o}),t.jsx(on,{})]}):t.jsxs("div",{className:`shell${i?" shell--noribbon":""}`,children:[m,t.jsxs("div",{className:"shell-top",children:[!i&&t.jsx(Jo,{}),t.jsxs("div",{className:"shell-work",children:[t.jsx(ys,{dark:n,soft:s,buildDefault:o}),v]})]}),t.jsx(on,{})]})),ni=["n","s","e","w","ne","nw","se","sw"],bt=n=>{const s=n.currentTarget,o=s.dataset.edge;if(n.type==="pointerdown"){if(n.button!==0)return;s.setPointerCapture(n.pointerId),window.tangu?.miniResize?.(o,!0)}else n.type==="pointermove"?s.hasPointerCapture(n.pointerId)&&window.tangu?.miniResize?.(o):window.tangu?.miniResize?.(null)},Kn=({buildDefault:n,direct:s,resizable:o})=>{const m=oe(j=>j.spaces),i=oe(j=>j.activeSpaceId),[,v]=c.useReducer(j=>j+1,0);c.useEffect(()=>Ae(v),[]);const p=m.filter(tt),f=p.find(j=>j.id===i),w=Me(j=>j.mainLeaves.find(L=>L.id===j.activeMainId)),[d,g]=c.useState(!1),{t:b}=zn(),h=f?.icon,y=s?Pe(s.view.type):void 0,I=c.useRef(!1);y&&(I.current=!0),c.useEffect(()=>{s&&I.current&&!y&&window.tangu?.closeSelf?.()},[s,y]);const N=s?.title||(y?je(y.displayName):f?je(f.mini?.name??f.name):"Mini Panel");c.useEffect(()=>{const j=Me.getState();if(j.setDefaultBuilder(n),!s)if(f)j.getActiveLeaf()?.type!==f.mini.view.type&&j.resetLayout();else{const L=p.find(T=>T.id==="tangu")??p[0];L&&ka(L.id),j.resetLayout()}},[m,i,f,n,s]),c.useEffect(()=>{const j=L=>{L.key==="Escape"&&g(!1)};return window.addEventListener("keydown",j),()=>window.removeEventListener("keydown",j)},[]);const S=w&&(s?w.type===s.view.type:f&&w.type===f.mini.view.type)?Me.getState().getActiveLeaf():null,M=S?Pe(S.type):null,z=()=>{if(s){Ze({type:s.mainView.type,params:{...s.mainView.params,...Me.getState().getActiveLeaf()?.params}});return}const j=St();j?.mini&&Ze({spaceId:j.id,type:j.mini.mainView.type,params:{...j.mini.mainView.params,...Me.getState().getActiveLeaf()?.params}})};return t.jsxs("div",{className:"mini-card-shell","data-space":s?"direct":f?.id,children:[t.jsxs("header",{className:"mini-card-chrome",children:[t.jsxs("button",{className:"mini-card-space","aria-label":b("lcl.mini.switchSpace"),"aria-expanded":d,disabled:!!s||p.length<2,onClick:()=>g(!d),children:[!s&&h&&t.jsx(h,{size:15}),t.jsx("span",{children:N}),!s&&p.length>1&&t.jsx(On,{size:12})]}),t.jsx("div",{className:"mini-card-drag-title"}),t.jsx("button",{className:"mini-card-action","aria-label":b("lcl.mini.showMain"),title:b("lcl.mini.showMain"),disabled:!s&&!f,onClick:z,children:t.jsx(xa,{size:15})}),t.jsx("button",{className:"mini-card-action mini-card-close","aria-label":b("lcl.mini.close"),onClick:()=>window.tangu?.closeSelf?.(),children:t.jsx(yt,{size:15})})]}),t.jsx("main",{className:"mini-card-main",children:S&&M?t.jsx("div",{className:"mini-panel-view","data-view":S.type,children:t.jsx(_n,{children:t.jsx(c.Suspense,{fallback:null,children:M.factory({leaf:S,params:S.params})})})},`${S.id}:${S.type}`):t.jsx("div",{className:"mini-panel-empty",children:b("lcl.mini.empty")})}),d&&t.jsxs(t.Fragment,{children:[t.jsx("button",{className:"mini-card-dismiss","aria-label":b("lcl.mini.closeMenu"),onClick:()=>g(!1)}),t.jsx("section",{className:"mini-card-popover","aria-label":b("lcl.mini.switchSpace"),children:t.jsx("div",{className:"mini-card-popover-list",children:p.map(j=>{const L=j.icon;return t.jsxs("button",{className:`mini-card-row${j.id===i?" active":""}`,onClick:()=>{et(j.id),g(!1)},children:[L&&t.jsx(L,{size:15}),t.jsx("span",{className:"mini-card-row-label",children:je(j.mini.name??j.name)})]},j.id)})})})]}),o&&ni.map(j=>t.jsx("div",{className:"mini-card-edge","data-edge":j,onPointerDown:bt,onPointerMove:bt,onLostPointerCapture:bt},j))]})};function si(){return t.jsx("div",{className:"mac-titlebar"})}const wt=9e3,Xe=5*1024*1024;function xt(n){return typeof n=="string"?n.replace(/\bBearer\s+[A-Za-z0-9._~+\/-]+=*/gi,"Bearer [redacted]").replace(/\b(sk-[a-zA-Z0-9_-]{12,})\b/g,"[redacted]").replace(/((?:["']?)(?:api[_-]?key|access[_-]?token|refresh[_-]?token|token|password|secret|authorization|cookie)(?:["']?)\s*[:=]\s*["']?)([^\s,"';&}]+)/gi,"$1[redacted]"):Array.isArray(n)?n.map(xt):n&&typeof n=="object"?Object.fromEntries(Object.entries(n).map(([s,o])=>[s,/^(?:token|.*api[_-]?key|access[_-]?token|refresh[_-]?token|password|secret|authorization|cookie|set-cookie)$/i.test(s)?"[redacted]":xt(o)])):n}async function ai(n,s,o){const m=await Ss(n,s,{...o,maxBytes:Xe});let i=xt({...m,feedbackSelection:o});const v=w=>{const d=JSON.stringify(w,null,2);return{json:d,bytes:new TextEncoder().encode(d).byteLength}};let p=v(i);const f=i.messages||[];if(p.bytes>Xe&&f.length){const w=b=>({...i,messageCount:b,messagesTruncated:!0,messages:f.slice(f.length-b)});let d=0,g=f.length-1;for(;d<g;){const b=Math.ceil((d+g)/2);v(w(b)).bytes<=Xe?d=b:g=b-1}i=w(d),p=v(i)}return{...p,filename:`tangu-feedback-${s?.id.slice(0,8)||"app"}-${new Date().toISOString().slice(0,10)}.json`,missing:Object.entries(m.sources).filter(([,w])=>w!=="included").map(([w])=>w),truncated:!!i.messagesTruncated||!!i.activityLogTruncated}}Qe({"feedback.subtitle":{zh:"告诉我们哪里可以做得更好。",en:"Tell us what could work better."},"feedback.kind":{zh:"反馈类型",en:"Feedback type"},"feedback.bug":{zh:"遇到问题",en:"Report a problem"},"feedback.idea":{zh:"功能建议",en:"Suggest a feature"},"feedback.other":{zh:"其他反馈",en:"Something else"},"feedback.description":{zh:"具体发生了什么?",en:"What happened?"},"feedback.bugPlaceholder":{zh:`你当时在做什么?预期的结果是什么,实际又发生了什么?
|
|
3
|
+
如果可以,请写下重现步骤。`,en:`What were you doing? What did you expect, and what happened instead?
|
|
4
|
+
Include steps to reproduce it if you can.`},"feedback.ideaPlaceholder":{zh:"你想完成什么?哪项改进会对你有帮助?",en:"What are you trying to do? What change would help?"},"feedback.otherPlaceholder":{zh:"分享你的使用体验或想法……",en:"Share your experience or thoughts…"},"feedback.context":{zh:"附带诊断信息",en:"Include diagnostic information"},"feedback.diagnostics":{zh:"应用与运行日志",en:"App and runtime logs"},"feedback.diagnosticsHint":{zh:"版本、界面状态、错误、运行时间线与用量;进程日志可能涉及其他会话。",en:"Version, interface state, errors, run timeline and usage. Process logs may include other sessions."},"feedback.conversation":{zh:"当前会话内容",en:"Current conversation"},"feedback.conversationHint":{zh:"整段对话,包含工具输入与输出;附件超过 5 MB 时保留最新的部分。",en:"The whole conversation, including tool inputs and outputs. If the attachment exceeds 5 MB, the most recent part is kept."},"feedback.activity":{zh:"近期活动记录",en:"Recent activity"},"feedback.activityHint":{zh:"近 2 天内最新 500 行,可能包含文件名与操作路径。",en:"The latest 500 lines from the last 2 days; may contain file names and paths."},"feedback.sessionContext":{zh:"关联会话:{name}",en:"Linked conversation: {name}"},"feedback.withoutSession":{zh:"未关联会话,仍可提交应用问题。",en:"No linked conversation. You can still report an app issue."},"feedback.privacy":{zh:"已过滤常见凭据字段。日志仍可能包含路径或内容片段,请按需选择并预览。",en:"Common credential fields are filtered. Logs may still contain paths or content excerpts; choose what to include and review the preview."},"feedback.preview":{zh:"预览附件",en:"Preview attachment"},"feedback.export":{zh:"导出日志文件",en:"Export log file"},"feedback.backToForm":{zh:"返回反馈",en:"Back to feedback"},"feedback.preparing":{zh:"正在准备诊断信息…",en:"Preparing diagnostics…"},"feedback.sending":{zh:"正在提交…",en:"Sending…"},"feedback.ready":{zh:"诊断附件已就绪 · {size}",en:"Diagnostics ready · {size}"},"feedback.textOnly":{zh:"仅提交反馈文字",en:"Only your feedback text will be sent"},"feedback.partial":{zh:"部分诊断来源不可用:{sources}。将提交已获取的内容。",en:"Some diagnostic sources are unavailable: {sources}. Available information will be sent."},"feedback.source.appVersion":{zh:"应用版本",en:"app version"},"feedback.source.messages":{zh:"会话内容",en:"conversation"},"feedback.source.agentConfig":{zh:"会话设置",en:"session settings"},"feedback.source.backendLogs":{zh:"运行输出",en:"runtime output"},"feedback.source.connection":{zh:"连接信息",en:"connection details"},"feedback.source.backendStatus":{zh:"引擎状态",en:"engine status"},"feedback.source.usage":{zh:"用量",en:"usage"},"feedback.source.timeline":{zh:"运行时间线",en:"run timeline"},"feedback.source.activityLog":{zh:"活动记录",en:"activity"},"feedback.truncated":{zh:"较早的部分记录因达到上限未附带,附件内已标记。",en:"Some older records were left out because of collection limits; this is marked in the attachment."},"feedback.tooLarge":{zh:"附件超过 5 MB,请减少勾选的内容后再提交。",en:"The attachment exceeds 5 MB. Deselect some information before sending."},"feedback.prepareFailed":{zh:"诊断信息准备失败。请重试,或取消勾选后仅提交文字。",en:"Could not prepare diagnostics. Retry, or deselect the options to send text only."},"feedback.refresh":{zh:"重新收集",en:"Collect again"},"feedback.successTitle":{zh:"反馈已收到",en:"Feedback received"},"feedback.successHint":{zh:"感谢你帮助我们改进 Tangu。你可以在账户中心查看回复。",en:"Thanks for helping improve Tangu. You can view replies in your account center."},"feedback.ticket":{zh:"反馈编号:{id}",en:"Reference: {id}"},"feedback.viewFeedback":{zh:"查看我的反馈",en:"View my feedback"},"feedback.done":{zh:"完成",en:"Done"},"feedback.limit":{zh:"反馈内容不能超过 {max} 字。",en:"Feedback cannot exceed {max} characters."},"feedback.retry":{zh:"重试提交",en:"Try again"},"feedback.diagnosePrompt":{zh:`我在使用 Tangu 时遇到一个问题,想请你帮我诊断:
|
|
5
|
+
|
|
6
|
+
{description}
|
|
7
|
+
|
|
8
|
+
请结合当前会话的上下文分析可能的原因,并给出排查步骤。`,en:`I ran into a problem while using Tangu and would like your help diagnosing it:
|
|
9
|
+
|
|
10
|
+
{description}
|
|
11
|
+
|
|
12
|
+
Using the context of this session, analyze the likely causes and suggest troubleshooting steps.`}});function Xn(n){C.getState().setPendingDraft(n),$.getState().openView("chat",{followActive:!0,reuseKey:"primary"},"main")}const Gn=({cfg:n,activeSession:s,onClose:o,surface:m="modal"})=>{const{t:i}=ge(),[v]=c.useState(()=>({cfg:n,session:s})),p=C(k=>k.feedbackDraft),[f,w]=c.useState("bug"),[d,g]=c.useState(!0),[b,h]=c.useState(!1),[y,I]=c.useState(!1),[N,S]=c.useState(0),[M,z]=c.useState(null),[j,L]=c.useState(!1),[T,G]=c.useState(!1),[Y,B]=c.useState(null),[W,V]=c.useState(""),_=c.useRef(null),re=c.useRef(!1),O=c.useRef(o);O.current=o;const U=d||b||y,ce=`${d}:${b}:${y}:${N}`,le=M?.key===ce?M:null,K=U&&!le,R=U?le?.report:void 0,de=!!R&&R.bytes>Xe,ne=p.trim().length>wt,se=!!p.trim()&&!ne&&!T&&!Y&&!K&&!de&&(!U||!!R),ue=()=>{re.current||O.current()};c.useEffect(()=>{if(!U)return;let k=!0;return ai(v.cfg,v.session,{diagnostics:d,conversation:b,activity:y}).then(A=>{k&&z({key:ce,report:A})}).catch(()=>{k&&z({key:ce,failed:!0})}),()=>{k=!1}},[v,d,b,y,N,ce,U]),c.useEffect(()=>{const k=document.activeElement,A=requestAnimationFrame(()=>_.current?.querySelector("textarea")?.focus()),Oe=q=>{if(q.key==="Escape"&&(q.preventDefault(),q.stopImmediatePropagation(),re.current||O.current()),q.key==="Tab"){const me=Array.from(_.current?.querySelectorAll('button:not(:disabled), textarea:not(:disabled), input:not(:disabled), [tabindex="0"]')||[]).filter(Fe=>Fe.getClientRects().length>0),ve=me[0],ke=me[me.length-1];if(!ve){q.preventDefault(),_.current?.focus();return}q.shiftKey&&(document.activeElement===ve||!_.current?.contains(document.activeElement))?(q.preventDefault(),ke.focus()):!q.shiftKey&&(document.activeElement===ke||!_.current?.contains(document.activeElement))&&(q.preventDefault(),ve.focus())}};return document.addEventListener("keydown",Oe,!0),()=>{cancelAnimationFrame(A),document.removeEventListener("keydown",Oe,!0),k?.focus()}},[]);const P=async()=>{if(!(!se||re.current)){if(!window.tangu?.submitFeedback){V(i("feedback.errUnavailable"));return}re.current=!0,G(!0),V("");try{const k=await window.tangu.submitFeedback({description:`[Tangu · ${i(`feedback.${f}`)}]
|
|
13
|
+
|
|
14
|
+
${p.trim()}`,...R?{sessionLogJson:R.json,sessionLogName:R.filename}:{}});k.ok?(B(k),C.setState({feedbackDraft:""})):V(k.error==="attachment-too-large"?i("feedback.tooLarge"):i("feedback.errFail",{err:k.error==="not-logged-in"?i("feedback.errNotLoggedIn"):k.error||"Unknown error"}))}catch(k){V(i("feedback.errFail",{err:String(k?.message||k)}))}finally{re.current=!1,G(!1)}}},st=()=>{if(!p.trim()||T)return;const k=i("feedback.diagnosePrompt",{description:p.trim()});window.tangu?.requestMainAction?window.tangu.requestMainAction("chat-draft",k):Xn(k),ue()},be=R?`${(R.bytes/1024).toFixed(1)} KB`:"",we=()=>{if(!R)return;const k=URL.createObjectURL(new Blob([R.json],{type:"application/json;charset=utf-8"})),A=document.createElement("a");A.href=k,A.download=R.filename,A.click(),setTimeout(()=>URL.revokeObjectURL(k),1e4)};return t.jsx("div",{className:m==="panel"?"feedback-panel-surface":"memv-modal feedback-overlay",onClick:k=>{m==="modal"&&k.target===k.currentTarget&&ue()},children:t.jsxs("div",{ref:_,className:"modal feedback-modal",role:"dialog","aria-modal":"true","aria-labelledby":"feedback-title",tabIndex:-1,onKeyDown:k=>{(k.metaKey||k.ctrlKey)&&k.key==="Enter"&&!k.nativeEvent.isComposing&&(k.preventDefault(),P())},children:[t.jsxs("div",{className:"modal-head feedback-head",children:[t.jsxs("div",{className:"feedback-heading",children:[t.jsx(un,{size:19}),t.jsxs("div",{children:[t.jsx("h2",{id:"feedback-title",children:i("feedback.title")}),t.jsx("p",{children:i("feedback.subtitle")})]})]}),t.jsx("button",{className:"icon-btn",onClick:ue,disabled:T,"aria-label":i("settings.btn.cancel"),children:t.jsx(yt,{size:18})})]}),Y?t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"modal-body feedback-success",role:"status",children:[t.jsx("span",{className:"feedback-success-icon",children:t.jsx(ya,{size:28})}),t.jsx("h3",{children:i("feedback.successTitle")}),t.jsx("p",{children:i("feedback.successHint")}),Y.id&&t.jsx("code",{children:i("feedback.ticket",{id:Y.id})}),Y.attachmentSkipped&&t.jsx("p",{className:"feedback-warning",children:i("feedback.okNoLog")}),W&&t.jsx("p",{className:"feedback-warning",role:"alert",children:W})]}),t.jsxs("div",{className:"feedback-footer",children:[window.tangu?.openAccountCenter&&t.jsx("button",{className:"btn ghost",onClick:()=>{V(""),window.tangu.openAccountCenter("feedback").catch(()=>V(i("feedback.errUnavailable")))},children:i("feedback.viewFeedback")}),t.jsx("span",{className:"grow"}),t.jsx("button",{autoFocus:!0,className:"btn primary",onClick:ue,children:i("feedback.done")})]})]}):t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"modal-body feedback-body",children:[j?t.jsxs(t.Fragment,{children:[t.jsxs("button",{className:"btn ghost sm feedback-back",onClick:()=>L(!1),children:[t.jsx(Sa,{size:14}),i("feedback.backToForm")]}),t.jsxs("div",{className:"feedback-file",children:[t.jsx(vt,{size:15}),t.jsx("span",{children:R?.filename}),t.jsx("span",{children:be})]}),t.jsx("pre",{className:"feedback-preview",tabIndex:0,children:R?.json})]}):t.jsxs(t.Fragment,{children:[t.jsx("div",{className:"feedback-kinds",role:"group","aria-label":i("feedback.kind"),children:[{id:"bug",Icon:ja},{id:"idea",Icon:In},{id:"other",Icon:un}].map(({id:k,Icon:A})=>t.jsxs("button",{className:"btn ghost","aria-pressed":f===k,disabled:T,onClick:()=>w(k),children:[t.jsx(A,{size:15}),i(`feedback.${k}`)]},k))}),t.jsxs("div",{className:"feedback-description",children:[t.jsx("label",{htmlFor:"feedback-description",children:i(f==="bug"?"feedback.description":"feedback.label")}),t.jsx("textarea",{id:"feedback-description",value:p,onChange:k=>{C.setState({feedbackDraft:k.target.value}),V("")},placeholder:i(`feedback.${f}Placeholder`),disabled:T,"aria-invalid":ne,"aria-describedby":"feedback-count"}),t.jsxs("span",{id:"feedback-count",className:ne?"feedback-warning":"feedback-count",children:[p.trim().length.toLocaleString()," / ",wt.toLocaleString()]})]}),t.jsxs("section",{className:"feedback-context","aria-labelledby":"feedback-context-title",children:[t.jsxs("div",{className:"feedback-section-heading",children:[t.jsx("h3",{id:"feedback-context-title",children:i("feedback.context")}),t.jsx("code",{children:"/feedback"})]}),t.jsx("p",{className:"feedback-session",children:v.session?i("feedback.sessionContext",{name:v.session.title||v.session.id.slice(0,8)}):i("feedback.withoutSession")}),[{id:"diagnostics",checked:d,change:g,unavailable:!1},{id:"conversation",checked:b,change:h,unavailable:!v.session},{id:"activity",checked:y,change:I,unavailable:!window.tangu?.exportActivity}].map(k=>t.jsxs("label",{className:"feedback-option","data-disabled":k.unavailable||void 0,children:[t.jsx("input",{type:"checkbox",checked:k.checked,onChange:A=>k.change(A.target.checked),disabled:T||k.unavailable}),t.jsxs("span",{children:[t.jsx("strong",{children:i(`feedback.${k.id}`)}),t.jsx("small",{children:i(`feedback.${k.id}Hint`)})]})]},k.id))]}),t.jsxs("div",{className:"feedback-report-status",role:"status",children:[t.jsx("span",{children:K?t.jsxs(t.Fragment,{children:[t.jsx(mn,{size:13,className:"spin"}),i("feedback.preparing")]}):R?t.jsxs(t.Fragment,{children:[t.jsx(vt,{size:13}),i("feedback.ready",{size:be})]}):i(U?"feedback.prepareFailed":"feedback.textOnly")}),t.jsxs("div",{children:[R&&t.jsx("button",{className:"btn ghost sm",onClick:()=>L(!0),disabled:T,children:i("feedback.preview")}),R&&t.jsxs("button",{className:"btn ghost sm",onClick:we,disabled:T,children:[t.jsx(Ca,{size:13}),i("feedback.export")]}),U&&t.jsx("button",{className:"icon-btn",onClick:()=>S(k=>k+1),disabled:T||K,"aria-label":i("feedback.refresh"),title:i("feedback.refresh"),children:t.jsx($n,{size:13})})]})]}),!!R?.missing.length&&t.jsx("p",{className:"feedback-warning",children:i("feedback.partial",{sources:R.missing.map(k=>i(`feedback.source.${k}`)).join(", ")})}),R?.truncated&&t.jsx("p",{className:"feedback-note",children:i("feedback.truncated")}),U&&t.jsx("p",{className:"feedback-note",children:i("feedback.privacy")})]}),de&&t.jsx("p",{className:"feedback-warning",role:"alert",children:i("feedback.tooLarge")}),ne&&t.jsx("p",{className:"feedback-warning",role:"alert",children:i("feedback.limit",{max:wt})}),W&&t.jsx("p",{className:"feedback-warning",role:"alert",children:W})]}),t.jsxs("div",{className:"feedback-footer",children:[t.jsxs("button",{className:"btn ghost feedback-diagnose",onClick:st,disabled:T||!p.trim(),title:i("feedback.diagnoseViaChatHint"),children:[t.jsx(Ea,{size:15}),i("feedback.diagnoseViaChat")]}),t.jsx("span",{className:"grow"}),t.jsxs("button",{className:"btn primary",onClick:()=>{P()},disabled:!se,children:[T&&t.jsx(mn,{size:14,className:"spin"}),i(T?"feedback.sending":W?"feedback.retry":"feedback.submit")]})]})]})]})})};function xn(n){return Array.from(n.dataTransfer?.types??[]).includes("Files")}function ze(){const n=o=>{!xn(o)||o.defaultPrevented||(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect="none"))},s=o=>{xn(o)&&!o.defaultPrevented&&o.preventDefault()};return document.addEventListener("dragover",n),document.addEventListener("drop",s),()=>{document.removeEventListener("dragover",n),document.removeEventListener("drop",s)}}function Zn({target:n,onUnavailable:s}){const[,o]=c.useReducer(d=>d+1,0),[m,i]=c.useState(()=>({...n.params??{}})),v=c.useRef(m);v.current=m;const p=c.useRef(!1);c.useEffect(()=>Ae(o),[]),c.useEffect(()=>i({...n.params??{}}),[n]);const f=Pe(n.type);f&&(p.current=!0),c.useEffect(()=>{p.current&&!f&&s?.()},[f,s]);const w=c.useMemo(()=>({id:`floating:${n.type}`,type:n.type,loc:"main",get params(){return v.current},setTitle:d=>{document.title=d},setParams:d=>i({...d}),close:()=>s?.()}),[n.type,s]);return f?t.jsx("div",{className:"floating-plugin-view","data-view":n.type,children:t.jsx(_n,{children:t.jsx(c.Suspense,{fallback:null,children:f.factory({leaf:w,params:m})})})}):t.jsx("div",{className:"floating-panel-empty",children:"Loading panel…"})}const oi=[[390,"iPhone"],[414,"Max"],[768,"iPad"]];function ii({children:n}){const[s,o]=c.useState(390);return Fn!=="mobile"?t.jsx(t.Fragment,{children:n}):window.innerWidth<=820?t.jsx(t.Fragment,{children:n}):t.jsxs("div",{className:"sc-frame",children:[t.jsx("div",{className:"sc-bar",children:oi.map(([m,i])=>t.jsxs("button",{className:`sc-size${s===m?" on":""}`,onClick:()=>o(m),children:[i," · ",m]},m))}),t.jsx("div",{className:"sc-device",style:{width:s},children:n})]})}function ri(){js(),c.useEffect(()=>ze(),[]),c.useEffect(()=>{Cs(),wo()},[]),c.useEffect(()=>window.tangu?.onMainAction?.((d,g)=>{d==="onboarding"&&C.getState().setOnboarding(!0),d==="dev-commands"&&Es(),d==="test-notification"&&Ns(),d==="reset-layout"&&$.getState().resetLayout({undoable:!0}),d==="achievement-toast"&&Na(),d==="space-removed"&&g&&co(g),d==="chat-draft"&&g&&Xn(g),d==="chat-quote"&&g&&vo(g),d==="agents-changed"&&(C.getState().refreshAgents(),window.dispatchEvent(new Event("forsion:agents-changed"))),d==="skills-changed"&&(jt(Ct()).then(b=>C.setState({skillsList:b})).catch(()=>{}),window.dispatchEvent(new Event("forsion:skills-changed"))),d==="open-agents"&&gn(C.getState().defaultAgentSlug||""),d==="open-agent"&&g&&/^[a-z0-9][a-z0-9-]{0,63}$/.test(g)&&gn(g)}),[]);const n=nt(),s=Ia();Is();const o=C(Bn(d=>({sessions:d.sessions,archivedSessions:d.archivedSessions,activeId:d.activeId,settingsOpen:d.settingsOpen,settingsTab:d.settingsTab,settingsSkillKey:d.settingsSkillKey,settingsNonce:d.settingsNonce,onboarding:d.onboarding,feedbackOpen:d.feedbackOpen,marketOpen:d.marketOpen,closeMarket:d.closeMarket,achievementsOpen:d.achievementsOpen,cfg:d.cfg,tr:d.tr,openSettings:d.openSettings,closeSettings:d.closeSettings,patchConfig:d.patchConfig,connect:d.connect,setOnboarding:d.setOnboarding,closeFeedback:d.closeFeedback}))),m=o.sessions.find(d=>d.id===o.activeId)||o.archivedSessions.find(d=>d.id===o.activeId)||null,i=c.useSyncExternalStore(Ta,pn,pn),[v,p]=c.useState(!1),f=c.useRef(o.onboarding);c.useEffect(()=>{const d=f.current;if(f.current=o.onboarding,d&&!o.onboarding){p(!0);const g=setTimeout(()=>p(!1),650);return()=>clearTimeout(g)}},[o.onboarding]);const w=o.settingsOpen||o.marketOpen||o.achievementsOpen||o.feedbackOpen||!!i||o.onboarding;return t.jsxs(ii,{children:[t.jsx("div",{className:`shell-host${v?" main-enter":""}`,style:o.onboarding?{visibility:"hidden"}:void 0,children:t.jsx(Un,{dark:s.mode==="dark",soft:!!Wn(s.lang)?.manifest.panelGap,buildDefault:Tn,header:t.jsx(si,{}),footer:t.jsx(Ts,{})})}),La()&&t.jsx(Ln,{}),t.jsx(Ma,{}),t.jsx(Ra,{}),t.jsx(Hn,{}),t.jsx(mo,{}),t.jsx(Se,{children:o.settingsOpen&&t.jsx(Le,{title:o.tr("settings.title"),onClose:()=>o.closeSettings(),children:t.jsx(Mn,{open:!0,initialTab:o.settingsTab??void 0,initialSkillKey:o.settingsSkillKey??void 0,cfg:o.cfg,activeSession:m,themeLang:n.lang,themeSkin:n.skin,themeMode:n.mode,themeModePref:n.modePref,flatOn:n.flat,glassOn:n.glass,themeSeed:n.seed,onClose:()=>o.closeSettings(),onConfigChange:o.patchConfig,onThemeChange:(d,g,b)=>n.setTheme(d,g,n.bg,b),onFlatChange:n.setFlat,onGlassChange:d=>n.setGlass(d),onSeedChange:d=>n.setSeedValue(d),onReloadThemes:()=>n.reloadThemes(),onReconnect:d=>{o.connect({...o.cfg,...d||{}})},onRelaunchOnboarding:()=>{o.closeSettings();try{localStorage.removeItem(Vn)}catch{}o.setOnboarding(!0)}},o.settingsNonce)},"settings")}),t.jsx(Se,{children:o.onboarding&&t.jsx(po.div,{style:{position:"fixed",inset:0,zIndex:60,background:"var(--bg)"},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0,scale:1.06},transition:{duration:.45,ease:[.2,.8,.2,1]},children:t.jsx(Da,{themeLang:n.lang,themeSkin:n.skin,themeMode:n.mode,themeModePref:n.modePref,themeSeed:n.seed,onThemeChange:(d,g,b)=>n.setTheme(d,g,n.bg,b),onSeedChange:d=>n.setSeedValue(d),onReconnect:()=>{window.tangu?.getConfig().then(d=>{const g={backendUrl:d.backendUrl,token:d.token,modelId:d.modelId};C.setState({cfg:g,desktopMode:"managed"}),C.getState().connect(g)})},onFinish:()=>{o.setOnboarding(!1),window.tangu?.getConfig().then(d=>{const g={backendUrl:d.backendUrl,token:d.token,modelId:d.modelId};C.setState({cfg:g,homeDir:d.homeDir,defaultWsDir:d.defaultWorkspaceDir||""}),C.getState().connect(g)})}})},"onboarding")}),t.jsx(Se,{children:o.marketOpen&&t.jsx(Le,{title:o.tr("market.title"),onClose:()=>o.closeMarket(),children:t.jsx(Rn,{onClose:()=>o.closeMarket()})},"market")}),t.jsx(Se,{children:o.achievementsOpen&&t.jsx(Le,{title:o.tr("achievements.title"),onClose:()=>C.getState().closeAchievements(),children:t.jsx(Dn,{onClose:()=>C.getState().closeAchievements()})},"achievements")}),t.jsx(Se,{children:o.feedbackOpen&&t.jsx(Le,{compact:!0,title:o.tr("feedback.title"),onClose:()=>o.closeFeedback(),children:t.jsx(Gn,{surface:"panel",cfg:o.cfg,activeSession:m,onClose:()=>o.closeFeedback()})},"feedback")}),t.jsx(Ls,{}),t.jsx(Se,{children:i?.view&&t.jsx(Le,{title:i.title,onClose:fn,children:t.jsx(Zn,{target:i.view,onUnavailable:fn})},i.id)}),!w&&t.jsx(Pn,{}),!w&&t.jsx(Ms,{onOpen:()=>C.getState().openAchievements()}),!o.onboarding&&t.jsx(Rs,{})]})}Qe({"chatpreview.msg.ask":{zh:"帮我把 LCL 的 hash 路由分支理一下,再决定要不要抽成表。",en:"Walk me through the hash route branches in LCL, then decide whether to pull them into a table."},"chatpreview.msg.reasoning":{zh:"先看 main.tsx 的 hash 分支顺序,确认 #/aion 与 #/tangu 不会被前面的 frame 分支吞掉,再决定是否抽一个 routes 表。整体规模还小,优先可读性。",en:"Start with the order of the hash branches in main.tsx, confirm that #/aion and #/tangu are not swallowed by the earlier frame branch, then decide whether to extract a routes table. The whole thing is still small, so readability wins."},"chatpreview.todo.read":{zh:"读 main.tsx 路由分支",en:"Read the route branches in main.tsx"},"chatpreview.todo.addRoute":{zh:"加 #/tangu 分支",en:"Add the #/tangu branch"},"chatpreview.todo.navLink":{zh:"补 Navigator 链接",en:"Add the Navigator link"},"chatpreview.todo.build":{zh:"跑 tsc / build",en:"Run tsc / build"},"chatpreview.plan":{zh:`1. 检查 hash 分支顺序
|
|
15
|
+
2. 补路由与导航
|
|
16
|
+
3. 运行 typecheck / build`,en:`1. Check the order of the hash branches
|
|
17
|
+
2. Add the route and the navigation link
|
|
18
|
+
3. Run typecheck / build`},"chatpreview.msg.answer":{zh:"看完了。当前是 5 条 `if (route.view === …)` 顺序分支,`frame` 在前、`aion/tangu` 在后,互不吞。\n\n```ts\nif (route.view === 'frame') return <Frame/>\nif (route.view === 'tangu') return <Tangu/>\n```\n\n规模还小,**暂不必抽表**——超过 ~8 条再说。",en:"Had a look. Right now there are 5 sequential `if (route.view === …)` branches — `frame` first, then `aion/tangu` — and none of them swallows another.\n\n```ts\nif (route.view === 'frame') return <Frame/>\nif (route.view === 'tangu') return <Tangu/>\n```\n\nAt this size a table is **not worth extracting yet** — revisit past ~8 branches."},"chatpreview.msg.buildFirst":{zh:"我先跑一遍构建确认。",en:"Let me run a build first to confirm."},"chatpreview.plan.question":{zh:"计划已就绪。是否批准?",en:"The plan is ready. Approve it?"},"chatpreview.inquiry.question":{zh:"路由是抽成表驱动,还是保持 if 分支?",en:"Should routing become table-driven, or stay as if branches?"},"chatpreview.inquiry.optTable":{zh:"抽成 routes 表",en:"Extract a routes table"},"chatpreview.inquiry.optIf":{zh:"保持 if 分支",en:"Keep the if branches"},"chatpreview.session.routing":{zh:"重构 LCL 路由层",en:"Refactor the LCL routing layer"},"chatpreview.session.weekly":{zh:"周报整理",en:"Compile the weekly report"},"chatpreview.session.scraper":{zh:"爬虫脚本调试",en:"Debug the scraper script"},"chatpreview.session.design":{zh:"设计系统对照",en:"Design system comparison"}});function ci(n){const s=Date.now()-6e4;return[{id:"u1",role:"user",content:n("chatpreview.msg.ask"),attachments:[{name:"routes.md",mimeType:"text/markdown",data:"",size:128}],status:"done",timestamp:s+1},{id:"a1",role:"assistant",agentName:"Tangu",status:"done",timestamp:s+2,systemPrompt:"You are Tangu, a coding agent. Keep changes scoped and verify them.",reasoning:n("chatpreview.msg.reasoning"),toolEvents:[{id:"t1",name:"read_file",arguments:"src/main.tsx",done:!0,elapsedMs:400},{id:"t2",name:"run_shell",arguments:"npx tsc --noEmit",done:!0,isError:!0,elapsedMs:1200}],todos:[{status:"completed",content:n("chatpreview.todo.read")},{status:"in_progress",content:n("chatpreview.todo.addRoute")},{status:"pending",content:n("chatpreview.todo.navLink")},{status:"pending",content:n("chatpreview.todo.build")}],planProposal:n("chatpreview.plan"),inquiries:[{inquiryId:"iqp",runId:"r1",question:n("chatpreview.plan.question"),options:[],status:"pending",kind:"plan"}],content:n("chatpreview.msg.answer")},{id:"a2",role:"assistant",agentName:"Tangu",status:"done",timestamp:s+3,content:n("chatpreview.msg.buildFirst"),approvals:[{approvalId:"ap1",runId:"r1",name:"run_bash",arguments:JSON.stringify({command:"npm run build && npx tsc --noEmit"}),preview:"$ npm run build && npx tsc --noEmit",status:"pending",reason:{kind:"mode",mode:"auto-edit"}},{approvalId:"ap2",runId:"r1",name:"write_file",arguments:JSON.stringify({path:"/etc/hosts",content:`127.0.0.1 tangu.local
|
|
19
|
+
`}),preview:"⚠ Write outside the workspace · write /etc/hosts (22 chars)",status:"pending",reason:{kind:"escalate",mode:"auto-edit"}}]},{id:"a3",role:"assistant",agentName:"Tangu",status:"done",timestamp:s+4,content:"",inquiries:[{inquiryId:"iq1",runId:"r1",question:n("chatpreview.inquiry.question"),options:[n("chatpreview.inquiry.optTable"),n("chatpreview.inquiry.optIf")],status:"pending"}]}]}const yn=new Date().toISOString(),li=["chatpreview.session.routing","chatpreview.session.weekly","chatpreview.session.scraper","chatpreview.session.design"];function di(n){return li.map((s,o)=>({id:`s${o+1}`,title:n(s),model_id:null,archived:!1,emoji:null,agent_config:null,project_path:"/tangu",project_name:n("app.defaultWorkspace"),created_at:yn,updated_at:yn}))}function ui(n){return[{key:"__cloud__",name:n("app.cloudWorkspace"),kind:"cloud",path:null,system:!0},{key:"/tangu",name:n("app.defaultWorkspace"),kind:"local",path:"/tangu",system:!0}]}const Sn={backendUrl:"http://localhost:8787",token:"",modelId:""};function mi(){const{t:n}=ge(),[s,o]=c.useState(!1),[m,i]=c.useState(""),v=c.useRef(null),p=c.useMemo(()=>ci(n),[n]),f=c.useMemo(()=>di(n),[n]),w=c.useMemo(()=>ui(n),[n]);return t.jsxs("div",{className:"t2-preview-shell",children:[t.jsx("div",{className:"t2-preview-side",children:t.jsx(Eo,{collapsed:!1,sessions:f,archivedSessions:[],activeId:"s1",runningIds:new Set(["s2"]),unreadIds:new Set(["s3"]),cfg:Sn,modelId:"",activeSession:f[0],workspaces:w,onSelect:()=>{},onNewInWorkspace:()=>{},onAddWorkspace:()=>{},onRenameWorkspace:()=>{},onRemoveWorkspace:()=>{},onRename:()=>{},onArchive:()=>{},onDelete:()=>{},onOpenSettings:()=>{},showSpecial:!0,onNewChat:()=>o(!0),onOpenWorkspace:()=>{}})}),t.jsxs("div",{className:"t2-preview-main t2-chat-view",children:[t.jsxs("div",{className:"t2-toolbar",children:[t.jsx("div",{className:"t2-toolbar-title",children:f[0].title}),t.jsx("span",{className:"t2-toolbar-grow"}),t.jsx("button",{className:"t2-pill",onClick:()=>o(!1),style:{fontWeight:s?400:600},children:n("workbench.chat")}),t.jsx("button",{className:"t2-pill",onClick:()=>o(!0),style:{fontWeight:s?600:400},children:n("chat.emptyHint")}),m&&t.jsx("span",{className:"t2-toolbar-pill","data-preview-action":!0,children:m})]}),s?t.jsx(ko,{}):t.jsx("div",{className:"t2-stream",ref:v,children:t.jsx("div",{className:"t2-stream-inner","data-has-messages":"",children:p.map(d=>t.jsx(xo,{msg:d},d.id))})}),t.jsx(No,{approvalTray:s?void 0:t.jsx(yo,{items:So(p),onDecide:(d,g,b,h)=>(i(`approval:${b}:${String(h?.command||"")}`),!1),onAnswer:(d,g,b)=>(i(`inquiry:${b}`),!1)}),disabled:!1,running:!1,execConfig:{execMode:"host",approvalMode:"auto-edit"},models:null,modelId:"",onModelChange:()=>{},planMode:!1,onPlanModeChange:()=>{},onExecConfigChange:()=>{},onSend:async()=>!0,onStop:()=>{},contextWindow:2e5,ctxTokens:84e3,sessionTokens:12e3,onCompact:()=>{}})]}),t.jsxs("div",{className:"t2-preview-right",children:[t.jsx("div",{className:"t2-preview-right-title",children:n("panel.tab.toc")}),t.jsx(Io,{view:"toc",cfg:Sn,sessionId:"s1",sessionConfig:{},running:!1,messages:s?[]:p,chatScrollRef:v,onToast:()=>{},onOpenPreview:()=>{},subChats:[]})]})]})}function pi(){$.getState().openView("home",{},"main")}Qe({"spaceWindow.stuck":{zh:"这个 Space 还没准备好。它所属的插件可能还在加载,或已被停用、卸载。准备好后这里会自动打开,也可以直接关掉这扇窗。",en:"This Space is not ready yet. Its plugin may still be loading, or may have been disabled or removed. It will open here once it is ready, or you can close this window."}});const jn=6e3;function fi(){const[n,s]=c.useState(hn?"wait":"plain");return c.useEffect(()=>{const o=hn;if(!o)return;const m=Date.now();let i=null,v=!1;const p=()=>{const g=oe.getState().spaces.find(h=>h.id===o);if(i){g!==i&&!v&&(v=!0,location.reload());return}if(!g||!Aa()&&Date.now()-m<jn)return;i=g;const b=$.getState();b.setSidebarDefaults(g.sidebarDefaults),b.setSideProfile(g.id,g.resizableSides??{},g.sideDefaultScale,g.bottomSpan),b.setPinned(g.pinned),document.title=je(g.name),s("ready")};p();const f=oe.subscribe(p),w=Ae(p),d=window.setTimeout(()=>{p(),i||s("stuck")},jn+50);return()=>{f(),w(),window.clearTimeout(d)}},[]),n}function hi(){const{t:n}=ge(),s=nt(),o=fi();c.useEffect(()=>{C.getState().setTr((i,v)=>n(i,v))},[n]),c.useEffect(()=>{C.getState().boot()},[]),c.useEffect(()=>ze(),[]),c.useEffect(()=>window.tangu?.onMainAction?.(i=>{i==="agents-changed"&&(C.getState().refreshAgents(),window.dispatchEvent(new Event("forsion:agents-changed"))),i==="skills-changed"&&(jt(Ct()).then(v=>C.setState({skillsList:v})).catch(()=>{}),window.dispatchEvent(new Event("forsion:skills-changed")))}),[]),c.useEffect(()=>{window.tangu?.detachedReady?.(Pa()).then(i=>{if(!i?.length)return;const v=$.getState();for(const p of i)v.openView(p.type,p.params??{},"main")})},[]);const m=(()=>{try{return window.tangu?.platform==="darwin"}catch{return!1}})();return o==="wait"||o==="stuck"?t.jsxs("div",{className:"shell-host",style:{display:"flex",flexDirection:"column"},children:[m&&t.jsx("div",{style:{height:38,flex:"0 0 auto",WebkitAppRegion:"drag"}}),o==="stuck"&&t.jsx("div",{className:"space-window-wait",role:"status",style:{flex:1,display:"grid",placeItems:"center",padding:32,textAlign:"center",color:"var(--text-muted)",fontSize:"var(--ui-font-body, 13px)",lineHeight:1.6},children:t.jsx("span",{style:{maxWidth:420},children:n("spaceWindow.stuck")})})]}):t.jsxs(t.Fragment,{children:[t.jsx("div",{className:"shell-host",children:t.jsx(Un,{noRibbon:!0,dark:s.mode==="dark",soft:!!Wn(s.lang)?.manifest.panelGap,buildDefault:o==="ready"?Tn:pi})}),window.amadeus&&t.jsx(Ln,{}),t.jsx(Hn,{})]})}Qe({"dock.pickTitle":{zh:"贴到哪个窗口旁边",en:"Dock beside a window"},"dock.pickHint":{zh:"选一个窗口,对话面板会贴在它旁边,一起移动和缩放。",en:"Pick a window. The chat panel docks beside it and moves and resizes with it."},"dock.loading":{zh:"正在查找窗口…",en:"Looking for windows…"},"dock.empty":{zh:"屏幕上没有可以贴靠的窗口。",en:"No windows on screen to dock beside."},"dock.refresh":{zh:"刷新",en:"Refresh"},"dock.close":{zh:"关闭",en:"Close"},"dock.selectedIn":{zh:"在 {app} 里选中的:",en:"Selected in {app}:"},"dock.err.helper_not_installed":{zh:"还没装好「电脑操作」的本机 helper。让 Agent 用一次电脑操作,它会自动装好。",en:"The Computer Use helper is not installed yet. Ask the agent to use Computer Use once and it installs itself."},"dock.err.helper_not_running":{zh:"「电脑操作」的本机 helper 没有启动。",en:"The Computer Use helper is not running."},"dock.err.unsupported_helper":{zh:"本机的「电脑操作」helper 是旧版,不支持侧边拼接。让 Agent 用一次电脑操作,它会自动更新。",en:"The Computer Use helper is out of date and cannot dock. Ask the agent to use Computer Use once and it updates itself."},"dock.err.window_gone":{zh:"这个窗口已经关了。",en:"That window has been closed."},"dock.err.generic":{zh:"没能贴过去({code})。",en:"Could not dock ({code})."}});const gi=new Set(["helper_not_installed","helper_not_running","unsupported_helper","window_gone"]);function bi(n,s,o){return n?.text?n.text:n?.items?.length?[o("dock.selectedIn",{app:s}),...n.items.map(m=>`- ${m}`)].join(`
|
|
20
|
+
`):""}function wi(){const{t:n}=ge(),[s,o]=c.useState(!1),[m,i]=c.useState(null);c.useEffect(()=>{C.getState().setTr((p,f)=>n(p,f))},[n]),c.useEffect(()=>{C.getState().boot().finally(()=>{C.setState({sessionMode:"work"}),o(!0)});const p=window.tangu?.onAppDockState?.(f=>i(f.target));return window.tangu?.appDockReady?.().then(f=>i(f.target)),()=>p?.()},[]),c.useEffect(()=>{window.amadeus&&Et()},[]),c.useEffect(()=>ze(),[]),c.useEffect(()=>{if(!s||!m)return;const p={type:"chat",params:{miniSurface:!0,appRef:m}};ki({view:p,mainView:{type:"chat"}}),C.getState().setActiveId(null),$.getState().openView("chat",p.params,"main")},[s,m?.pid,m?.windowId]);const v=c.useRef(n);return v.current=n,c.useEffect(()=>{if(!m)return;let p="";const f=async()=>{const w=bi(await window.tangu?.appDockSelection?.(),m.app,v.current);!w||w===p||(p=w,C.getState().setPendingChatQuote("chat",w))};return window.addEventListener("focus",f),()=>window.removeEventListener("focus",f)},[m?.pid,m?.windowId]),m?t.jsx(Kn,{buildDefault:()=>{},direct:{title:m.app,view:{type:"chat",params:{miniSurface:!0,appRef:m}},mainView:{type:"chat"}}}):t.jsx(vi,{})}function vi(){const{t:n}=ge(),[s,o]=c.useState(null),[m,i]=c.useState(""),v=async()=>{o(null),i("");const w=await window.tangu?.appDockCandidates?.();o(w?.windows??[]),w?.error&&i(w.error)};c.useEffect(()=>{v()},[]);const p=async w=>{i("");const d=await window.tangu?.appDockAttach?.({pid:w.pid,windowId:w.windowId,app:w.app,bundleId:w.bundleId,title:w.title});d&&!d.ok&&d.error!=="superseded"&&i(d.error||"unavailable")},f=m?gi.has(m)?n(`dock.err.${m}`):n("dock.err.generic",{code:m}):"";return t.jsxs("div",{className:"mini-card-shell","data-space":"dock",children:[t.jsxs("header",{className:"mini-card-chrome",children:[t.jsx("div",{className:"mini-card-drag-title dock-picker-title",children:n("dock.pickTitle")}),t.jsx("button",{className:"mini-card-action","aria-label":n("dock.refresh"),title:n("dock.refresh"),onClick:()=>{v()},children:t.jsx($n,{size:15})}),t.jsx("button",{className:"mini-card-action mini-card-close","aria-label":n("dock.close"),onClick:()=>window.tangu?.closeSelf?.(),children:t.jsx(yt,{size:15})})]}),t.jsxs("main",{className:"mini-card-main dock-picker",children:[t.jsx("p",{className:"dock-picker-hint",children:n("dock.pickHint")}),f&&t.jsx("p",{className:"dock-picker-error",role:"alert",children:f}),s===null?t.jsx("div",{className:"mini-panel-empty",children:n("dock.loading")}):s.length===0?!f&&t.jsx("div",{className:"mini-panel-empty",children:n("dock.empty")}):t.jsx("div",{className:"dock-picker-list",children:s.map(w=>t.jsxs("button",{className:"mini-card-row dock-picker-row","data-window-id":w.windowId,onClick:()=>{p(w)},children:[t.jsx(za,{size:15}),t.jsxs("span",{className:"mini-card-row-label",children:[t.jsx("span",{className:"dock-picker-app",children:w.app}),w.title&&t.jsx("span",{className:"dock-picker-window",children:w.title})]})]},`${w.pid}:${w.windowId}`))})]})]})}let X=null;function ki(n){X=n}Je()==="mini"&&(Fa(async n=>{n.type==="amadeus-editor"&&await $a();const s={...n.params};delete s.miniSurface,n.type==="chat"&&(s.sessionId||=C.getState().activeId||void 0,s.followActive=!s.sessionId),window.tangu?.showMainPanel?.({...n,params:s})}),_a(n=>{if(X?.view)return n.type===X.view.type?n:n.type===(X.mainView?.type||X.view.type)?{type:X.view.type,params:{...X.view.params,...n.params}}:(Ze({...n}),null);const s=St();if(!s||!tt(s))return null;const o=s.mini;return n.type===o.view.type?n:n.type===o.mainView.type?{type:o.view.type,params:{...o.view.params,...n.params}}:(Ze({...n}),null)}));function xi(){const n=St();n&&tt(n)&&$.getState().openView(n.mini.view.type,n.mini.view.params??{},"main")}function yi(){return Oa()?t.jsx(wi,{}):t.jsx(Si,{})}function Si(){const{t:n}=ge(),[s,o]=c.useState(null);return c.useEffect(()=>{C.getState().setTr((m,i)=>n(m,i))},[n]),c.useEffect(()=>{let m=!1,i=!1;const v=new URLSearchParams(location.search);let p=v.get("sessionId")?{sessionId:v.get("sessionId")}:null;const f=()=>{if(!m||!p)return;if(p.view){const N=p.view;if(!Pe(N.type)){i&&window.tangu?.closeSelf?.();return}i=!0;const S=p;p=null,X=S,o(S),$.getState().openView(N.type,{...N.params,...S.params},"main");return}const b=p.spaceId||(p.sessionId?"tangu":void 0),h=oe.getState().spaces.find(N=>N.id===b);if(!h||!tt(h))return;const y=p;p=null,X=null,o(null),et(h.id);const I={...h.mini.view.params,...y.params,...y.sessionId?{sessionId:y.sessionId,followActive:!1}:{}};$.getState().openView(h.mini.view.type,I,"main"),y.sessionId&&C.getState().setActiveId(y.sessionId)},w=window.tangu?.onMiniTarget?.(b=>{p=b,f()});window.tangu?.miniReady?.();const d=oe.subscribe(f),g=Ae(f);return C.getState().boot().finally(()=>{m=!0,f()}),()=>{w?.(),d(),g(),m=!1,X=null}},[]),c.useEffect(()=>{window.amadeus&&Et()},[]),c.useEffect(()=>ze(),[]),t.jsx(Kn,{buildDefault:xi,resizable:!!window.tangu?.miniResize&&!new URLSearchParams(location.search).has("transient"),direct:s?.view?{title:s.title,view:s.view,mainView:s.mainView??s.view}:null})}const ji={settings:"settings.title",market:"market.title",achievements:"achievements.title",feedback:"feedback.title",btw:"btw.title"};function Ci(n,s){return n.builtin?s(ji[n.builtin]):n.title}function Ei(){const{t:n}=ge(),s=nt(),[o,m]=c.useState(null),i=C(Bn(y=>({cfg:y.cfg,cfgLoaded:y.cfgLoaded,closeSettings:y.closeSettings,closeMarket:y.closeMarket,closeAchievements:y.closeAchievements,closeFeedback:y.closeFeedback,patchConfig:y.patchConfig,connect:y.connect}))),v=o?.params?.session?.id?o.params.session:null,p=()=>window.tangu?.closeSelf?.(),f=o?.builtin==="btw"?jo(o.params):null,w=o?Ci(o,n):"";if(c.useEffect(()=>{o?.builtin&&w&&(document.title=w)},[o?.builtin,w]),c.useEffect(()=>{C.getState().setTr((y,I)=>n(y,I))},[n]),c.useEffect(()=>{C.getState().boot()},[]),c.useEffect(()=>{window.amadeus&&Et()},[]),c.useEffect(()=>ze(),[]),c.useEffect(()=>window.tangu?.onMainAction?.(y=>{y==="agents-changed"&&(C.getState().refreshAgents(),window.dispatchEvent(new Event("forsion:agents-changed"))),y==="skills-changed"&&(jt(Ct()).then(I=>C.setState({skillsList:I})).catch(()=>{}),window.dispatchEvent(new Event("forsion:skills-changed")))}),[]),c.useEffect(()=>{const y=Ba(),I=window.tangu?.onFloatingTarget?.(m);return window.tangu?.floatingReady?.(y).then(N=>{N&&m(N)}),()=>I?.()},[]),c.useEffect(()=>{o?.builtin==="feedback"&&typeof o.params?.description=="string"&&C.setState({feedbackDraft:o.params.description})},[o]),!o)return t.jsx("div",{className:"floating-native-root"});const d=()=>{i.closeSettings(),p()},g=()=>{i.closeMarket(),p()},b=()=>{i.closeAchievements(),p()},h=()=>{i.closeFeedback(),p()};return t.jsxs("div",{className:"floating-native-root",children:[window.tangu?.platform==="darwin"&&t.jsx("header",{className:"floating-native-chrome",children:t.jsx("span",{title:w,children:w})}),t.jsxs("main",{className:"floating-native-content",children:[o.builtin==="settings"&&t.jsx(Mn,{open:!0,initialTab:typeof o.params?.tab=="string"?o.params.tab:void 0,initialSkillKey:typeof o.params?.skillKey=="string"?o.params.skillKey:void 0,cfg:i.cfg,activeSession:v,themeLang:s.lang,themeSkin:s.skin,themeMode:s.mode,themeModePref:s.modePref,flatOn:s.flat,glassOn:s.glass,themeSeed:s.seed,onClose:d,onConfigChange:i.patchConfig,onThemeChange:(y,I,N)=>s.setTheme(y,I,s.bg,N),onFlatChange:s.setFlat,onGlassChange:s.setGlass,onSeedChange:s.setSeedValue,onReloadThemes:s.reloadThemes,onReconnect:y=>{i.connect({...i.cfg,...y||{}})},onRelaunchOnboarding:()=>{try{localStorage.removeItem(Vn)}catch{}window.tangu?.requestMainAction?.("onboarding"),p()}},JSON.stringify(o.params??{})),o.builtin==="market"&&t.jsx(Rn,{initialQuery:typeof o.params?.q=="string"?o.params.q:void 0,onClose:g},String(o.params?.q??"")),o.builtin==="achievements"&&t.jsx(Dn,{onClose:b}),o.builtin==="feedback"&&i.cfgLoaded&&t.jsx(Gn,{surface:"panel",cfg:i.cfg,activeSession:v,onClose:h},v?.id||""),o.builtin==="btw"&&i.cfgLoaded&&f&&t.jsx(Ds,{seed:f,onClose:p}),o.view&&t.jsx(Zn,{target:o.view,onUnavailable:p})]}),(o.builtin==="settings"||o.builtin==="market")&&t.jsx(Pn,{})]})}let he=null;function Cn(n){if(!n){he&&(he.style.display="none");return}he||(he=document.createElement("div"),Object.assign(he.style,{position:"fixed",inset:"0",pointerEvents:"none",zIndex:"99998",boxSizing:"border-box",border:"3px solid var(--accent, #4d8794)",background:"color-mix(in srgb, var(--accent, #4d8794) 8%, transparent)"}),document.body.appendChild(he)),he.style.display="block"}function Ni(){const n=window.tangu;if(n?.openDetached){if(Je()==="main"){let s="";const o=()=>{const p=C.getState(),f=p.activeId,w={sessionId:f,runId:f?p.runningBySession[f]??null:null},d=JSON.stringify(w);d!==s&&(s=d,n.reportMiniSession?.(w))};C.subscribe(o),o();let m=null;const i=()=>{if(!$.getState().api||!m||!Pe(m.type))return;const f=m;m=null,f.spaceId&&et(f.spaceId);const w=$.getState().openView(f.type,f.params??{},"main");w&&f.params&&w.setParams({...w.params,...f.params})};n.onMainPanelTarget?.(p=>{m=p,i()}),Ae(i);let v=!1;$.subscribe(p=>{p.api&&(v||(v=!0,n.mainPanelReady?.()),i())})}Wa({ribbonPointerDrag:n.platform==="win32",cursorScreenPoint:n.cursorScreenPoint,detach:(s,o)=>{n.openDetached?.(s,o)},openSpace:(s,o)=>{Je()==="main"&&Va()===s&&oe.getState().activeSpaceId===s&&$.getState().saveNamed(qa(s)),n.openDetached?.([],o,{space:s})},dragUpdate:(s,o,m)=>n.dragUpdate?.(s,o,m),drop:async(s,o,m)=>(await n.dropView?.(s,o,m))?.routed??!1}),n.onAcceptView?.(s=>{Cn(null),$.getState().openView(s.type,s.params??{},"main")}),n.onDragPreview?.(s=>Cn(s))}}function Ii(){const n=window.tangu;if(!n?.reportRunningSessions)return;const s=o=>n.reportRunningSessions(Object.keys(o).length);s(C.getState().runningBySession),C.subscribe((o,m)=>{o.runningBySession!==m.runningBySession&&s(o.runningBySession)})}const En=n=>To(n).toLowerCase(),Jn=(n,s)=>n.configBySession[s]?.cwd||n.sessions.find(o=>o.id===s)?.project_path||"",Qn=(n,s)=>Object.keys(n.runningBySession).some(o=>En(Jn(n,o))===En(s));function Ti(){const n=window.tangu;if(!(!n?.codeStudioGitCommit||!n.codeStudioGitStatus||!n.productsIsCreation))return C.subscribe((s,o)=>{if(s.runningBySession!==o.runningBySession)for(const m of Object.keys(o.runningBySession)){if(s.runningBySession[m])continue;const i=Jn(s,m);!i||Qn(s,i)||Li(i,m)}})}async function Li(n,s){try{if(!await window.tangu.productsIsCreation(n))return;const o=await window.tangu.codeStudioGitStatus(n);if(!(o?.auto??o?.writable)||Qn(C.getState(),n))return;const m=Ps(C.getState().messagesBySession[s]||[]);await window.tangu.codeStudioGitCommit(n,{name:m,auto:!0,untitled:Nn("studio.history.untitled")})}catch(o){console.warn("[creations] 自动存版本失败",o)}}function Mi(){if(!window.tangu?.onAuthWillChange)return()=>{};let n=!1,s=null,o=!1,m=0,i=Promise.resolve(),v=!1;const p=()=>{s&&(s.inert=o),s=null},f=window.tangu.onAuthWillChange(async()=>{const d=++m;s||(s=document.body,o=s?.inert??!1,s&&(s.inert=!0));try{if(await i,d!==m||v||!window.amadeus)return;const[{flushAllScopes:g,resetAllScopeDocs:b,usePageStore:h},{useDbStore:y},{useDrawStore:I},N]=await Promise.all([Te(()=>import("./appStore-affnJoin.js").then(S=>S.sn),__vite__mapDeps([0,1,2,3,4,5]),import.meta.url),Te(()=>import("./appStore-affnJoin.js").then(S=>S.so),__vite__mapDeps([0,1,2,3,4,5]),import.meta.url),Te(()=>import("./appStore-affnJoin.js").then(S=>S.sq),__vite__mapDeps([0,1,2,3,4,5]),import.meta.url),Te(()=>import("./index-BYUntVIZ.js").then(S=>S.cA),[],import.meta.url)]);if(await Promise.all([g(!0),y.getState().flushAll(!0),I.getState().flushAll(!0)]),d!==m)return;n=h.getState().vaultSide==="cloud",n&&(N.retireAllUnifiedScopes(),b(),h.setState({vaultRoot:null,pages:[],folders:[],files:[],icons:{}}))}catch(g){throw d===m&&p(),g}}),w=window.tangu.onAuthChanged?.(()=>{const d=++m;if(!n){i.finally(()=>{d===m&&p()});return}n=!1,i=i.then(async()=>{const{usePageStore:g}=await Te(async()=>{const{usePageStore:b}=await import("./appStore-affnJoin.js").then(h=>h.sn);return{usePageStore:b}},__vite__mapDeps([0,1,2,3,4,5]),import.meta.url);v||(await g.getState().restoreVault(),await g.getState().initVaultSide())}).catch(g=>console.error("[auth] Cannot restore vault after account change:",g)).finally(()=>{d===m&&p()})});return()=>{v=!0,++m,f(),w?.(),p()}}Mi();window.addEventListener("error",n=>{console.error("[tangu] window error:",n.error||n.message)});window.addEventListener("unhandledrejection",n=>{console.error("[tangu] unhandledrejection:",n.reason)});const Ri=(()=>{try{return location.hash==="#preview"}catch{return!1}})(),Ge=Je();try{document.documentElement.dataset.window=Ge}catch{}try{document.documentElement.lang=gs()==="zh"?"zh-CN":"en"}catch{}try{window.tangu?.platform==="darwin"&&(document.documentElement.dataset.platform="mac")}catch{}let es,ts=null;try{es=localStorage.getItem("forsion_theme_seed")||void 0}catch{}try{ts=localStorage.getItem("forsion_theme_lang")}catch{}try{Ha(Ya(),Ua(),Ka(),Xa(),{customColor:es}),Ga(),document.documentElement.style.removeProperty("background"),nt.getState().initThemes(ts),C.getState().setTr(Nn),As(),Ni(),Ii(),Ti(),Za(),zs(),Ja()}catch(n){console.error("[tangu] init failed, continue to mount:",n),Qa("init",n)}ws.createRoot(document.getElementById("root")).render(t.jsx(bs,{children:t.jsx(Co,{children:Ri?t.jsx(mi,{}):Ge==="mini"?t.jsx(yi,{}):Ge==="floating"?t.jsx(Ei,{}):Ge==="detached"?t.jsx(hi,{}):t.jsx(ri,{})})}));
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{U as z,W as A,I as O,X as H,j as b,M as W,u as V,d as j,r as F}from"./index-BYUntVIZ.js";import{n9 as I,na as B,nb as _,gd as T}from"./appStore-affnJoin.js";import{P as N}from"./MarkdownBlock-BHpDy2qQ.js";import"./nativeDownload-Udrv_tmU.js";import"./ipc-D7yENkjV.js";import"./client-BqhpYbYL.js";import"./index-Y2kzYlZq.js";import"./linkFollow-Msu1XH9v.js";import"./emoji-BPdA62d7.js";import"./listFold-CKxjyY5_.js";import"./book-open-CcXCToyx.js";const G=z().use(A).use(O,{singleTilde:!1}).use(H,["yaml"]).use(I).use(B,{singleTilde:!1}),o=t=>String(t??"").replace(/[&<>"']/g,m=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[m]);function M(t,m=!1){if(!t||/[\u0000-\u0020\u007f\\]/.test(t)||t.startsWith("//"))return null;if(t.startsWith("/")||t.startsWith("#"))return t;try{const l=new URL(t);if(l.protocol==="https:"||l.protocol==="http:"||!m&&l.protocol==="mailto:")return l.href}catch{}return!t.includes(":")&&!t.startsWith(".")?t:null}function C(t){return t.value??(t.children??[]).map(C).join("")}function P(t){return t.type!=="paragraph"?null:/^!\[\[([^\]\n]+)\]\]$/.exec(C(t).trim())?.[1]?.replace(/\|\d+$/,"")??null}function X(t){return t.type==="paragraph"&&t.children?.length===1&&t.children[0].type==="image"?t.children[0]:null}function D(t,m={}){const l=G.parse(t),c=m.locale==="zh",d=(e,n=!1)=>{const r=M(e,n);if(!r||!m.baseUrl||r.startsWith("#"))return r;try{return M(new URL(r,m.baseUrl).href,n)}catch{return r}};let v=!0;const $=()=>{const e=!!m.priorityFirstImage&&v;return v=!1,e?'loading="eager" fetchpriority="high"':'loading="lazy"'},s=new Map((l.children??[]).filter(e=>e.type==="definition").map(e=>[e.identifier,e]));let f=0;const h=e=>(e.children??[]).map(i).join(""),y=(e,n)=>{const r=_(e),a=d(r?.provider==="Bilibili"&&/^BV[\w]{10}$/i.test(e.trim())?"https://www.bilibili.com/video/"+e.trim():e,!0);if(!a)return null;let g=a;try{g=new URL(a,"https://forsion.example").pathname}catch{}const x=/\.(mp4|webm|mov|m4v|ogv)$/i.test(g),E=/\.(mp3|m4a|ogg|wav|flac)$/i.test(g);if(!r&&!x&&!E)return null;const q=n?.alt||r?.provider||(c?E?"音频":"视频演示":E?"Audio":"Video demo"),L=n?.url?d(n.url,!0):null,w=/^(\d{1,4})[:/](\d{1,4})$/.exec(n?.title||""),R=w&&+w[1]>0&&+w[2]>0?` style="aspect-ratio:${+w[1]}/${+w[2]}"`:"",U=L?`<img src="${o(L)}" alt="${o(q)}" ${$()} decoding="async">`:`<div class="md-media-placeholder"><span>${o(q)}</span></div>`;return`<figure class="md-media" data-amadeus-media="${r?"platform":E?"audio":"video"}" data-src="${o(r?.src||a)}"><div class="md-media-stage${L?" has-poster":""}"${R}>${U}</div><figcaption><span>${o(q)}</span><button type="button" class="play-button">${c?"播放":"Play"}${r?` · ${r.provider}`:""}</button><a href="${o(a)}" target="_blank" rel="noopener noreferrer">${c?"打开原视频":"Open original"} ↗</a></figcaption><p class="md-media-error" role="status" hidden>${c?"暂时无法播放,请打开原视频。":"Playback is unavailable. Open the original video."}</p></figure>`};function i(e){const n=()=>h(e);switch(e.type){case"text":return o(e.value);case"strong":return`<strong>${n()}</strong>`;case"emphasis":return`<em>${n()}</em>`;case"delete":return`<del>${n()}</del>`;case"inlineCode":return`<code>${o(e.value)}</code>`;case"break":return"<br>";case"heading":{const r=Math.min(6,(e.depth??2)+(m.headingOffset??0));return`<h${r} id="${o(m.idPrefix||"md")}-${++f}">${n()}</h${r}>`}case"paragraph":{const r=P(e);if(r){const a=d(r,!0);if(a&&/\.(?:png|jpe?g|gif|webp|avif|svg)(?:[?#]|$)/i.test(a))return`<figure class="md-image"><img src="${o(a)}" alt="${o(r)}" ${$()} decoding="async"></figure>`;const g=y(r);if(g)return g;const x=d(r);return x?`<p class="md-bookmark"><a href="${o(x)}" target="_blank" rel="noopener noreferrer">${o(r)} ↗</a></p>`:`<p>${o(C(e))}</p>`}return`<p>${n()}</p>`}case"link":case"linkReference":{const r=e.url??s.get(e.identifier)?.url??"",a=d(r);return a?`<a href="${o(a)}"${/^https?:/.test(a)?' target="_blank" rel="noopener noreferrer"':""}>${n()}</a>`:n()}case"image":case"imageReference":{const r=s.get(e.identifier),a=d(e.url??r?.url??"",!0);return a?`<img src="${o(a)}" alt="${o(e.alt||"")}" ${$()} decoding="async">`:o(e.alt||"")}case"list":return`<${e.ordered?"ol":"ul"}${e.ordered&&e.start?` start="${e.start}"`:""}>${n()}</${e.ordered?"ol":"ul"}>`;case"listItem":return`<li>${e.checked!=null?`<input type="checkbox" disabled aria-label="${c?"清单项":"Checklist item"}"${e.checked?" checked":""}>`:""}${n()}</li>`;case"blockquote":{const r=e.children?.[0],a=r?.type==="paragraph"?/^\[!([\w-]+)\]([+-])?\s*(.*)/.exec(C(r)):null;if(!a)return`<blockquote>${n()}</blockquote>`;const g=(e.children??[]).slice(1).map(i).join(""),x=o(a[3]||a[1]);return a[2]?`<details class="md-callout md-fold"${a[2]==="+"?" open":""}><summary>${x}</summary><div>${g}</div></details>`:`<aside class="md-callout"><p class="md-callout-title">${x}</p>${g}</aside>`}case"table":return`<div class="md-table-wrap"><table>${(e.children??[]).map((r,a)=>`<${a?"tbody":"thead"}><tr>${(r.children??[]).map(g=>`<${a?"td":"th"}>${h(g)}</${a?"td":"th"}>`).join("")}</tr></${a?"tbody":"thead"}>`).join("")}</table></div>`;case"code":return`<pre><code${e.lang?` class="language-${o(e.lang.replace(/[^\w-]/g,""))}"`:""}>${o(e.value)}</code></pre>`;case"thematicBreak":return"<hr>";case"html":case"yaml":case"definition":return"";default:return e.children?n():o(e.value)}}const p=(l.children??[]).filter(e=>!["yaml","html","definition"].includes(e.type));let k="";p[0]?.type==="heading"&&p[0].depth===1&&(k=C(p.shift()));let u="",S=!1;for(let e=0;e<p.length;e++){const n=p[e];n.type==="heading"&&n.depth===2&&(S&&(u+="</section>"),u+='<section class="md-feature">',S=!0);const r=X(n),a=p[e+1]&&P(p[e+1]),g=r&&a?y(a,r):null;if(g){u+=g,e++;continue}u+=i(n)}return S&&(u+="</section>"),{title:k,html:u}}function J(t,m="en"){const l=m==="zh",c=Array.from(t.querySelectorAll("[data-amadeus-media]")),d=new AbortController,v=s=>{c.forEach(f=>{f!==s&&f.querySelector("video,audio")?.pause()})};for(const s of c){const f=s.querySelector("button"),h=s.querySelector(".md-media-stage");f.addEventListener("click",()=>{const y=s.querySelector(".md-media-error");if(y.hidden=!0,s.dataset.amadeusMedia==="platform"){if(h.querySelector("iframe")){h.querySelector("iframe").remove(),h.classList.remove("playing"),f.textContent=l?"播放":"Play";return}v(s);const p=document.createElement("iframe");p.src=s.dataset.src,p.title=s.querySelector("figcaption span")?.textContent||"Video",p.allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; fullscreen",p.allowFullscreen=!0,p.referrerPolicy="strict-origin-when-cross-origin",h.appendChild(p),h.classList.add("playing"),f.textContent=l?"关闭播放器":"Close player";return}let i=h.querySelector("video,audio");if(i||(i=document.createElement(s.dataset.amadeusMedia==="audio"?"audio":"video"),i.setAttribute("controls",""),i.setAttribute("playsinline",""),i.preload="none",i.src=s.dataset.src,h.appendChild(i),i.addEventListener("playing",()=>{h.classList.add("playing"),f.textContent=l?"暂停":"Pause"},{signal:d.signal}),i.addEventListener("pause",()=>{f.textContent=i.ended?l?"重播":"Replay":l?"继续播放":"Resume"},{signal:d.signal}),i.addEventListener("loadedmetadata",()=>{i instanceof HTMLVideoElement&&i.videoHeight&&(h.style.aspectRatio=`${i.videoWidth}/${i.videoHeight}`)},{signal:d.signal})),!i.paused){i.pause();return}v(s),i.play().catch(()=>{y.hidden=!1,h.classList.remove("playing")})},{signal:d.signal})}const $=()=>{c.forEach(s=>s.querySelector("video,audio")?.pause())};return document.addEventListener("visibilitychange",()=>{document.hidden&&$()},{signal:d.signal}),()=>{d.abort(),$(),c.forEach(s=>s.querySelector("iframe")?.remove())}}F({"publishing.visual":{zh:"Amadeus 编辑",en:"Amadeus editor"},"publishing.source":{zh:"Markdown 源码",en:"Markdown source"},"publishing.preview":{zh:"预览",en:"Preview"}});function K({options:t,revision:m,alive:l}){const{t:c,locale:d}=V(),[v,$]=j.useState(t.value),[s,f]=j.useState("visual"),h=t.modes!==!1,y=h?s:"visual",i=j.useRef(null);j.useEffect(()=>{$(t.value)},[t.value,m]);const p=u=>{l()&&(t.value=u,$(u),t.onChange?.(u))};j.useEffect(()=>i.current?J(i.current,d):void 0,[y,v,d,t.previewBaseUrl]);const k=y==="preview"?D(v,{locale:d,baseUrl:t.previewBaseUrl}):null;return b.jsxs("div",{className:"am-app amx-publishing-editor","aria-label":t.label,children:[h&&b.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6,padding:"8px 0"},children:["visual","source","preview"].map(u=>b.jsx("button",{className:"btn",type:"button","aria-pressed":y===u,onClick:()=>f(u),children:c(`publishing.${u}`)},u))}),y==="visual"&&b.jsx(N,{initial:v,onChange:p,readOnly:t.readOnly,immediate:!0}),y==="source"&&b.jsx("textarea",{"aria-label":t.label||c("publishing.source"),value:v,readOnly:t.readOnly,onChange:u=>p(u.target.value),style:{width:"100%",minHeight:420,resize:"vertical",padding:12,font:"inherit",fontFamily:"var(--font-mono)",color:"var(--text)",background:"var(--bg)",border:"1px solid var(--border)",borderRadius:"var(--radius-sm)"}}),k&&b.jsx("div",{ref:i,className:"amadeus-published",dangerouslySetInnerHTML:{__html:(k.title?`<h1>${k.title.replace(/[&<>"']/g,u=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[u])}</h1>`:"")+k.html}})]})}function oe(t,m){const l={...m};let c=!0,d=0;const v=()=>b.jsx(W,{children:b.jsx(K,{options:l,revision:d++,alive:()=>c})}),$=T(t,v(),()=>{c=!1}),s=()=>$.render(v());return{getValue(){return l.value},update(f){c&&(Object.assign(l,f),s())},insertMarkdown(f){c&&!l.readOnly&&(l.value+=`
|
|
2
|
+
|
|
3
|
+
`+f,l.onChange?.(l.value),s())},focus(){c&&t.querySelector('[contenteditable="true"],textarea')?.focus()},dispose:$.dispose}}export{oe as mountPluginMarkdownEditor};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{G as a}from"./appStore-
|
|
1
|
+
import{G as a}from"./appStore-affnJoin.js";const e=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}],["path",{d:"M12 8v6",key:"1ib9pf"}],["path",{d:"M9 11h6",key:"1fldmi"}]],o=a("message-square-plus",e);export{o as M};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t}from"./index-
|
|
1
|
+
import{r as t}from"./index-BYUntVIZ.js";t({"automation.deleted":{zh:"已删除「{name}」",en:"Deleted “{name}”"},"automation.deleteConfirm":{zh:"删除「{name}」?此操作无法撤销。",en:"Delete “{name}”? This can’t be undone."},"automation.undo":{zh:"撤销",en:"Undo"},"automation.ux.actions":{zh:"更多操作",en:"More actions"},"automation.ux.help":{zh:"使用说明",en:"Workflow help"},"automation.ux.properties":{zh:"规则配置",en:"Rule configuration"},"automation.ux.myWorkflows":{zh:"我的自动化",en:"My workflows"},"automation.ux.noRules":{zh:"从入门模板创建第一条自动化。",en:"Create your first workflow from a starter template."},"automation.ux.workspace":{zh:"自动化工作台",en:"Automation studio"},"automation.ux.welcome":{zh:"把重复的事,交给流程",en:"Turn repeat work into a workflow"},"automation.ux.intro":{zh:"从一个触发条件开始,连接 Agent、笔记和多维表,随时查看每一步的结果。",en:"Start with a trigger, connect your agents, notes and databases, and see what each step did."},"automation.ux.guide.trigger":{zh:"选择触发方式",en:"Choose a trigger"},"automation.ux.guide.triggerHint":{zh:"定时、事件、表格变化,或手动点击。",en:"A schedule, an event, a database change, or a click."},"automation.ux.guide.actions":{zh:"连接要做的事",en:"Connect your actions"},"automation.ux.guide.actionsHint":{zh:"在画布添加步骤,选中节点完成配置。",en:"Add steps on the canvas, then select a node to configure it."},"automation.ux.guide.test":{zh:"试运行,再启用",en:"Test, then enable"},"automation.ux.guide.testHint":{zh:"先保存为暂停状态,检查结果后开启。",en:"Save paused, review a test run, then enable it."},"automation.ux.startWith":{zh:"从场景开始",en:"Start with a use case"},"automation.ux.blank":{zh:"自定义流程",en:"Custom workflow"},"automation.ux.draftHint":{zh:"模板只填入草稿。保存前,你可以修改所有配置。",en:"Templates only fill a draft. Review and change anything before saving."},"automation.ux.native":{zh:"和 Forsion 一起工作",en:"Works with Forsion"},"automation.ux.nativeHint":{zh:"笔记按钮负责手动启动,多维表提供触发数据,Agent 处理任务,通知送达收件箱。Muse 和 Historian 的系统自动化也可在左侧单独管理。",en:"Note buttons start manual workflows, databases supply trigger data, agents handle tasks, and notifications arrive in your inbox. Manage Muse and Historian separately in the sidebar."},"automation.ux.reminder.name":{zh:"每日提醒",en:"Daily reminder"},"automation.ux.reminder.hint":{zh:"每天固定时间,把提醒送进收件箱。",en:"Send a reminder to your inbox at a set time each day."},"automation.ux.reminder.flow":{zh:"每天 09:00 → 发通知",en:"Daily at 09:00 → Notify"},"automation.ux.reminder.body":{zh:"今天有哪些值得优先处理的事?",en:"What deserves your attention today?"},"automation.ux.briefing.name":{zh:"Agent 每日简报",en:"Daily agent briefing"},"automation.ux.briefing.hint":{zh:"选一个 Agent,定时整理你关心的信息。",en:"Choose an agent to prepare a scheduled briefing."},"automation.ux.briefing.flow":{zh:"定时 → 跑 Agent",en:"Schedule → Run agent"},"automation.ux.briefing.prompt":{zh:"整理一份今日工作简报,总结当前待办和需要关注的事项。",en:"Prepare a daily briefing of current tasks and items that need attention."},"automation.ux.table.name":{zh:"新增记录提醒",en:"New record notification"},"automation.ux.table.hint":{zh:"多维表新增一行时,通知你及时跟进。",en:"Get notified when a new row is added to a database."},"automation.ux.table.flow":{zh:"新增记录 → 发通知",en:"Row added → Notify"},"automation.ux.table.body":{zh:"多维表新增了记录:{{row.id}}",en:"A new database row was added: {{row.id}}"},"automation.ux.button.name":{zh:"一键交给 Agent",en:"One click to an agent"},"automation.ux.button.hint":{zh:"手动执行常用任务,也能绑定到笔记按钮。",en:"Run a repeat task manually or attach it to a note button."},"automation.ux.button.flow":{zh:"手动点击 → 跑 Agent",en:"Manual click → Run agent"},"automation.ux.button.prompt":{zh:"检查我的待办,整理接下来最值得推进的三件事。",en:"Review my tasks and identify the three most useful next actions."},"automation.ux.overview":{zh:"入门与模板",en:"Guide and templates"},"automation.ux.search":{zh:"搜索自动化",en:"Search automations"},"automation.ux.noMatches":{zh:"没有匹配的自动化",en:"No matching automations"},"automation.ux.enable":{zh:"启用",en:"Enable"},"automation.ux.pause":{zh:"暂停",en:"Pause"},"automation.ux.on":{zh:"已启用",en:"Enabled"},"automation.ux.off":{zh:"已暂停",en:"Paused"},"automation.ux.flow":{zh:"工作流画布",en:"Workflow canvas"},"automation.ux.canvasHint":{zh:"拖动排列 · 点击配置",en:"Drag to arrange · Click to configure"},"automation.ux.canvasOrder":{zh:"按连线顺序执行。拖动只调整布局,步骤顺序在配置中调整。",en:"Steps run in connected order. Dragging changes the layout; use the step controls to reorder execution."},"automation.ux.zoomIn":{zh:"放大画布",en:"Zoom in"},"automation.ux.zoomOut":{zh:"缩小画布",en:"Zoom out"},"automation.ux.fit":{zh:"适应视图",en:"Fit to view"},"automation.ux.arrange":{zh:"自动排列",en:"Auto arrange"},"automation.ux.ready":{zh:"已配置",en:"Configured"},"automation.ux.incomplete":{zh:"待配置",en:"Needs setup"},"automation.ux.finish":{zh:"保存与启用",en:"Save and enable"},"automation.ux.finishHint":{zh:"检查配置与启动方式",en:"Review setup and activation"},"automation.ux.addStep":{zh:"添加步骤",en:"Add a step"},"automation.ux.maxSteps":{zh:"最多添加 24 个步骤",en:"Up to 24 steps"},"automation.ux.setup":{zh:"节点配置",en:"Node configuration"},"automation.ux.setupHint":{zh:"选中画布节点,配置触发条件或动作。",en:"Select a canvas node to configure its trigger or action."},"automation.ux.savePaused":{zh:"保存为暂停",en:"Save paused"},"automation.ux.saveEnabled":{zh:"保存并启用",en:"Save and enable"},"automation.ux.enabledLabel":{zh:"保存后启用",en:"Enable after saving"},"automation.ux.enableHint":{zh:"暂停状态仍可试运行;启用后才响应触发条件。",en:"Paused workflows can still be tested. Enable them to respond to triggers."},"automation.ux.saved":{zh:"自动化已保存",en:"Automation saved"},"automation.ux.checklist":{zh:"还需完成",en:"Complete the setup"},"automation.ux.allReady":{zh:"配置已完成,可以保存",en:"Ready to save"},"automation.ux.review":{zh:"检查并保存",en:"Review and save"},"automation.ux.issue.name":{zh:"填写自动化名称",en:"Enter a workflow name"},"automation.ux.issue.trigger":{zh:"补全触发条件",en:"Complete the trigger settings"},"automation.ux.issue.steps":{zh:"至少添加一个动作",en:"Add at least one action"},"automation.ux.issue.notify":{zh:"填写通知标题",en:"Enter a notification title"},"automation.ux.issue.agent":{zh:"选择执行任务的 Agent",en:"Choose an agent"},"automation.ux.issue.prompt":{zh:"说明 Agent 需要完成的任务",en:"Describe the task for the agent"},"automation.ux.issue.table":{zh:"选择目标多维表",en:"Choose a database"},"automation.ux.issue.cells":{zh:"至少指定一个要写入的字段",en:"Add at least one field to write"},"automation.ux.issue.row":{zh:"指定记录 ID 或按列值匹配目标记录",en:"Set a row ID or match target rows by a column value"},"automation.ux.issue.match":{zh:"填写记录匹配值",en:"Enter a row matching value"},"automation.ux.issue.tool":{zh:"选择一个可用工具",en:"Choose an available tool"},"automation.ux.issue.args":{zh:"补全工具的必填参数",en:"Complete the required tool arguments"},"automation.ux.issue.json":{zh:"填写有效的 JSON 参数",en:"Enter valid JSON arguments"},"automation.ux.issue.cooldown":{zh:"填写有效的冷却时长",en:"Enter a valid cooldown duration"},"automation.ux.variables":{zh:"插入变量",en:"Insert variable"},"automation.ux.insertVariable":{zh:"为「{field}」插入变量",en:"Insert a variable into {field}"},"automation.ux.today":{zh:"今天的日期",en:"Today"},"automation.ux.now":{zh:"当前时间",en:"Current time"},"automation.ux.triggerRow":{zh:"触发记录",en:"Trigger row"},"automation.ux.rowId":{zh:"记录 ID",en:"Row ID"},"automation.ux.runHint":{zh:"试运行会真实执行已保存的动作。",en:"Testing executes the saved actions."},"automation.ux.dbRunHint":{zh:"表格规则试运行不携带触发行数据;行变量与默认触发行目标需要真实表格事件。",en:"Database tests have no triggering row. Row variables and default row targets require a real database event."},"automation.ux.runResults":{zh:"运行结果",en:"Run results"},"automation.ux.runEmpty":{zh:"还没有运行记录。可以先试运行一次,或等待触发条件满足。",en:"No runs yet. Test the workflow or wait for its trigger."},"automation.ux.runLoading":{zh:"正在读取运行记录…",en:"Loading runs…"},"automation.ux.runError":{zh:"无法读取运行记录,请重试。",en:"Could not load runs. Please retry."},"automation.ux.retry":{zh:"重试",en:"Retry"},"automation.ux.done":{zh:"已完成",en:"Completed"},"automation.ux.failed":{zh:"失败",en:"Failed"},"automation.ux.running":{zh:"运行中",en:"Running"},"automation.ux.queued":{zh:"排队中",en:"Queued"},"automation.ux.autoOrigin":{zh:"自动触发",en:"Automatic"},"automation.ux.manualOrigin":{zh:"手动执行",en:"Manual"},"automation.ux.stepResult":{zh:"步骤 {n} · {type}",en:"Step {n} · {type}"},"automation.ux.latestResults":{zh:"每步执行结果",en:"Step results"},"automation.ux.noSteps":{zh:"这次执行没有步骤结果。",en:"No step results were recorded for this run."},"automation.ux.systemHint":{zh:"系统助理",en:"System assistants"},"automation.ux.loadError":{zh:"自动化加载失败,请重试。",en:"Could not load automations. Please retry."}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{G as o}from"./appStore-affnJoin.js";const s=[["path",{d:"M5 12h14",key:"1ays0h"}]],e=o("minus",s);export{e as M};
|