@jdi-code/claude-code 1.0.3 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +104 -369
- package/dist/{chunk-4t7n5hfg.js → chunk-0318ehfm.js} +8 -8
- package/dist/chunk-050fe4m3.js +68 -0
- package/dist/chunk-06v69x0b.js +127 -0
- package/dist/chunk-07069jq1.js +30 -0
- package/dist/chunk-0c9xpqm8.js +106 -0
- package/dist/chunk-0hxxwcs1.js +107 -0
- package/dist/chunk-0nsb3kxz.js +440 -0
- package/dist/{chunk-1cbn5kxf.js → chunk-0rpb2bdp.js} +3 -2
- package/dist/{chunk-vykgfhrb.js → chunk-0svbkpfn.js} +5 -5
- package/dist/chunk-0vg07894.js +121 -0
- package/dist/{chunk-e4vsvf0r.js → chunk-0zefjhrg.js} +4 -4
- package/dist/chunk-0zfmj5y2.js +106 -0
- package/dist/{chunk-czkshaff.js → chunk-107p04a0.js} +13 -11
- package/dist/{chunk-z4dm354d.js → chunk-13f30tg0.js} +1 -1
- package/dist/{chunk-44fpr6jq.js → chunk-168xb8v1.js} +4 -2
- package/dist/{chunk-0w63x62y.js → chunk-181q7ysj.js} +79 -63
- package/dist/{chunk-6mapphaq.js → chunk-18jc5efa.js} +8 -8
- package/dist/chunk-19j7nkpy.js +133 -0
- package/dist/chunk-1c2qp0ks.js +33068 -0
- package/dist/{chunk-0e1xsncc.js → chunk-1cwdhk7a.js} +1 -1
- package/dist/{chunk-7m2nd8da.js → chunk-1erfksyp.js} +6 -9
- package/dist/{chunk-rs45skes.js → chunk-1h1tc4mw.js} +13 -10
- package/dist/{chunk-91rcbmch.js → chunk-1rngm3yy.js} +155 -184
- package/dist/{chunk-3gqdqmzb.js → chunk-1vthytca.js} +16 -12
- package/dist/{chunk-xe6z85xc.js → chunk-1xbs4yb6.js} +19 -16
- package/dist/chunk-1xj1yz5n.js +109 -0
- package/dist/chunk-21mfpnva.js +85 -0
- package/dist/chunk-2361j94t.js +1811 -0
- package/dist/chunk-238g70xa.js +1 -1
- package/dist/chunk-250f5ce1.js +108 -0
- package/dist/{chunk-8yx1trkj.js → chunk-29r4exv2.js} +105 -211
- package/dist/chunk-2a8yf5ct.js +72 -0
- package/dist/{chunk-h3fqb66h.js → chunk-2bnerkhs.js} +110 -135
- package/dist/{chunk-0nt9md2b.js → chunk-2cctz9ww.js} +101 -8
- package/dist/chunk-2fwze72g.js +24 -0
- package/dist/{chunk-h3qa8f5w.js → chunk-2jvpw0q1.js} +229 -363
- package/dist/{chunk-9wm5e9e9.js → chunk-2mj88mnr.js} +42 -31
- package/dist/chunk-2q0schcc.js +133 -0
- package/dist/{chunk-r66hz8j6.js → chunk-2qp2hc02.js} +14 -12
- package/dist/chunk-2t0xa4dt.js +145 -0
- package/dist/chunk-2tzxsnha.js +360 -0
- package/dist/chunk-2v8cya3p.js +54 -0
- package/dist/chunk-2w00z1ct.js +105 -0
- package/dist/{chunk-2md1yavs.js → chunk-2wpfdv2t.js} +43 -32
- package/dist/chunk-2xcr3eqt.js +65 -0
- package/dist/chunk-30bpz5m2.js +34 -0
- package/dist/{chunk-hrzerbfw.js → chunk-36b2q5fg.js} +14 -14
- package/dist/{chunk-edg1yhec.js → chunk-3aady5e2.js} +2 -2
- package/dist/chunk-3ewzhjyb.js +207 -0
- package/dist/{chunk-z47tm067.js → chunk-3kpptrnz.js} +54 -47
- package/dist/{chunk-yd3av9a3.js → chunk-3na967x3.js} +2 -2
- package/dist/chunk-3nk79af8.js +8 -0
- package/dist/{chunk-z0cm9r7f.js → chunk-3r66czp1.js} +10 -10
- package/dist/{chunk-rnjbczcy.js → chunk-3y3qasy6.js} +13 -11
- package/dist/{chunk-nxsh6de2.js → chunk-404qm8xt.js} +16 -12
- package/dist/{chunk-mhqthgdg.js → chunk-41grdp0q.js} +5 -5
- package/dist/chunk-4cp6193g.js +9076 -0
- package/dist/chunk-4g18phg9.js +2535 -0
- package/dist/{chunk-6n2qgm9v.js → chunk-4hv90qcz.js} +1 -1
- package/dist/chunk-4jkfzf6g.js +81 -0
- package/dist/{chunk-5frcqxsv.js → chunk-4m6k7588.js} +127117 -138842
- package/dist/chunk-4nspekjp.js +69 -0
- package/dist/chunk-4x29t96w.js +119 -0
- package/dist/{chunk-40b8p5em.js → chunk-585cb3h6.js} +14 -12
- package/dist/{chunk-5dbar61y.js → chunk-59qz55py.js} +77 -61
- package/dist/chunk-5bta6qne.js +1030 -0
- package/dist/chunk-5dmczs66.js +123 -0
- package/dist/{chunk-9e2kqv5g.js → chunk-5pevjsyw.js} +3 -10
- package/dist/{chunk-5ndexvh1.js → chunk-5py41v61.js} +10226 -16961
- package/dist/{chunk-d5e75scx.js → chunk-5q2gm8dt.js} +5 -5
- package/dist/{chunk-893mewv4.js → chunk-5rpyh7nn.js} +1 -1
- package/dist/{chunk-hx2tr4ep.js → chunk-5z28bqne.js} +34 -475
- package/dist/chunk-5zzwydag.js +1170 -0
- package/dist/{chunk-4tyxyfsv.js → chunk-61gm3j90.js} +2 -2
- package/dist/chunk-64c1avct.js +13 -0
- package/dist/chunk-64hks9ax.js +456 -0
- package/dist/{chunk-bw9a5v0b.js → chunk-64m7ax9d.js} +4 -4
- package/dist/{chunk-cha1tdry.js → chunk-66hjztcb.js} +1 -1
- package/dist/{chunk-q25bjaev.js → chunk-677as3nh.js} +2 -2
- package/dist/chunk-69v14ada.js +76 -0
- package/dist/chunk-6eahnbxj.js +101 -0
- package/dist/chunk-6eg4c33n.js +196 -0
- package/dist/chunk-6fjfwj7q.js +214 -0
- package/dist/{chunk-70qb5sds.js → chunk-6kwwke3r.js} +2 -2
- package/dist/chunk-6m0pc6py.js +311 -0
- package/dist/chunk-6mpw9h55.js +1071 -0
- package/dist/{chunk-v1mgv1et.js → chunk-6p4cyhb3.js} +4 -3
- package/dist/chunk-6r1dx518.js +111 -0
- package/dist/{chunk-1n1xqxv5.js → chunk-713bh4cd.js} +1072 -1736
- package/dist/{chunk-nstbdz07.js → chunk-7246q965.js} +85 -69
- package/dist/{chunk-w6q6a1qj.js → chunk-74mdk2e7.js} +564 -864
- package/dist/{chunk-77czbpcq.js → chunk-76pa90ge.js} +104 -90
- package/dist/chunk-77nkh0x1.js +82 -0
- package/dist/chunk-7bsbnzpm.js +65 -0
- package/dist/chunk-7r3v46aq.js +167 -0
- package/dist/chunk-7vf8s593.js +235 -0
- package/dist/chunk-7x6ng8fp.js +64 -0
- package/dist/chunk-7xy990yb.js +81 -0
- package/dist/chunk-7xyswgjh.js +8 -0
- package/dist/chunk-80p18mf8.js +228 -0
- package/dist/{chunk-dv1wfr85.js → chunk-8225arm6.js} +5 -4
- package/dist/{chunk-vdbes184.js → chunk-82rh5hpz.js} +70 -10
- package/dist/chunk-84nf3k34.js +73 -0
- package/dist/chunk-85v0yx5b.js +106 -0
- package/dist/{chunk-x5j50p5x.js → chunk-86f4vq6n.js} +5 -5
- package/dist/{chunk-e5ga3s0y.js → chunk-86vec0h6.js} +148 -421
- package/dist/chunk-8az1n4zt.js +110 -0
- package/dist/{chunk-ctw5jwcd.js → chunk-8bwqtasa.js} +10 -10
- package/dist/chunk-8c9jtmsm.js +100 -0
- package/dist/{chunk-fqc5mcw7.js → chunk-8ca80ew2.js} +9 -9
- package/dist/chunk-8g5pe1gr.js +37 -0
- package/dist/{chunk-g0j0t6qk.js → chunk-8g747a8x.js} +1 -1
- package/dist/{chunk-3vzs2gbq.js → chunk-8gxztyqd.js} +4 -4
- package/dist/{chunk-45kxdsp8.js → chunk-8h6sdj66.js} +13 -10
- package/dist/{chunk-s8amjdwf.js → chunk-8ht15c7w.js} +7 -7
- package/dist/{chunk-ywxd4qw4.js → chunk-8mm8b6dd.js} +2 -5
- package/dist/{chunk-sdj9b9wh.js → chunk-8pn8tvgg.js} +9 -154
- package/dist/{chunk-pxrffn0w.js → chunk-8vnxjgz9.js} +11 -5
- package/dist/chunk-9525p9tg.js +401 -0
- package/dist/{chunk-y47cg3kz.js → chunk-9a0rsdre.js} +17 -13
- package/dist/chunk-9a2pa53f.js +308 -0
- package/dist/chunk-9es2dav7.js +507 -0
- package/dist/chunk-9pq45ycx.js +217 -0
- package/dist/chunk-9qwkw406.js +121 -0
- package/dist/chunk-9rf1x0z9.js +109 -0
- package/dist/{chunk-ghmbr193.js → chunk-9rvqx05m.js} +9 -9
- package/dist/{chunk-dchkdhzs.js → chunk-9sd3tz3p.js} +91 -75
- package/dist/chunk-9x5zgy22.js +12 -0
- package/dist/{chunk-q6b51yc5.js → chunk-9z4vq44b.js} +3 -3
- package/dist/chunk-a136cvvz.js +27 -0
- package/dist/{chunk-8hq5kk3y.js → chunk-a4twdmhf.js} +3 -2
- package/dist/{chunk-d18z9pna.js → chunk-a7rhvq9b.js} +2 -2
- package/dist/{chunk-pmjqdasm.js → chunk-a8jbqb9f.js} +2313 -4199
- package/dist/chunk-a9xhsth1.js +1068 -0
- package/dist/{chunk-kd63fbhw.js → chunk-achjqrhd.js} +81 -65
- package/dist/{chunk-67kbbt9h.js → chunk-af2vfhm4.js} +42 -31
- package/dist/{chunk-js8rvgs1.js → chunk-ahn9tgz7.js} +3 -3
- package/dist/chunk-ajets2e9.js +103 -0
- package/dist/chunk-akxywws0.js +79 -0
- package/dist/{chunk-meefz2g4.js → chunk-aqvgkvsq.js} +7 -7
- package/dist/{chunk-r6b58y3x.js → chunk-ase86y73.js} +1 -3
- package/dist/{chunk-hjhc4cpt.js → chunk-awb4vc41.js} +2 -2
- package/dist/{chunk-1jrcb7cs.js → chunk-b0mt3wzx.js} +37 -82
- package/dist/chunk-b4zy6y92.js +105 -0
- package/dist/{chunk-ax83mpvw.js → chunk-b65yxs9e.js} +26 -26
- package/dist/{chunk-wzx6mmft.js → chunk-b7b39zx2.js} +120 -118
- package/dist/{chunk-8bedvdm1.js → chunk-b81hd3m6.js} +1 -1
- package/dist/chunk-bbr7mwpv.js +117 -0
- package/dist/{chunk-1a61g8t2.js → chunk-bdzqt6gy.js} +83 -64
- package/dist/chunk-bkm0zms8.js +110 -0
- package/dist/{chunk-0vvej174.js → chunk-bs8r4665.js} +5 -5
- package/dist/{chunk-xvc4gp3x.js → chunk-bszdmr4k.js} +24 -24
- package/dist/{chunk-8ngxagxq.js → chunk-bt64sq5y.js} +4 -3
- package/dist/chunk-bvcpr8qa.js +909 -0
- package/dist/chunk-bx811wk6.js +118 -0
- package/dist/{chunk-3be7ka25.js → chunk-bxcfz5gy.js} +1 -1
- package/dist/{chunk-77g09znh.js → chunk-byv2p9hn.js} +22 -16
- package/dist/{chunk-wbkahkdc.js → chunk-c03am3es.js} +8 -6
- package/dist/chunk-c1x69s30.js +116 -0
- package/dist/chunk-c5vkve4j.js +68 -0
- package/dist/chunk-c6sjhj89.js +1284 -0
- package/dist/chunk-cb0wxajw.js +142 -0
- package/dist/{chunk-vyc0rjyx.js → chunk-cbrt5vsb.js} +1 -1
- package/dist/{chunk-4kxr1pwz.js → chunk-cgmy7r62.js} +30 -17
- package/dist/chunk-chsyvavm.js +3435 -0
- package/dist/{chunk-z72st5c8.js → chunk-cmsknj6n.js} +4774 -3386
- package/dist/{chunk-cdz5yb0r.js → chunk-crmjpsqe.js} +13 -2
- package/dist/chunk-cs039fnj.js +123 -0
- package/dist/{chunk-e7393td6.js → chunk-cznf6k4g.js} +13 -9
- package/dist/{chunk-fw49pe3p.js → chunk-cztjpxq4.js} +6 -6
- package/dist/{chunk-n8sjmqba.js → chunk-d0n93ge4.js} +141 -100
- package/dist/{chunk-spde0bf5.js → chunk-d14ygn80.js} +3 -3
- package/dist/chunk-d4mdda98.js +94 -0
- package/dist/chunk-d5qggsbm.js +137 -0
- package/dist/{chunk-55wgxwa9.js → chunk-d7886r6a.js} +6928 -6935
- package/dist/{chunk-eh8h36nt.js → chunk-d9gxtzmz.js} +42 -31
- package/dist/{chunk-xk66xrkk.js → chunk-da312cj9.js} +54 -72
- package/dist/{chunk-j287ctwr.js → chunk-df19zqjj.js} +77 -61
- package/dist/chunk-dm3n2qgd.js +24 -0
- package/dist/{chunk-m21hvkn4.js → chunk-dncgrfdt.js} +2 -2
- package/dist/{chunk-0nz8sqg4.js → chunk-dq3rw4b5.js} +1294 -873
- package/dist/{chunk-ey03t39w.js → chunk-dw1f4b7e.js} +257 -194
- package/dist/chunk-dx1jrvdz.js +339 -0
- package/dist/{chunk-0ragr30c.js → chunk-dxeadbxq.js} +12 -12
- package/dist/{chunk-gdp8wgnd.js → chunk-e8b9gcwf.js} +88 -72
- package/dist/chunk-e9k5a3cy.js +409 -0
- package/dist/chunk-e9mer45h.js +64 -0
- package/dist/{chunk-5qbwrz8m.js → chunk-ea2f7wt3.js} +13 -13
- package/dist/chunk-eak7m65m.js +1182 -0
- package/dist/chunk-ebhgmeyk.js +245 -0
- package/dist/chunk-eg93k7ac.js +117 -0
- package/dist/{chunk-jgv78tv0.js → chunk-ej1yvp43.js} +8 -8
- package/dist/chunk-ekr8pwpv.js +1408 -0
- package/dist/{chunk-m4edbpcz.js → chunk-epg124e3.js} +117 -143
- package/dist/chunk-eyqnj23w.js +5368 -0
- package/dist/chunk-f2bvkxbw.js +267 -0
- package/dist/chunk-f537x96t.js +295 -0
- package/dist/chunk-f6wdmebb.js +108 -0
- package/dist/chunk-feyzykye.js +10 -0
- package/dist/{chunk-ep47dy22.js → chunk-fj3ywwqv.js} +7 -7
- package/dist/{chunk-9gttd1xq.js → chunk-fjv7p1kc.js} +4 -4
- package/dist/{chunk-1rnkpxy4.js → chunk-fpe5nywt.js} +10 -115
- package/dist/chunk-fvpgrg19.js +434 -0
- package/dist/{chunk-9xmsmn93.js → chunk-fvqrkmtn.js} +5 -5
- package/dist/{chunk-6g62sjpf.js → chunk-fz0ch109.js} +4 -3
- package/dist/{chunk-5xz7ts0k.js → chunk-g0vh71q6.js} +188 -339
- package/dist/chunk-g1gtvtv8.js +384 -0
- package/dist/chunk-g5g9wm20.js +66 -0
- package/dist/{chunk-v399mzxk.js → chunk-g63tgj4f.js} +2 -2
- package/dist/{chunk-kkkneeg1.js → chunk-gay98970.js} +21 -16
- package/dist/chunk-gey7mwcw.js +36 -0
- package/dist/{chunk-w5ctjgmx.js → chunk-gtyh1yd1.js} +2 -2
- package/dist/{chunk-tjaqa99q.js → chunk-gx8016vp.js} +3 -3
- package/dist/{chunk-f2mhrmww.js → chunk-h0rbjg6x.js} +1 -8
- package/dist/{chunk-7z8j9qfn.js → chunk-h1mr3371.js} +3 -3
- package/dist/chunk-h2yxyeq4.js +132 -0
- package/dist/{chunk-qqfa0dqg.js → chunk-h4b85amj.js} +20 -32
- package/dist/chunk-h707k8xq.js +64 -0
- package/dist/{chunk-3z6rf0m3.js → chunk-h7rcjx8d.js} +5 -5
- package/dist/chunk-hch5yeq8.js +121 -0
- package/dist/{chunk-4anyx5bv.js → chunk-hd4azb7x.js} +5 -5
- package/dist/chunk-hjnbg9qw.js +32 -0
- package/dist/{chunk-e2yv57c2.js → chunk-hk9mmkba.js} +8 -8
- package/dist/{chunk-f1rrxxcf.js → chunk-hs9w0p45.js} +7 -131
- package/dist/{chunk-9f7xza5r.js → chunk-htaan7k0.js} +11 -11
- package/dist/chunk-htg84hvs.js +300 -0
- package/dist/chunk-hvyr6p4r.js +433 -0
- package/dist/chunk-j0r5vkvw.js +267 -0
- package/dist/{chunk-9gbamk79.js → chunk-j5bth84e.js} +5 -1
- package/dist/{chunk-vratq94g.js → chunk-j9gxwbe3.js} +1 -1
- package/dist/{chunk-3r24h7t6.js → chunk-jaaxk89e.js} +1 -1
- package/dist/chunk-je7jake4.js +3584 -0
- package/dist/chunk-jeqhpyxr.js +126 -0
- package/dist/chunk-jngf0nar.js +135 -0
- package/dist/chunk-jqjbc5ef.js +795 -0
- package/dist/{chunk-xf4wsjdm.js → chunk-jwrmmv7j.js} +9 -7
- package/dist/{chunk-j9wpkwjj.js → chunk-jwyzy83k.js} +6 -6
- package/dist/chunk-jz8v9sn3.js +228 -0
- package/dist/{chunk-bqfnp99q.js → chunk-k3s4yk22.js} +1 -1
- package/dist/chunk-k5c09bzv.js +443 -0
- package/dist/chunk-kbktwsms.js +372 -0
- package/dist/chunk-ke0hn0xr.js +260 -0
- package/dist/chunk-kehe7a71.js +41 -0
- package/dist/{chunk-1xkekb9y.js → chunk-kfd89dsd.js} +5 -3
- package/dist/chunk-ktjjb0k9.js +104 -0
- package/dist/{chunk-b74ht3xj.js → chunk-kxgcshx1.js} +78 -62
- package/dist/chunk-kz2fpejx.js +651 -0
- package/dist/{chunk-zvbpaaa1.js → chunk-kz3ctzg3.js} +110 -115
- package/dist/{chunk-72p24c9k.js → chunk-m268mm4c.js} +127 -188
- package/dist/{chunk-jafes477.js → chunk-m2bcpk8j.js} +4 -3
- package/dist/{chunk-4qv4z794.js → chunk-m32mdkts.js} +42 -31
- package/dist/chunk-m74w3187.js +164 -0
- package/dist/chunk-m7s7j422.js +166 -0
- package/dist/chunk-majhpxx5.js +594 -0
- package/dist/{chunk-q6av622g.js → chunk-mdk3xgya.js} +17 -13
- package/dist/{chunk-8bw3ft0x.js → chunk-mfcbez9a.js} +4 -4
- package/dist/{chunk-df6bwb4a.js → chunk-mj6w3ttg.js} +2 -2
- package/dist/{chunk-drrw55jr.js → chunk-mk6kj3q2.js} +1336 -2840
- package/dist/{chunk-vqr58rfh.js → chunk-mky388t4.js} +27 -67
- package/dist/chunk-mn61mk4v.js +351 -0
- package/dist/chunk-mx28h61f.js +1147 -0
- package/dist/chunk-my57sgky.js +883 -0
- package/dist/{chunk-k48thqgp.js → chunk-myk8saf6.js} +95 -190
- package/dist/chunk-n2zdmx4g.js +66 -0
- package/dist/{chunk-720qpv6d.js → chunk-n833arxq.js} +79 -63
- package/dist/{chunk-w2z5pqd3.js → chunk-n9ktjngj.js} +6 -6
- package/dist/{chunk-2tw2ve8h.js → chunk-nb2ntesh.js} +14 -10
- package/dist/{chunk-y18mc4m4.js → chunk-nbqv8ref.js} +10 -10
- package/dist/{chunk-74v9z7z4.js → chunk-nd4rncgd.js} +3 -13
- package/dist/chunk-nda50ze4.js +341 -0
- package/dist/{chunk-gb2q3nvc.js → chunk-nea2sah6.js} +5 -5
- package/dist/{chunk-t36rb2a8.js → chunk-nefsxetf.js} +294 -500
- package/dist/chunk-netzwgv1.js +154 -0
- package/dist/chunk-nfk9e540.js +107 -0
- package/dist/{chunk-xszk7n10.js → chunk-nh3cd07f.js} +1 -1
- package/dist/chunk-njq2hmjy.js +270 -0
- package/dist/chunk-nn5j7h8a.js +156 -0
- package/dist/{chunk-6fjab2dp.js → chunk-nrvkwzmq.js} +2 -2
- package/dist/chunk-nsextsmp.js +360 -0
- package/dist/{chunk-amhzxqj4.js → chunk-nt90fta7.js} +5 -5
- package/dist/{chunk-qbx1rq4f.js → chunk-p6sqbnqb.js} +193 -327
- package/dist/chunk-p8c23zr7.js +61 -0
- package/dist/chunk-p8enbwjk.js +183 -0
- package/dist/chunk-p8yggvgf.js +436 -0
- package/dist/{chunk-96awg5tc.js → chunk-pcfhe19b.js} +80 -17
- package/dist/{chunk-sfq65q9w.js → chunk-pgv9sa3a.js} +10 -14
- package/dist/chunk-ppwjyveh.js +8 -0
- package/dist/chunk-ppxvfp6m.js +424 -0
- package/dist/{chunk-zsfxha74.js → chunk-pshjyzq4.js} +8 -7
- package/dist/{chunk-35x3tjnr.js → chunk-pwr83fyy.js} +14 -8
- package/dist/chunk-q1976kze.js +473 -0
- package/dist/chunk-q387p8pp.js +943 -0
- package/dist/{chunk-b6av9ny9.js → chunk-q3ffkhnp.js} +132 -20
- package/dist/{chunk-w7wgpqcp.js → chunk-q50q8mc5.js} +7 -7
- package/dist/{chunk-e5pntxye.js → chunk-q7tpyeb3.js} +6 -4
- package/dist/{chunk-7ymfj7m3.js → chunk-q82r31er.js} +1 -1
- package/dist/chunk-qajrkk97.js +298 -0
- package/dist/chunk-qdazcrd7.js +362 -0
- package/dist/chunk-qhwvhgty.js +61 -0
- package/dist/{chunk-455a8z6g.js → chunk-qqk0kvsw.js} +138 -98
- package/dist/chunk-qqya1xyt.js +513 -0
- package/dist/{chunk-mzdwvbb0.js → chunk-qs6wypj1.js} +2 -2
- package/dist/chunk-qtahf5s5.js +113 -0
- package/dist/{chunk-tj79kfmn.js → chunk-qv9phqbv.js} +7 -7
- package/dist/{chunk-r5k04v8g.js → chunk-qyygv221.js} +13 -9
- package/dist/{chunk-zfc67eqj.js → chunk-r34f6vwc.js} +4 -4
- package/dist/{chunk-nerv0jvx.js → chunk-r59rgjxq.js} +1 -1
- package/dist/{chunk-7sb5axvf.js → chunk-r7j395t6.js} +2 -2
- package/dist/chunk-rb31sqzm.js +106 -0
- package/dist/{chunk-twsxz9ph.js → chunk-rbwy1qmm.js} +42 -31
- package/dist/{chunk-99t8enmg.js → chunk-re3crc6t.js} +10 -7
- package/dist/chunk-rhw4ayb1.js +6851 -0
- package/dist/{chunk-h6wtwdk0.js → chunk-rm31ynek.js} +8 -8
- package/dist/{chunk-eqrh0yjm.js → chunk-rr4e4axp.js} +2 -2
- package/dist/{chunk-neh2frnn.js → chunk-rs8304k5.js} +6 -6
- package/dist/{chunk-gax0fcbx.js → chunk-s1s8qfdh.js} +5 -5
- package/dist/{chunk-src9fqj8.js → chunk-s2483y2h.js} +3 -3
- package/dist/chunk-s2nhzjmt.js +113 -0
- package/dist/{chunk-7jma9mhn.js → chunk-sfhws681.js} +77 -61
- package/dist/{chunk-e3g8q4cn.js → chunk-sg66v252.js} +10 -8
- package/dist/{chunk-vp25xhav.js → chunk-szyt0xvf.js} +69 -78
- package/dist/{chunk-v7455ztd.js → chunk-t7j91et3.js} +86 -67
- package/dist/{chunk-mt25echc.js → chunk-tezak8rx.js} +1 -1
- package/dist/chunk-tf1p9trz.js +190 -0
- package/dist/{chunk-05gxvwvf.js → chunk-tm82sqkr.js} +96 -79
- package/dist/chunk-tpjetyb0.js +106 -0
- package/dist/chunk-trxvrrac.js +149 -0
- package/dist/chunk-tv9pcdnz.js +51 -0
- package/dist/{chunk-e5tfw9f7.js → chunk-twh7pzm8.js} +248 -307
- package/dist/{chunk-1x2wb3tc.js → chunk-txfvkh0w.js} +8 -8
- package/dist/chunk-var1et7e.js +66 -0
- package/dist/{chunk-se7v9emp.js → chunk-vbhvx4ma.js} +12 -10
- package/dist/{chunk-hqmz36b3.js → chunk-vf612n57.js} +21 -101
- package/dist/{chunk-3sdp7ds7.js → chunk-vfcty2ga.js} +10 -10
- package/dist/chunk-vhhyv8z8.js +147 -0
- package/dist/{chunk-48z7dgy1.js → chunk-vjcxs86z.js} +3 -3
- package/dist/{chunk-k5bpc8d5.js → chunk-vmnf3h9c.js} +43 -32
- package/dist/{chunk-fpjeh2em.js → chunk-vr7wmmyn.js} +17 -13
- package/dist/{chunk-9ewmqkgb.js → chunk-vxp2mhqy.js} +8 -8
- package/dist/{chunk-d238zp4m.js → chunk-w4gwnrwa.js} +2 -2
- package/dist/{chunk-jhsywyw8.js → chunk-wahkzh83.js} +9 -9
- package/dist/chunk-wdd4en5q.js +117 -0
- package/dist/{chunk-gm2m2yba.js → chunk-wgfnd174.js} +43 -32
- package/dist/chunk-wk1jw4dm.js +139 -0
- package/dist/chunk-wnpjc8hg.js +1018 -0
- package/dist/chunk-wv1t041q.js +151 -0
- package/dist/chunk-wvtmrmaj.js +130 -0
- package/dist/chunk-wyavftcj.js +103 -0
- package/dist/{chunk-4589pec2.js → chunk-x2dp18yj.js} +18 -46
- package/dist/{chunk-fj4hkg6k.js → chunk-x474ybns.js} +79 -110
- package/dist/chunk-x67cvhb8.js +134 -0
- package/dist/chunk-x6r4v44b.js +8 -0
- package/dist/{chunk-s0xfxkys.js → chunk-xk9pxqqx.js} +6 -6
- package/dist/{chunk-m06q12hg.js → chunk-xkt36p6r.js} +1 -1
- package/dist/{chunk-g653q217.js → chunk-xnav6j8h.js} +62 -374
- package/dist/chunk-xrjb0zyc.js +146 -0
- package/dist/chunk-xv3era3s.js +8 -0
- package/dist/{chunk-p7g7pf3f.js → chunk-y3r7v9pq.js} +4 -4
- package/dist/{chunk-3sagmdbp.js → chunk-y4szkj7r.js} +80 -64
- package/dist/{chunk-7d2700y8.js → chunk-y8syxjw1.js} +24 -54
- package/dist/chunk-y98z50mm.js +158 -0
- package/dist/chunk-ycrfxq10.js +123 -0
- package/dist/{chunk-8440dz44.js → chunk-yfjzdc0q.js} +9 -9
- package/dist/{chunk-cejskpky.js → chunk-ygf7pmmr.js} +145 -153
- package/dist/chunk-yha3z3ab.js +259 -0
- package/dist/chunk-ym5r3jnk.js +2007 -0
- package/dist/{chunk-28r6z9br.js → chunk-ys2gtqb0.js} +1 -3
- package/dist/{chunk-rzgtgtaf.js → chunk-ytg2n0dd.js} +7 -7
- package/dist/{chunk-q5hb65kq.js → chunk-ytzw9kw1.js} +78 -62
- package/dist/chunk-yzx3mhfd.js +110 -0
- package/dist/chunk-z1bs6d7k.js +24 -0
- package/dist/{chunk-6h9zcxaa.js → chunk-z1mvcq39.js} +4 -4
- package/dist/{chunk-gbq6jz9a.js → chunk-z3qhctbk.js} +134 -170
- package/dist/chunk-z9jn3442.js +146 -0
- package/dist/{chunk-5q7c8vt9.js → chunk-zbsz51qa.js} +41 -32
- package/dist/{chunk-n1erf6kh.js → chunk-ze6zvkg6.js} +5 -5
- package/dist/{chunk-t0rgmccj.js → chunk-zejm280k.js} +1 -1
- package/dist/{chunk-gfkppe34.js → chunk-zf47p99b.js} +10 -10
- package/dist/{chunk-53nbpp47.js → chunk-zhtrjznv.js} +557 -1502
- package/dist/{chunk-das977za.js → chunk-zq6tz1zv.js} +61 -100
- package/dist/chunk-zrw9gm80.js +264 -0
- package/dist/chunk-zseb1639.js +37 -0
- package/dist/{chunk-spqaamnc.js → chunk-zsgha506.js} +2 -2
- package/dist/chunk-zst7b4sp.js +2840 -0
- package/dist/{chunk-0xn1zr3e.js → chunk-zxkzzpgd.js} +145 -121
- package/dist/{chunk-g3t0act8.js → chunk-zzm33q8x.js} +1 -1
- package/dist/cli.js +20 -117
- package/dist/download-ripgrep.js +24821 -0
- package/dist/vendor/audio-capture/arm64-darwin/audio-capture.node +0 -0
- package/dist/vendor/audio-capture/arm64-linux/audio-capture.node +0 -0
- package/dist/vendor/audio-capture/arm64-win32/audio-capture.node +0 -0
- package/dist/vendor/audio-capture/x64-darwin/audio-capture.node +0 -0
- package/dist/vendor/audio-capture/x64-linux/audio-capture.node +0 -0
- package/dist/vendor/audio-capture/x64-win32/audio-capture.node +0 -0
- package/package.json +22 -14
- package/scripts/download-ripgrep.ts +335 -0
- package/scripts/postinstall.cjs +319 -0
- package/dist/chunk-0gemty6d.js +0 -70
- package/dist/chunk-0pjw8y9z.js +0 -2833
- package/dist/chunk-1c8z1b5v.js +0 -16
- package/dist/chunk-1ebedmba.js +0 -90
- package/dist/chunk-1rvz0433.js +0 -722
- package/dist/chunk-1wfb8e3m.js +0 -107
- package/dist/chunk-2qjywwq4.js +0 -3445
- package/dist/chunk-2y659zbj.js +0 -103
- package/dist/chunk-41md7gny.js +0 -91
- package/dist/chunk-45m062tx.js +0 -2058
- package/dist/chunk-4br37gsw.js +0 -107
- package/dist/chunk-4nfrc6sq.js +0 -2431
- package/dist/chunk-4pdedeb4.js +0 -2644
- package/dist/chunk-4wzyhqbt.js +0 -444
- package/dist/chunk-4zsw4fhp.js +0 -67
- package/dist/chunk-52wv09zw.js +0 -102
- package/dist/chunk-55sfqnz4.js +0 -1921
- package/dist/chunk-5cd9cptq.js +0 -110
- package/dist/chunk-5dbk24zg.js +0 -890
- package/dist/chunk-5tfppbkq.js +0 -55
- package/dist/chunk-60xyrp86.js +0 -117
- package/dist/chunk-6deqb0mc.js +0 -376
- package/dist/chunk-6kpbgc5w.js +0 -23
- package/dist/chunk-6ndpfxcn.js +0 -222
- package/dist/chunk-7nvpa5ex.js +0 -123
- package/dist/chunk-7va8tw32.js +0 -128
- package/dist/chunk-7z3tkgec.js +0 -66
- package/dist/chunk-8e8set87.js +0 -281
- package/dist/chunk-8fg1egbv.js +0 -107
- package/dist/chunk-8thd6sgk.js +0 -106
- package/dist/chunk-8ytkb7k9.js +0 -84
- package/dist/chunk-9s5nkgsg.js +0 -699
- package/dist/chunk-9wce9hrc.js +0 -1015
- package/dist/chunk-9y91z69v.js +0 -44
- package/dist/chunk-ae76ded0.js +0 -30
- package/dist/chunk-b0eez8w0.js +0 -169
- package/dist/chunk-b57sb1dw.js +0 -642
- package/dist/chunk-bg3mt9bm.js +0 -28
- package/dist/chunk-bhdt6k7w.js +0 -15
- package/dist/chunk-bm1qb16p.js +0 -17
- package/dist/chunk-bsbmmfyt.js +0 -17
- package/dist/chunk-c7q12yes.js +0 -269
- package/dist/chunk-cv6y320h.js +0 -299
- package/dist/chunk-cvy3vntc.js +0 -65
- package/dist/chunk-cy2hswr1.js +0 -15
- package/dist/chunk-d5d398m4.js +0 -184
- package/dist/chunk-d7q4zp2z.js +0 -89
- package/dist/chunk-dnk519qv.js +0 -94
- package/dist/chunk-dqqde43e.js +0 -93
- package/dist/chunk-dy4ayw0p.js +0 -522
- package/dist/chunk-e4ak3jfc.js +0 -1154
- package/dist/chunk-e64spn53.js +0 -283
- package/dist/chunk-e8pk14j0.js +0 -527
- package/dist/chunk-eashsrsv.js +0 -88
- package/dist/chunk-eb90vwvr.js +0 -152
- package/dist/chunk-ese2g7hc.js +0 -92
- package/dist/chunk-et4jnyb5.js +0 -713
- package/dist/chunk-fdy0651p.js +0 -212
- package/dist/chunk-frsyts9j.js +0 -1170
- package/dist/chunk-ft2jssz4.js +0 -424
- package/dist/chunk-g41hzcy2.js +0 -101
- package/dist/chunk-g8dr8vvj.js +0 -111
- package/dist/chunk-gj71pd83.js +0 -5395
- package/dist/chunk-gjdwtdch.js +0 -154
- package/dist/chunk-gyj242zr.js +0 -20
- package/dist/chunk-hr719wjg.js +0 -144
- package/dist/chunk-hs8ph4p8.js +0 -8
- package/dist/chunk-j7gpr82p.js +0 -105
- package/dist/chunk-jczedp5x.js +0 -91
- package/dist/chunk-jd0t67a6.js +0 -259
- package/dist/chunk-jgyp3mzg.js +0 -1318
- package/dist/chunk-jq1kp9yy.js +0 -90
- package/dist/chunk-jskhn7bz.js +0 -71
- package/dist/chunk-k5aas9d3.js +0 -6108
- package/dist/chunk-k8jcy7mj.js +0 -48
- package/dist/chunk-ka22ccvm.js +0 -1581
- package/dist/chunk-ka6jav10.js +0 -91
- package/dist/chunk-kq6j096k.js +0 -538
- package/dist/chunk-kqd0e3xj.js +0 -463
- package/dist/chunk-kqjrsah4.js +0 -85
- package/dist/chunk-m390jta5.js +0 -114
- package/dist/chunk-m44a9yfj.js +0 -90
- package/dist/chunk-m5c8ng6v.js +0 -328
- package/dist/chunk-meag7bbe.js +0 -89
- package/dist/chunk-mnsrmwn8.js +0 -604
- package/dist/chunk-mzj4mtye.js +0 -115
- package/dist/chunk-mzy911jq.js +0 -128
- package/dist/chunk-n0fwapk6.js +0 -347
- package/dist/chunk-nt0mgsh6.js +0 -496
- package/dist/chunk-nwcfrws3.js +0 -273
- package/dist/chunk-pa2xksyb.js +0 -57
- package/dist/chunk-pnhs96g8.js +0 -140
- package/dist/chunk-ps4c75j7.js +0 -105
- package/dist/chunk-q0yg73za.js +0 -490
- package/dist/chunk-q5by3da6.js +0 -8
- package/dist/chunk-qbmhde47.js +0 -92
- package/dist/chunk-qp3dw7b4.js +0 -100
- package/dist/chunk-qt0b9x2w.js +0 -42
- package/dist/chunk-qxe98jgk.js +0 -584
- package/dist/chunk-r7n42k56.js +0 -756
- package/dist/chunk-radsjrmv.js +0 -55
- package/dist/chunk-rckj9gd1.js +0 -55
- package/dist/chunk-rn4kqfvd.js +0 -99
- package/dist/chunk-rngmdt2v.js +0 -97
- package/dist/chunk-rs5e0520.js +0 -87
- package/dist/chunk-s274nv8k.js +0 -8
- package/dist/chunk-s7t2e2tw.js +0 -1493
- package/dist/chunk-sbbt0ct3.js +0 -90
- package/dist/chunk-t0mnk0qp.js +0 -105
- package/dist/chunk-t1qmy36p.js +0 -94
- package/dist/chunk-tdy66rf9.js +0 -116
- package/dist/chunk-tf40vqky.js +0 -70
- package/dist/chunk-tmcxeatp.js +0 -116
- package/dist/chunk-v3gm2day.js +0 -8
- package/dist/chunk-v496te8v.js +0 -192
- package/dist/chunk-vd2hwk8d.js +0 -61
- package/dist/chunk-vdsmt7v0.js +0 -998
- package/dist/chunk-vf3qxte3.js +0 -93
- package/dist/chunk-vfqe1jqj.js +0 -643
- package/dist/chunk-vk3270s6.js +0 -119
- package/dist/chunk-vsr9mbnq.js +0 -195
- package/dist/chunk-w18zryr9.js +0 -348
- package/dist/chunk-wdxcgk6m.js +0 -196
- package/dist/chunk-wef07p3j.js +0 -131
- package/dist/chunk-wf4q1xj3.js +0 -62
- package/dist/chunk-wjq4zq3t.js +0 -162
- package/dist/chunk-wp4hc4n7.js +0 -133
- package/dist/chunk-x0rjttct.js +0 -420
- package/dist/chunk-xdw5dv00.js +0 -8
- package/dist/chunk-xm8fv5c9.js +0 -469
- package/dist/chunk-xq5ztz4g.js +0 -130
- package/dist/chunk-xvcdtezw.js +0 -401
- package/dist/chunk-y7njq3z3.js +0 -1866
- package/dist/chunk-ycxwftfh.js +0 -97
- package/dist/chunk-yn38f69a.js +0 -105
- package/dist/chunk-yp5kc8hq.js +0 -372
- package/dist/chunk-z09n2krq.js +0 -752
- package/dist/chunk-zerg8qwf.js +0 -96
- package/dist/{chunk-p452k1xp.js → chunk-57s5mr32.js} +9 -9
- package/dist/{chunk-27xc1csx.js → chunk-dggvswz1.js} +3 -3
- package/dist/{chunk-zxzwfa0b.js → chunk-pbyq1tm3.js} +3 -3
package/dist/chunk-0pjw8y9z.js
DELETED
|
@@ -1,2833 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import {
|
|
3
|
-
Messages,
|
|
4
|
-
init_Messages
|
|
5
|
-
} from "./chunk-drrw55jr.js";
|
|
6
|
-
import {
|
|
7
|
-
LoadingState,
|
|
8
|
-
init_LoadingState
|
|
9
|
-
} from "./chunk-ycxwftfh.js";
|
|
10
|
-
import {
|
|
11
|
-
SearchBox,
|
|
12
|
-
init_SearchBox,
|
|
13
|
-
init_useSearchInput,
|
|
14
|
-
useSearchInput
|
|
15
|
-
} from "./chunk-f1rrxxcf.js";
|
|
16
|
-
import {
|
|
17
|
-
Select,
|
|
18
|
-
Spinner,
|
|
19
|
-
TextInput,
|
|
20
|
-
getAllBaseTools,
|
|
21
|
-
getFirstMeaningfulUserMessageTextContent,
|
|
22
|
-
getSessionIdFromLog,
|
|
23
|
-
getWorktreePaths,
|
|
24
|
-
init_Spinner,
|
|
25
|
-
init_TextInput,
|
|
26
|
-
init_getWorktreePaths,
|
|
27
|
-
init_select,
|
|
28
|
-
init_sessionStorage,
|
|
29
|
-
init_shellQuote,
|
|
30
|
-
init_sideQuery,
|
|
31
|
-
init_tools1 as init_tools,
|
|
32
|
-
isCustomTitleEnabled,
|
|
33
|
-
isLiteLog,
|
|
34
|
-
loadFullLog,
|
|
35
|
-
quote,
|
|
36
|
-
saveCustomTitle,
|
|
37
|
-
sideQuery
|
|
38
|
-
} from "./chunk-5frcqxsv.js";
|
|
39
|
-
import {
|
|
40
|
-
Byline,
|
|
41
|
-
ConfigurableShortcutHint,
|
|
42
|
-
KeyboardShortcutHint,
|
|
43
|
-
init_Byline,
|
|
44
|
-
init_ConfigurableShortcutHint,
|
|
45
|
-
init_KeyboardShortcutHint
|
|
46
|
-
} from "./chunk-kqd0e3xj.js";
|
|
47
|
-
import {
|
|
48
|
-
init_useExitOnCtrlCDWithKeybindings,
|
|
49
|
-
useExitOnCtrlCDWithKeybindings
|
|
50
|
-
} from "./chunk-rn4kqfvd.js";
|
|
51
|
-
import {
|
|
52
|
-
Divider,
|
|
53
|
-
init_Divider,
|
|
54
|
-
init_useKeybinding,
|
|
55
|
-
init_useTerminalSize,
|
|
56
|
-
useKeybinding,
|
|
57
|
-
useTerminalSize
|
|
58
|
-
} from "./chunk-g653q217.js";
|
|
59
|
-
import {
|
|
60
|
-
ThemedBox_default,
|
|
61
|
-
ThemedText,
|
|
62
|
-
applyColor,
|
|
63
|
-
getTheme,
|
|
64
|
-
init_colorize,
|
|
65
|
-
init_ink,
|
|
66
|
-
init_theme,
|
|
67
|
-
require_compiler_runtime,
|
|
68
|
-
useTerminalFocus,
|
|
69
|
-
useTheme,
|
|
70
|
-
use_input_default
|
|
71
|
-
} from "./chunk-z72st5c8.js";
|
|
72
|
-
import {
|
|
73
|
-
require_jsx_dev_runtime,
|
|
74
|
-
require_react
|
|
75
|
-
} from "./chunk-g338npwr.js";
|
|
76
|
-
import {
|
|
77
|
-
getSmallFastModel,
|
|
78
|
-
init_model,
|
|
79
|
-
init_source,
|
|
80
|
-
source_default
|
|
81
|
-
} from "./chunk-53nbpp47.js";
|
|
82
|
-
import {
|
|
83
|
-
count,
|
|
84
|
-
init_array
|
|
85
|
-
} from "./chunk-0e1xsncc.js";
|
|
86
|
-
import {
|
|
87
|
-
formatLogMetadata,
|
|
88
|
-
formatRelativeTimeAgo,
|
|
89
|
-
init_format,
|
|
90
|
-
init_stringWidth,
|
|
91
|
-
stringWidth,
|
|
92
|
-
truncateToWidth
|
|
93
|
-
} from "./chunk-1rvz0433.js";
|
|
94
|
-
import {
|
|
95
|
-
init_analytics,
|
|
96
|
-
logEvent
|
|
97
|
-
} from "./chunk-f2mhrmww.js";
|
|
98
|
-
import {
|
|
99
|
-
getBranch,
|
|
100
|
-
init_git
|
|
101
|
-
} from "./chunk-hrzerbfw.js";
|
|
102
|
-
import {
|
|
103
|
-
getLogDisplayTitle,
|
|
104
|
-
init_log,
|
|
105
|
-
logError
|
|
106
|
-
} from "./chunk-p7g7pf3f.js";
|
|
107
|
-
import {
|
|
108
|
-
init_debug,
|
|
109
|
-
init_slowOperations,
|
|
110
|
-
jsonParse,
|
|
111
|
-
logForDebugging
|
|
112
|
-
} from "./chunk-nxsh6de2.js";
|
|
113
|
-
import {
|
|
114
|
-
getOriginalCwd,
|
|
115
|
-
getSessionId,
|
|
116
|
-
init_state
|
|
117
|
-
} from "./chunk-qqfa0dqg.js";
|
|
118
|
-
import {
|
|
119
|
-
__esm,
|
|
120
|
-
__toESM
|
|
121
|
-
} from "./chunk-qp2qdcda.js";
|
|
122
|
-
|
|
123
|
-
// src/components/SessionPreview.tsx
|
|
124
|
-
function SessionPreview(t0) {
|
|
125
|
-
const $ = import_compiler_runtime.c(33);
|
|
126
|
-
const {
|
|
127
|
-
log,
|
|
128
|
-
onExit,
|
|
129
|
-
onSelect
|
|
130
|
-
} = t0;
|
|
131
|
-
const [fullLog, setFullLog] = import_react.default.useState(null);
|
|
132
|
-
let t1;
|
|
133
|
-
let t2;
|
|
134
|
-
if ($[0] !== log) {
|
|
135
|
-
t1 = () => {
|
|
136
|
-
setFullLog(null);
|
|
137
|
-
if (isLiteLog(log)) {
|
|
138
|
-
loadFullLog(log).then(setFullLog);
|
|
139
|
-
}
|
|
140
|
-
};
|
|
141
|
-
t2 = [log];
|
|
142
|
-
$[0] = log;
|
|
143
|
-
$[1] = t1;
|
|
144
|
-
$[2] = t2;
|
|
145
|
-
} else {
|
|
146
|
-
t1 = $[1];
|
|
147
|
-
t2 = $[2];
|
|
148
|
-
}
|
|
149
|
-
import_react.default.useEffect(t1, t2);
|
|
150
|
-
const isLoading = isLiteLog(log) && fullLog === null;
|
|
151
|
-
const displayLog = fullLog ?? log;
|
|
152
|
-
let t3;
|
|
153
|
-
if ($[3] !== displayLog) {
|
|
154
|
-
t3 = getSessionIdFromLog(displayLog) || "";
|
|
155
|
-
$[3] = displayLog;
|
|
156
|
-
$[4] = t3;
|
|
157
|
-
} else {
|
|
158
|
-
t3 = $[4];
|
|
159
|
-
}
|
|
160
|
-
const conversationId = t3;
|
|
161
|
-
let t4;
|
|
162
|
-
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
163
|
-
t4 = getAllBaseTools();
|
|
164
|
-
$[5] = t4;
|
|
165
|
-
} else {
|
|
166
|
-
t4 = $[5];
|
|
167
|
-
}
|
|
168
|
-
const tools = t4;
|
|
169
|
-
let t5;
|
|
170
|
-
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
171
|
-
t5 = {
|
|
172
|
-
context: "Confirmation"
|
|
173
|
-
};
|
|
174
|
-
$[6] = t5;
|
|
175
|
-
} else {
|
|
176
|
-
t5 = $[6];
|
|
177
|
-
}
|
|
178
|
-
useKeybinding("confirm:no", onExit, t5);
|
|
179
|
-
let t6;
|
|
180
|
-
if ($[7] !== fullLog || $[8] !== log || $[9] !== onSelect) {
|
|
181
|
-
t6 = () => {
|
|
182
|
-
onSelect(fullLog ?? log);
|
|
183
|
-
};
|
|
184
|
-
$[7] = fullLog;
|
|
185
|
-
$[8] = log;
|
|
186
|
-
$[9] = onSelect;
|
|
187
|
-
$[10] = t6;
|
|
188
|
-
} else {
|
|
189
|
-
t6 = $[10];
|
|
190
|
-
}
|
|
191
|
-
const handleSelect = t6;
|
|
192
|
-
let t7;
|
|
193
|
-
if ($[11] === Symbol.for("react.memo_cache_sentinel")) {
|
|
194
|
-
t7 = {
|
|
195
|
-
context: "Confirmation"
|
|
196
|
-
};
|
|
197
|
-
$[11] = t7;
|
|
198
|
-
} else {
|
|
199
|
-
t7 = $[11];
|
|
200
|
-
}
|
|
201
|
-
useKeybinding("confirm:yes", handleSelect, t7);
|
|
202
|
-
if (isLoading) {
|
|
203
|
-
let t82;
|
|
204
|
-
if ($[12] === Symbol.for("react.memo_cache_sentinel")) {
|
|
205
|
-
t82 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(LoadingState, {
|
|
206
|
-
message: "Loading session\u2026"
|
|
207
|
-
}, undefined, false, undefined, this);
|
|
208
|
-
$[12] = t82;
|
|
209
|
-
} else {
|
|
210
|
-
t82 = $[12];
|
|
211
|
-
}
|
|
212
|
-
let t92;
|
|
213
|
-
if ($[13] === Symbol.for("react.memo_cache_sentinel")) {
|
|
214
|
-
t92 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(ThemedBox_default, {
|
|
215
|
-
flexDirection: "column",
|
|
216
|
-
padding: 1,
|
|
217
|
-
children: [
|
|
218
|
-
t82,
|
|
219
|
-
/* @__PURE__ */ jsx_dev_runtime.jsxDEV(ThemedText, {
|
|
220
|
-
dimColor: true,
|
|
221
|
-
children: /* @__PURE__ */ jsx_dev_runtime.jsxDEV(Byline, {
|
|
222
|
-
children: /* @__PURE__ */ jsx_dev_runtime.jsxDEV(ConfigurableShortcutHint, {
|
|
223
|
-
action: "confirm:no",
|
|
224
|
-
context: "Confirmation",
|
|
225
|
-
fallback: "Esc",
|
|
226
|
-
description: "cancel"
|
|
227
|
-
}, undefined, false, undefined, this)
|
|
228
|
-
}, undefined, false, undefined, this)
|
|
229
|
-
}, undefined, false, undefined, this)
|
|
230
|
-
]
|
|
231
|
-
}, undefined, true, undefined, this);
|
|
232
|
-
$[13] = t92;
|
|
233
|
-
} else {
|
|
234
|
-
t92 = $[13];
|
|
235
|
-
}
|
|
236
|
-
return t92;
|
|
237
|
-
}
|
|
238
|
-
let t8;
|
|
239
|
-
if ($[14] === Symbol.for("react.memo_cache_sentinel")) {
|
|
240
|
-
t8 = [];
|
|
241
|
-
$[14] = t8;
|
|
242
|
-
} else {
|
|
243
|
-
t8 = $[14];
|
|
244
|
-
}
|
|
245
|
-
let t10;
|
|
246
|
-
let t9;
|
|
247
|
-
if ($[15] === Symbol.for("react.memo_cache_sentinel")) {
|
|
248
|
-
t9 = [];
|
|
249
|
-
t10 = new Set;
|
|
250
|
-
$[15] = t10;
|
|
251
|
-
$[16] = t9;
|
|
252
|
-
} else {
|
|
253
|
-
t10 = $[15];
|
|
254
|
-
t9 = $[16];
|
|
255
|
-
}
|
|
256
|
-
let t11;
|
|
257
|
-
if ($[17] === Symbol.for("react.memo_cache_sentinel")) {
|
|
258
|
-
t11 = [];
|
|
259
|
-
$[17] = t11;
|
|
260
|
-
} else {
|
|
261
|
-
t11 = $[17];
|
|
262
|
-
}
|
|
263
|
-
let t12;
|
|
264
|
-
if ($[18] !== conversationId || $[19] !== displayLog.messages) {
|
|
265
|
-
t12 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(Messages, {
|
|
266
|
-
messages: displayLog.messages,
|
|
267
|
-
tools,
|
|
268
|
-
commands: t8,
|
|
269
|
-
verbose: true,
|
|
270
|
-
toolJSX: null,
|
|
271
|
-
toolUseConfirmQueue: t9,
|
|
272
|
-
inProgressToolUseIDs: t10,
|
|
273
|
-
isMessageSelectorVisible: false,
|
|
274
|
-
conversationId,
|
|
275
|
-
screen: "transcript",
|
|
276
|
-
streamingToolUses: t11,
|
|
277
|
-
showAllInTranscript: true,
|
|
278
|
-
isLoading: false
|
|
279
|
-
}, undefined, false, undefined, this);
|
|
280
|
-
$[18] = conversationId;
|
|
281
|
-
$[19] = displayLog.messages;
|
|
282
|
-
$[20] = t12;
|
|
283
|
-
} else {
|
|
284
|
-
t12 = $[20];
|
|
285
|
-
}
|
|
286
|
-
let t13;
|
|
287
|
-
if ($[21] !== displayLog.modified) {
|
|
288
|
-
t13 = formatRelativeTimeAgo(displayLog.modified);
|
|
289
|
-
$[21] = displayLog.modified;
|
|
290
|
-
$[22] = t13;
|
|
291
|
-
} else {
|
|
292
|
-
t13 = $[22];
|
|
293
|
-
}
|
|
294
|
-
const t14 = displayLog.gitBranch ? ` \xB7 ${displayLog.gitBranch}` : "";
|
|
295
|
-
let t15;
|
|
296
|
-
if ($[23] !== displayLog.messageCount || $[24] !== t13 || $[25] !== t14) {
|
|
297
|
-
t15 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(ThemedText, {
|
|
298
|
-
children: [
|
|
299
|
-
t13,
|
|
300
|
-
" \xB7",
|
|
301
|
-
" ",
|
|
302
|
-
displayLog.messageCount,
|
|
303
|
-
" messages",
|
|
304
|
-
t14
|
|
305
|
-
]
|
|
306
|
-
}, undefined, true, undefined, this);
|
|
307
|
-
$[23] = displayLog.messageCount;
|
|
308
|
-
$[24] = t13;
|
|
309
|
-
$[25] = t14;
|
|
310
|
-
$[26] = t15;
|
|
311
|
-
} else {
|
|
312
|
-
t15 = $[26];
|
|
313
|
-
}
|
|
314
|
-
let t16;
|
|
315
|
-
if ($[27] === Symbol.for("react.memo_cache_sentinel")) {
|
|
316
|
-
t16 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(ThemedText, {
|
|
317
|
-
dimColor: true,
|
|
318
|
-
children: /* @__PURE__ */ jsx_dev_runtime.jsxDEV(Byline, {
|
|
319
|
-
children: [
|
|
320
|
-
/* @__PURE__ */ jsx_dev_runtime.jsxDEV(KeyboardShortcutHint, {
|
|
321
|
-
shortcut: "Enter",
|
|
322
|
-
action: "resume"
|
|
323
|
-
}, undefined, false, undefined, this),
|
|
324
|
-
/* @__PURE__ */ jsx_dev_runtime.jsxDEV(ConfigurableShortcutHint, {
|
|
325
|
-
action: "confirm:no",
|
|
326
|
-
context: "Confirmation",
|
|
327
|
-
fallback: "Esc",
|
|
328
|
-
description: "cancel"
|
|
329
|
-
}, undefined, false, undefined, this)
|
|
330
|
-
]
|
|
331
|
-
}, undefined, true, undefined, this)
|
|
332
|
-
}, undefined, false, undefined, this);
|
|
333
|
-
$[27] = t16;
|
|
334
|
-
} else {
|
|
335
|
-
t16 = $[27];
|
|
336
|
-
}
|
|
337
|
-
let t17;
|
|
338
|
-
if ($[28] !== t15) {
|
|
339
|
-
t17 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(ThemedBox_default, {
|
|
340
|
-
flexShrink: 0,
|
|
341
|
-
flexDirection: "column",
|
|
342
|
-
borderTopDimColor: true,
|
|
343
|
-
borderBottom: false,
|
|
344
|
-
borderLeft: false,
|
|
345
|
-
borderRight: false,
|
|
346
|
-
borderStyle: "single",
|
|
347
|
-
paddingLeft: 2,
|
|
348
|
-
children: [
|
|
349
|
-
t15,
|
|
350
|
-
t16
|
|
351
|
-
]
|
|
352
|
-
}, undefined, true, undefined, this);
|
|
353
|
-
$[28] = t15;
|
|
354
|
-
$[29] = t17;
|
|
355
|
-
} else {
|
|
356
|
-
t17 = $[29];
|
|
357
|
-
}
|
|
358
|
-
let t18;
|
|
359
|
-
if ($[30] !== t12 || $[31] !== t17) {
|
|
360
|
-
t18 = /* @__PURE__ */ jsx_dev_runtime.jsxDEV(ThemedBox_default, {
|
|
361
|
-
flexDirection: "column",
|
|
362
|
-
children: [
|
|
363
|
-
t12,
|
|
364
|
-
t17
|
|
365
|
-
]
|
|
366
|
-
}, undefined, true, undefined, this);
|
|
367
|
-
$[30] = t12;
|
|
368
|
-
$[31] = t17;
|
|
369
|
-
$[32] = t18;
|
|
370
|
-
} else {
|
|
371
|
-
t18 = $[32];
|
|
372
|
-
}
|
|
373
|
-
return t18;
|
|
374
|
-
}
|
|
375
|
-
var import_compiler_runtime, import_react, jsx_dev_runtime;
|
|
376
|
-
var init_SessionPreview = __esm(() => {
|
|
377
|
-
init_ink();
|
|
378
|
-
init_useKeybinding();
|
|
379
|
-
init_tools();
|
|
380
|
-
init_format();
|
|
381
|
-
init_sessionStorage();
|
|
382
|
-
init_ConfigurableShortcutHint();
|
|
383
|
-
init_Byline();
|
|
384
|
-
init_KeyboardShortcutHint();
|
|
385
|
-
init_LoadingState();
|
|
386
|
-
init_Messages();
|
|
387
|
-
import_compiler_runtime = __toESM(require_compiler_runtime(), 1);
|
|
388
|
-
import_react = __toESM(require_react(), 1);
|
|
389
|
-
jsx_dev_runtime = __toESM(require_jsx_dev_runtime(), 1);
|
|
390
|
-
});
|
|
391
|
-
|
|
392
|
-
// src/components/TagTabs.tsx
|
|
393
|
-
function getTabWidth(tab, maxWidth) {
|
|
394
|
-
if (tab === ALL_TAB_LABEL) {
|
|
395
|
-
return ALL_TAB_LABEL.length + TAB_PADDING;
|
|
396
|
-
}
|
|
397
|
-
const tagWidth = stringWidth(tab);
|
|
398
|
-
const effectiveTagWidth = maxWidth ? Math.min(tagWidth, maxWidth - TAB_PADDING - HASH_PREFIX_LENGTH) : tagWidth;
|
|
399
|
-
return Math.max(0, effectiveTagWidth) + TAB_PADDING + HASH_PREFIX_LENGTH;
|
|
400
|
-
}
|
|
401
|
-
function truncateTag(tag, maxWidth) {
|
|
402
|
-
const availableForTag = maxWidth - TAB_PADDING - HASH_PREFIX_LENGTH;
|
|
403
|
-
if (stringWidth(tag) <= availableForTag) {
|
|
404
|
-
return tag;
|
|
405
|
-
}
|
|
406
|
-
if (availableForTag <= 1) {
|
|
407
|
-
return tag.charAt(0);
|
|
408
|
-
}
|
|
409
|
-
return truncateToWidth(tag, availableForTag);
|
|
410
|
-
}
|
|
411
|
-
function TagTabs({
|
|
412
|
-
tabs,
|
|
413
|
-
selectedIndex,
|
|
414
|
-
availableWidth,
|
|
415
|
-
showAllProjects = false
|
|
416
|
-
}) {
|
|
417
|
-
const resumeLabel = showAllProjects ? "Resume (All Projects)" : "Resume";
|
|
418
|
-
const resumeLabelWidth = resumeLabel.length + 1;
|
|
419
|
-
const rightHintWidth = Math.max(RIGHT_HINT_WIDTH_WITH_COUNT, RIGHT_HINT_WIDTH_NO_COUNT);
|
|
420
|
-
const maxTabsWidth = availableWidth - resumeLabelWidth - rightHintWidth - 2;
|
|
421
|
-
const safeSelectedIndex = Math.max(0, Math.min(selectedIndex, tabs.length - 1));
|
|
422
|
-
const maxSingleTabWidth = Math.max(20, Math.floor(maxTabsWidth / 2));
|
|
423
|
-
const tabWidths = tabs.map((tab) => getTabWidth(tab, maxSingleTabWidth));
|
|
424
|
-
let startIndex = 0;
|
|
425
|
-
let endIndex = tabs.length;
|
|
426
|
-
const totalTabsWidth = tabWidths.reduce((sum, w, i) => sum + w + (i < tabWidths.length - 1 ? 1 : 0), 0);
|
|
427
|
-
if (totalTabsWidth > maxTabsWidth) {
|
|
428
|
-
const effectiveMaxWidth = maxTabsWidth - LEFT_ARROW_WIDTH;
|
|
429
|
-
let windowWidth = tabWidths[safeSelectedIndex] ?? 0;
|
|
430
|
-
startIndex = safeSelectedIndex;
|
|
431
|
-
endIndex = safeSelectedIndex + 1;
|
|
432
|
-
while (startIndex > 0 || endIndex < tabs.length) {
|
|
433
|
-
const canExpandLeft = startIndex > 0;
|
|
434
|
-
const canExpandRight = endIndex < tabs.length;
|
|
435
|
-
if (canExpandLeft) {
|
|
436
|
-
const leftWidth = (tabWidths[startIndex - 1] ?? 0) + 1;
|
|
437
|
-
if (windowWidth + leftWidth <= effectiveMaxWidth) {
|
|
438
|
-
startIndex--;
|
|
439
|
-
windowWidth += leftWidth;
|
|
440
|
-
continue;
|
|
441
|
-
}
|
|
442
|
-
}
|
|
443
|
-
if (canExpandRight) {
|
|
444
|
-
const rightWidth = (tabWidths[endIndex] ?? 0) + 1;
|
|
445
|
-
if (windowWidth + rightWidth <= effectiveMaxWidth) {
|
|
446
|
-
endIndex++;
|
|
447
|
-
windowWidth += rightWidth;
|
|
448
|
-
continue;
|
|
449
|
-
}
|
|
450
|
-
}
|
|
451
|
-
break;
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
const hiddenLeft = startIndex;
|
|
455
|
-
const hiddenRight = tabs.length - endIndex;
|
|
456
|
-
const visibleTabs = tabs.slice(startIndex, endIndex);
|
|
457
|
-
const visibleIndices = visibleTabs.map((_, i_0) => startIndex + i_0);
|
|
458
|
-
return /* @__PURE__ */ jsx_dev_runtime2.jsxDEV(ThemedBox_default, {
|
|
459
|
-
flexDirection: "row",
|
|
460
|
-
gap: 1,
|
|
461
|
-
children: [
|
|
462
|
-
/* @__PURE__ */ jsx_dev_runtime2.jsxDEV(ThemedText, {
|
|
463
|
-
color: "suggestion",
|
|
464
|
-
children: resumeLabel
|
|
465
|
-
}, undefined, false, undefined, this),
|
|
466
|
-
hiddenLeft > 0 && /* @__PURE__ */ jsx_dev_runtime2.jsxDEV(ThemedText, {
|
|
467
|
-
dimColor: true,
|
|
468
|
-
children: [
|
|
469
|
-
LEFT_ARROW_PREFIX,
|
|
470
|
-
hiddenLeft
|
|
471
|
-
]
|
|
472
|
-
}, undefined, true, undefined, this),
|
|
473
|
-
visibleTabs.map((tab_0, i_1) => {
|
|
474
|
-
const actualIndex = visibleIndices[i_1];
|
|
475
|
-
const isSelected = actualIndex === safeSelectedIndex;
|
|
476
|
-
const displayText = tab_0 === ALL_TAB_LABEL ? tab_0 : `#${truncateTag(tab_0, maxSingleTabWidth - TAB_PADDING)}`;
|
|
477
|
-
return /* @__PURE__ */ jsx_dev_runtime2.jsxDEV(ThemedText, {
|
|
478
|
-
backgroundColor: isSelected ? "suggestion" : undefined,
|
|
479
|
-
color: isSelected ? "inverseText" : undefined,
|
|
480
|
-
bold: isSelected,
|
|
481
|
-
children: [
|
|
482
|
-
" ",
|
|
483
|
-
displayText,
|
|
484
|
-
" "
|
|
485
|
-
]
|
|
486
|
-
}, tab_0, true, undefined, this);
|
|
487
|
-
}),
|
|
488
|
-
hiddenRight > 0 ? /* @__PURE__ */ jsx_dev_runtime2.jsxDEV(ThemedText, {
|
|
489
|
-
dimColor: true,
|
|
490
|
-
children: [
|
|
491
|
-
RIGHT_HINT_WITH_COUNT_PREFIX,
|
|
492
|
-
hiddenRight,
|
|
493
|
-
RIGHT_HINT_SUFFIX
|
|
494
|
-
]
|
|
495
|
-
}, undefined, true, undefined, this) : /* @__PURE__ */ jsx_dev_runtime2.jsxDEV(ThemedText, {
|
|
496
|
-
dimColor: true,
|
|
497
|
-
children: RIGHT_HINT_NO_COUNT
|
|
498
|
-
}, undefined, false, undefined, this)
|
|
499
|
-
]
|
|
500
|
-
}, undefined, true, undefined, this);
|
|
501
|
-
}
|
|
502
|
-
var jsx_dev_runtime2, ALL_TAB_LABEL = "All", TAB_PADDING = 2, HASH_PREFIX_LENGTH = 1, LEFT_ARROW_PREFIX = "\u2190 ", RIGHT_HINT_WITH_COUNT_PREFIX = "\u2192", RIGHT_HINT_SUFFIX = " (tab to cycle)", RIGHT_HINT_NO_COUNT = "(tab to cycle)", MAX_OVERFLOW_DIGITS = 2, LEFT_ARROW_WIDTH, RIGHT_HINT_WIDTH_WITH_COUNT, RIGHT_HINT_WIDTH_NO_COUNT;
|
|
503
|
-
var init_TagTabs = __esm(() => {
|
|
504
|
-
init_stringWidth();
|
|
505
|
-
init_ink();
|
|
506
|
-
init_format();
|
|
507
|
-
jsx_dev_runtime2 = __toESM(require_jsx_dev_runtime(), 1);
|
|
508
|
-
LEFT_ARROW_WIDTH = LEFT_ARROW_PREFIX.length + MAX_OVERFLOW_DIGITS + 1;
|
|
509
|
-
RIGHT_HINT_WIDTH_WITH_COUNT = RIGHT_HINT_WITH_COUNT_PREFIX.length + MAX_OVERFLOW_DIGITS + RIGHT_HINT_SUFFIX.length;
|
|
510
|
-
RIGHT_HINT_WIDTH_NO_COUNT = RIGHT_HINT_NO_COUNT.length;
|
|
511
|
-
});
|
|
512
|
-
|
|
513
|
-
// src/components/ui/TreeSelect.tsx
|
|
514
|
-
function TreeSelect(t0) {
|
|
515
|
-
const $ = import_compiler_runtime2.c(48);
|
|
516
|
-
const {
|
|
517
|
-
nodes,
|
|
518
|
-
onSelect,
|
|
519
|
-
onCancel,
|
|
520
|
-
onFocus,
|
|
521
|
-
focusNodeId,
|
|
522
|
-
visibleOptionCount,
|
|
523
|
-
layout: t1,
|
|
524
|
-
isDisabled: t2,
|
|
525
|
-
hideIndexes: t3,
|
|
526
|
-
isNodeExpanded,
|
|
527
|
-
onExpand,
|
|
528
|
-
onCollapse,
|
|
529
|
-
getParentPrefix,
|
|
530
|
-
getChildPrefix,
|
|
531
|
-
onUpFromFirstItem
|
|
532
|
-
} = t0;
|
|
533
|
-
const layout = t1 === undefined ? "expanded" : t1;
|
|
534
|
-
const isDisabled = t2 === undefined ? false : t2;
|
|
535
|
-
const hideIndexes = t3 === undefined ? false : t3;
|
|
536
|
-
let t4;
|
|
537
|
-
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
538
|
-
t4 = new Set;
|
|
539
|
-
$[0] = t4;
|
|
540
|
-
} else {
|
|
541
|
-
t4 = $[0];
|
|
542
|
-
}
|
|
543
|
-
const [internalExpandedIds, setInternalExpandedIds] = import_react2.default.useState(t4);
|
|
544
|
-
const isProgrammaticFocusRef = import_react2.default.useRef(false);
|
|
545
|
-
const lastFocusedIdRef = import_react2.default.useRef(null);
|
|
546
|
-
let t5;
|
|
547
|
-
if ($[1] !== internalExpandedIds || $[2] !== isNodeExpanded) {
|
|
548
|
-
t5 = (nodeId) => {
|
|
549
|
-
if (isNodeExpanded) {
|
|
550
|
-
return isNodeExpanded(nodeId);
|
|
551
|
-
}
|
|
552
|
-
return internalExpandedIds.has(nodeId);
|
|
553
|
-
};
|
|
554
|
-
$[1] = internalExpandedIds;
|
|
555
|
-
$[2] = isNodeExpanded;
|
|
556
|
-
$[3] = t5;
|
|
557
|
-
} else {
|
|
558
|
-
t5 = $[3];
|
|
559
|
-
}
|
|
560
|
-
const isExpanded = t5;
|
|
561
|
-
let result;
|
|
562
|
-
if ($[4] !== isExpanded || $[5] !== nodes) {
|
|
563
|
-
let traverse = function(node, depth, parentId) {
|
|
564
|
-
const hasChildren = !!node.children && node.children.length > 0;
|
|
565
|
-
const nodeIsExpanded = isExpanded(node.id);
|
|
566
|
-
result.push({
|
|
567
|
-
node,
|
|
568
|
-
depth,
|
|
569
|
-
isExpanded: nodeIsExpanded,
|
|
570
|
-
hasChildren,
|
|
571
|
-
parentId
|
|
572
|
-
});
|
|
573
|
-
if (hasChildren && nodeIsExpanded && node.children) {
|
|
574
|
-
for (const child of node.children) {
|
|
575
|
-
traverse(child, depth + 1, node.id);
|
|
576
|
-
}
|
|
577
|
-
}
|
|
578
|
-
};
|
|
579
|
-
result = [];
|
|
580
|
-
for (const node_0 of nodes) {
|
|
581
|
-
traverse(node_0, 0, undefined);
|
|
582
|
-
}
|
|
583
|
-
$[4] = isExpanded;
|
|
584
|
-
$[5] = nodes;
|
|
585
|
-
$[6] = result;
|
|
586
|
-
} else {
|
|
587
|
-
result = $[6];
|
|
588
|
-
}
|
|
589
|
-
const flattenedNodes = result;
|
|
590
|
-
const defaultGetParentPrefix = _temp;
|
|
591
|
-
const defaultGetChildPrefix = _temp2;
|
|
592
|
-
const parentPrefixFn = getParentPrefix ?? defaultGetParentPrefix;
|
|
593
|
-
const childPrefixFn = getChildPrefix ?? defaultGetChildPrefix;
|
|
594
|
-
let t6;
|
|
595
|
-
if ($[7] !== childPrefixFn || $[8] !== parentPrefixFn) {
|
|
596
|
-
t6 = (flatNode) => {
|
|
597
|
-
let prefix = "";
|
|
598
|
-
if (flatNode.hasChildren) {
|
|
599
|
-
prefix = parentPrefixFn(flatNode.isExpanded);
|
|
600
|
-
} else {
|
|
601
|
-
if (flatNode.depth > 0) {
|
|
602
|
-
prefix = childPrefixFn(flatNode.depth);
|
|
603
|
-
}
|
|
604
|
-
}
|
|
605
|
-
return prefix + flatNode.node.label;
|
|
606
|
-
};
|
|
607
|
-
$[7] = childPrefixFn;
|
|
608
|
-
$[8] = parentPrefixFn;
|
|
609
|
-
$[9] = t6;
|
|
610
|
-
} else {
|
|
611
|
-
t6 = $[9];
|
|
612
|
-
}
|
|
613
|
-
const buildLabel = t6;
|
|
614
|
-
let t7;
|
|
615
|
-
if ($[10] !== buildLabel || $[11] !== flattenedNodes) {
|
|
616
|
-
t7 = flattenedNodes.map((flatNode_0) => ({
|
|
617
|
-
label: buildLabel(flatNode_0),
|
|
618
|
-
description: flatNode_0.node.description,
|
|
619
|
-
dimDescription: flatNode_0.node.dimDescription ?? true,
|
|
620
|
-
value: flatNode_0.node.id
|
|
621
|
-
}));
|
|
622
|
-
$[10] = buildLabel;
|
|
623
|
-
$[11] = flattenedNodes;
|
|
624
|
-
$[12] = t7;
|
|
625
|
-
} else {
|
|
626
|
-
t7 = $[12];
|
|
627
|
-
}
|
|
628
|
-
const options = t7;
|
|
629
|
-
let map;
|
|
630
|
-
if ($[13] !== flattenedNodes) {
|
|
631
|
-
map = new Map;
|
|
632
|
-
flattenedNodes.forEach((fn) => map.set(fn.node.id, fn.node));
|
|
633
|
-
$[13] = flattenedNodes;
|
|
634
|
-
$[14] = map;
|
|
635
|
-
} else {
|
|
636
|
-
map = $[14];
|
|
637
|
-
}
|
|
638
|
-
const nodeMap = map;
|
|
639
|
-
let t8;
|
|
640
|
-
if ($[15] !== flattenedNodes) {
|
|
641
|
-
t8 = (nodeId_0) => flattenedNodes.find((fn_0) => fn_0.node.id === nodeId_0);
|
|
642
|
-
$[15] = flattenedNodes;
|
|
643
|
-
$[16] = t8;
|
|
644
|
-
} else {
|
|
645
|
-
t8 = $[16];
|
|
646
|
-
}
|
|
647
|
-
const findFlattenedNode = t8;
|
|
648
|
-
let t9;
|
|
649
|
-
if ($[17] !== findFlattenedNode || $[18] !== onCollapse || $[19] !== onExpand) {
|
|
650
|
-
t9 = (nodeId_1, shouldExpand) => {
|
|
651
|
-
const flatNode_1 = findFlattenedNode(nodeId_1);
|
|
652
|
-
if (!flatNode_1 || !flatNode_1.hasChildren) {
|
|
653
|
-
return;
|
|
654
|
-
}
|
|
655
|
-
if (shouldExpand) {
|
|
656
|
-
if (onExpand) {
|
|
657
|
-
onExpand(nodeId_1);
|
|
658
|
-
} else {
|
|
659
|
-
setInternalExpandedIds((prev) => new Set(prev).add(nodeId_1));
|
|
660
|
-
}
|
|
661
|
-
} else {
|
|
662
|
-
if (onCollapse) {
|
|
663
|
-
onCollapse(nodeId_1);
|
|
664
|
-
} else {
|
|
665
|
-
setInternalExpandedIds((prev_0) => {
|
|
666
|
-
const newSet = new Set(prev_0);
|
|
667
|
-
newSet.delete(nodeId_1);
|
|
668
|
-
return newSet;
|
|
669
|
-
});
|
|
670
|
-
}
|
|
671
|
-
}
|
|
672
|
-
};
|
|
673
|
-
$[17] = findFlattenedNode;
|
|
674
|
-
$[18] = onCollapse;
|
|
675
|
-
$[19] = onExpand;
|
|
676
|
-
$[20] = t9;
|
|
677
|
-
} else {
|
|
678
|
-
t9 = $[20];
|
|
679
|
-
}
|
|
680
|
-
const toggleExpand = t9;
|
|
681
|
-
let t10;
|
|
682
|
-
if ($[21] !== findFlattenedNode || $[22] !== focusNodeId || $[23] !== isDisabled || $[24] !== nodeMap || $[25] !== onFocus || $[26] !== toggleExpand) {
|
|
683
|
-
t10 = (e) => {
|
|
684
|
-
if (!focusNodeId || isDisabled) {
|
|
685
|
-
return;
|
|
686
|
-
}
|
|
687
|
-
const flatNode_2 = findFlattenedNode(focusNodeId);
|
|
688
|
-
if (!flatNode_2) {
|
|
689
|
-
return;
|
|
690
|
-
}
|
|
691
|
-
if (e.key === "right" && flatNode_2.hasChildren) {
|
|
692
|
-
e.preventDefault();
|
|
693
|
-
toggleExpand(focusNodeId, true);
|
|
694
|
-
} else {
|
|
695
|
-
if (e.key === "left") {
|
|
696
|
-
if (flatNode_2.hasChildren && flatNode_2.isExpanded) {
|
|
697
|
-
e.preventDefault();
|
|
698
|
-
toggleExpand(focusNodeId, false);
|
|
699
|
-
} else {
|
|
700
|
-
if (flatNode_2.parentId !== undefined) {
|
|
701
|
-
e.preventDefault();
|
|
702
|
-
isProgrammaticFocusRef.current = true;
|
|
703
|
-
toggleExpand(flatNode_2.parentId, false);
|
|
704
|
-
if (onFocus) {
|
|
705
|
-
const parentNode = nodeMap.get(flatNode_2.parentId);
|
|
706
|
-
if (parentNode) {
|
|
707
|
-
onFocus(parentNode);
|
|
708
|
-
}
|
|
709
|
-
}
|
|
710
|
-
}
|
|
711
|
-
}
|
|
712
|
-
}
|
|
713
|
-
}
|
|
714
|
-
};
|
|
715
|
-
$[21] = findFlattenedNode;
|
|
716
|
-
$[22] = focusNodeId;
|
|
717
|
-
$[23] = isDisabled;
|
|
718
|
-
$[24] = nodeMap;
|
|
719
|
-
$[25] = onFocus;
|
|
720
|
-
$[26] = toggleExpand;
|
|
721
|
-
$[27] = t10;
|
|
722
|
-
} else {
|
|
723
|
-
t10 = $[27];
|
|
724
|
-
}
|
|
725
|
-
const handleKeyDown = t10;
|
|
726
|
-
let t11;
|
|
727
|
-
if ($[28] !== nodeMap || $[29] !== onSelect) {
|
|
728
|
-
t11 = (nodeId_2) => {
|
|
729
|
-
const node_1 = nodeMap.get(nodeId_2);
|
|
730
|
-
if (!node_1) {
|
|
731
|
-
return;
|
|
732
|
-
}
|
|
733
|
-
onSelect(node_1);
|
|
734
|
-
};
|
|
735
|
-
$[28] = nodeMap;
|
|
736
|
-
$[29] = onSelect;
|
|
737
|
-
$[30] = t11;
|
|
738
|
-
} else {
|
|
739
|
-
t11 = $[30];
|
|
740
|
-
}
|
|
741
|
-
const handleChange = t11;
|
|
742
|
-
let t12;
|
|
743
|
-
if ($[31] !== nodeMap || $[32] !== onFocus) {
|
|
744
|
-
t12 = (nodeId_3) => {
|
|
745
|
-
if (isProgrammaticFocusRef.current) {
|
|
746
|
-
isProgrammaticFocusRef.current = false;
|
|
747
|
-
return;
|
|
748
|
-
}
|
|
749
|
-
if (lastFocusedIdRef.current === nodeId_3) {
|
|
750
|
-
return;
|
|
751
|
-
}
|
|
752
|
-
lastFocusedIdRef.current = nodeId_3;
|
|
753
|
-
if (onFocus) {
|
|
754
|
-
const node_2 = nodeMap.get(nodeId_3);
|
|
755
|
-
if (node_2) {
|
|
756
|
-
onFocus(node_2);
|
|
757
|
-
}
|
|
758
|
-
}
|
|
759
|
-
};
|
|
760
|
-
$[31] = nodeMap;
|
|
761
|
-
$[32] = onFocus;
|
|
762
|
-
$[33] = t12;
|
|
763
|
-
} else {
|
|
764
|
-
t12 = $[33];
|
|
765
|
-
}
|
|
766
|
-
const handleFocus = t12;
|
|
767
|
-
let t13;
|
|
768
|
-
if ($[34] !== focusNodeId || $[35] !== handleChange || $[36] !== handleFocus || $[37] !== hideIndexes || $[38] !== isDisabled || $[39] !== layout || $[40] !== onCancel || $[41] !== onUpFromFirstItem || $[42] !== options || $[43] !== visibleOptionCount) {
|
|
769
|
-
t13 = /* @__PURE__ */ jsx_dev_runtime3.jsxDEV(Select, {
|
|
770
|
-
options,
|
|
771
|
-
onChange: handleChange,
|
|
772
|
-
onFocus: handleFocus,
|
|
773
|
-
onCancel,
|
|
774
|
-
defaultFocusValue: focusNodeId,
|
|
775
|
-
visibleOptionCount,
|
|
776
|
-
layout,
|
|
777
|
-
isDisabled,
|
|
778
|
-
hideIndexes,
|
|
779
|
-
onUpFromFirstItem
|
|
780
|
-
}, undefined, false, undefined, this);
|
|
781
|
-
$[34] = focusNodeId;
|
|
782
|
-
$[35] = handleChange;
|
|
783
|
-
$[36] = handleFocus;
|
|
784
|
-
$[37] = hideIndexes;
|
|
785
|
-
$[38] = isDisabled;
|
|
786
|
-
$[39] = layout;
|
|
787
|
-
$[40] = onCancel;
|
|
788
|
-
$[41] = onUpFromFirstItem;
|
|
789
|
-
$[42] = options;
|
|
790
|
-
$[43] = visibleOptionCount;
|
|
791
|
-
$[44] = t13;
|
|
792
|
-
} else {
|
|
793
|
-
t13 = $[44];
|
|
794
|
-
}
|
|
795
|
-
let t14;
|
|
796
|
-
if ($[45] !== handleKeyDown || $[46] !== t13) {
|
|
797
|
-
t14 = /* @__PURE__ */ jsx_dev_runtime3.jsxDEV(ThemedBox_default, {
|
|
798
|
-
tabIndex: 0,
|
|
799
|
-
autoFocus: true,
|
|
800
|
-
onKeyDown: handleKeyDown,
|
|
801
|
-
children: t13
|
|
802
|
-
}, undefined, false, undefined, this);
|
|
803
|
-
$[45] = handleKeyDown;
|
|
804
|
-
$[46] = t13;
|
|
805
|
-
$[47] = t14;
|
|
806
|
-
} else {
|
|
807
|
-
t14 = $[47];
|
|
808
|
-
}
|
|
809
|
-
return t14;
|
|
810
|
-
}
|
|
811
|
-
function _temp2(_depth) {
|
|
812
|
-
return " \u25B8 ";
|
|
813
|
-
}
|
|
814
|
-
function _temp(isExpanded_0) {
|
|
815
|
-
return isExpanded_0 ? "\u25BC " : "\u25B6 ";
|
|
816
|
-
}
|
|
817
|
-
var import_compiler_runtime2, import_react2, jsx_dev_runtime3;
|
|
818
|
-
var init_TreeSelect = __esm(() => {
|
|
819
|
-
init_ink();
|
|
820
|
-
init_select();
|
|
821
|
-
import_compiler_runtime2 = __toESM(require_compiler_runtime(), 1);
|
|
822
|
-
import_react2 = __toESM(require_react(), 1);
|
|
823
|
-
jsx_dev_runtime3 = __toESM(require_jsx_dev_runtime(), 1);
|
|
824
|
-
});
|
|
825
|
-
|
|
826
|
-
// src/components/LogSelector.tsx
|
|
827
|
-
function normalizeAndTruncateToWidth(text, maxWidth) {
|
|
828
|
-
const normalized = text.replace(/\s+/g, " ").trim();
|
|
829
|
-
return truncateToWidth(normalized, maxWidth);
|
|
830
|
-
}
|
|
831
|
-
function formatSnippet({
|
|
832
|
-
before,
|
|
833
|
-
match,
|
|
834
|
-
after
|
|
835
|
-
}, highlightColor) {
|
|
836
|
-
return source_default.dim(before) + highlightColor(match) + source_default.dim(after);
|
|
837
|
-
}
|
|
838
|
-
function extractSnippet(text, query, contextChars) {
|
|
839
|
-
const matchIndex = text.toLowerCase().indexOf(query.toLowerCase());
|
|
840
|
-
if (matchIndex === -1)
|
|
841
|
-
return null;
|
|
842
|
-
const matchEnd = matchIndex + query.length;
|
|
843
|
-
const snippetStart = Math.max(0, matchIndex - contextChars);
|
|
844
|
-
const snippetEnd = Math.min(text.length, matchEnd + contextChars);
|
|
845
|
-
const beforeRaw = text.slice(snippetStart, matchIndex);
|
|
846
|
-
const matchText = text.slice(matchIndex, matchEnd);
|
|
847
|
-
const afterRaw = text.slice(matchEnd, snippetEnd);
|
|
848
|
-
return {
|
|
849
|
-
before: (snippetStart > 0 ? "\u2026" : "") + beforeRaw.replace(/\s+/g, " ").trimStart(),
|
|
850
|
-
match: matchText.trim(),
|
|
851
|
-
after: afterRaw.replace(/\s+/g, " ").trimEnd() + (snippetEnd < text.length ? "\u2026" : "")
|
|
852
|
-
};
|
|
853
|
-
}
|
|
854
|
-
function buildLogLabel(log, maxLabelWidth, options) {
|
|
855
|
-
const {
|
|
856
|
-
isGroupHeader = false,
|
|
857
|
-
isChild = false,
|
|
858
|
-
forkCount = 0
|
|
859
|
-
} = options || {};
|
|
860
|
-
const prefixWidth = isGroupHeader && forkCount > 0 ? PARENT_PREFIX_WIDTH : isChild ? CHILD_PREFIX_WIDTH : 0;
|
|
861
|
-
const sessionCountSuffix = isGroupHeader && forkCount > 0 ? ` (+${forkCount} other ${forkCount === 1 ? "session" : "sessions"})` : "";
|
|
862
|
-
const sidechainSuffix = log.isSidechain ? " (sidechain)" : "";
|
|
863
|
-
const maxSummaryWidth = maxLabelWidth - prefixWidth - sidechainSuffix.length - sessionCountSuffix.length;
|
|
864
|
-
const truncatedSummary = normalizeAndTruncateToWidth(getLogDisplayTitle(log), maxSummaryWidth);
|
|
865
|
-
return `${truncatedSummary}${sidechainSuffix}${sessionCountSuffix}`;
|
|
866
|
-
}
|
|
867
|
-
function buildLogMetadata(log, options) {
|
|
868
|
-
const {
|
|
869
|
-
isChild = false,
|
|
870
|
-
showProjectPath = false
|
|
871
|
-
} = options || {};
|
|
872
|
-
const childPadding = isChild ? " " : "";
|
|
873
|
-
const baseMetadata = formatLogMetadata(log);
|
|
874
|
-
const projectSuffix = showProjectPath && log.projectPath ? ` \xB7 ${log.projectPath}` : "";
|
|
875
|
-
return childPadding + baseMetadata + projectSuffix;
|
|
876
|
-
}
|
|
877
|
-
function LogSelector(t0) {
|
|
878
|
-
const $ = import_compiler_runtime3.c(247);
|
|
879
|
-
const {
|
|
880
|
-
logs,
|
|
881
|
-
maxHeight: t1,
|
|
882
|
-
forceWidth,
|
|
883
|
-
onCancel,
|
|
884
|
-
onSelect,
|
|
885
|
-
onLogsChanged,
|
|
886
|
-
onLoadMore,
|
|
887
|
-
initialSearchQuery,
|
|
888
|
-
showAllProjects: t2,
|
|
889
|
-
onToggleAllProjects,
|
|
890
|
-
onAgenticSearch
|
|
891
|
-
} = t0;
|
|
892
|
-
const maxHeight = t1 === undefined ? Infinity : t1;
|
|
893
|
-
const showAllProjects = t2 === undefined ? false : t2;
|
|
894
|
-
const terminalSize = useTerminalSize();
|
|
895
|
-
const columns = forceWidth === undefined ? terminalSize.columns : forceWidth;
|
|
896
|
-
const exitState = useExitOnCtrlCDWithKeybindings(onCancel);
|
|
897
|
-
const isTerminalFocused = useTerminalFocus();
|
|
898
|
-
let t3;
|
|
899
|
-
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
900
|
-
t3 = isCustomTitleEnabled();
|
|
901
|
-
$[0] = t3;
|
|
902
|
-
} else {
|
|
903
|
-
t3 = $[0];
|
|
904
|
-
}
|
|
905
|
-
const isResumeWithRenameEnabled = t3;
|
|
906
|
-
const isDeepSearchEnabled = false;
|
|
907
|
-
const [themeName] = useTheme();
|
|
908
|
-
let t4;
|
|
909
|
-
if ($[1] !== themeName) {
|
|
910
|
-
t4 = getTheme(themeName);
|
|
911
|
-
$[1] = themeName;
|
|
912
|
-
$[2] = t4;
|
|
913
|
-
} else {
|
|
914
|
-
t4 = $[2];
|
|
915
|
-
}
|
|
916
|
-
const theme = t4;
|
|
917
|
-
let t5;
|
|
918
|
-
if ($[3] !== theme.warning) {
|
|
919
|
-
t5 = (text) => applyColor(text, theme.warning);
|
|
920
|
-
$[3] = theme.warning;
|
|
921
|
-
$[4] = t5;
|
|
922
|
-
} else {
|
|
923
|
-
t5 = $[4];
|
|
924
|
-
}
|
|
925
|
-
const highlightColor = t5;
|
|
926
|
-
const isAgenticSearchEnabled = false;
|
|
927
|
-
const [currentBranch, setCurrentBranch] = import_react3.default.useState(null);
|
|
928
|
-
const [branchFilterEnabled, setBranchFilterEnabled] = import_react3.default.useState(false);
|
|
929
|
-
const [showAllWorktrees, setShowAllWorktrees] = import_react3.default.useState(false);
|
|
930
|
-
const [hasMultipleWorktrees, setHasMultipleWorktrees] = import_react3.default.useState(false);
|
|
931
|
-
let t6;
|
|
932
|
-
if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
|
|
933
|
-
t6 = getOriginalCwd();
|
|
934
|
-
$[5] = t6;
|
|
935
|
-
} else {
|
|
936
|
-
t6 = $[5];
|
|
937
|
-
}
|
|
938
|
-
const currentCwd = t6;
|
|
939
|
-
const [renameValue, setRenameValue] = import_react3.default.useState("");
|
|
940
|
-
const [renameCursorOffset, setRenameCursorOffset] = import_react3.default.useState(0);
|
|
941
|
-
let t7;
|
|
942
|
-
if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
|
|
943
|
-
t7 = new Set;
|
|
944
|
-
$[6] = t7;
|
|
945
|
-
} else {
|
|
946
|
-
t7 = $[6];
|
|
947
|
-
}
|
|
948
|
-
const [expandedGroupSessionIds, setExpandedGroupSessionIds] = import_react3.default.useState(t7);
|
|
949
|
-
const [focusedNode, setFocusedNode] = import_react3.default.useState(null);
|
|
950
|
-
const [focusedIndex, setFocusedIndex] = import_react3.default.useState(1);
|
|
951
|
-
const [viewMode, setViewMode] = import_react3.default.useState("list");
|
|
952
|
-
const [previewLog, setPreviewLog] = import_react3.default.useState(null);
|
|
953
|
-
const prevFocusedIdRef = import_react3.default.useRef(null);
|
|
954
|
-
const [selectedTagIndex, setSelectedTagIndex] = import_react3.default.useState(0);
|
|
955
|
-
let t8;
|
|
956
|
-
if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
|
|
957
|
-
t8 = {
|
|
958
|
-
status: "idle"
|
|
959
|
-
};
|
|
960
|
-
$[7] = t8;
|
|
961
|
-
} else {
|
|
962
|
-
t8 = $[7];
|
|
963
|
-
}
|
|
964
|
-
const [agenticSearchState, setAgenticSearchState] = import_react3.default.useState(t8);
|
|
965
|
-
const [isAgenticSearchOptionFocused, setIsAgenticSearchOptionFocused] = import_react3.default.useState(false);
|
|
966
|
-
const agenticSearchAbortRef = import_react3.default.useRef(null);
|
|
967
|
-
const t9 = viewMode === "search" && agenticSearchState.status !== "searching";
|
|
968
|
-
let t10;
|
|
969
|
-
let t11;
|
|
970
|
-
let t12;
|
|
971
|
-
if ($[8] === Symbol.for("react.memo_cache_sentinel")) {
|
|
972
|
-
t10 = () => {
|
|
973
|
-
setViewMode("list");
|
|
974
|
-
logEvent("tengu_session_search_toggled", {
|
|
975
|
-
enabled: false
|
|
976
|
-
});
|
|
977
|
-
};
|
|
978
|
-
t11 = () => {
|
|
979
|
-
setViewMode("list");
|
|
980
|
-
logEvent("tengu_session_search_toggled", {
|
|
981
|
-
enabled: false
|
|
982
|
-
});
|
|
983
|
-
};
|
|
984
|
-
t12 = ["n"];
|
|
985
|
-
$[8] = t10;
|
|
986
|
-
$[9] = t11;
|
|
987
|
-
$[10] = t12;
|
|
988
|
-
} else {
|
|
989
|
-
t10 = $[8];
|
|
990
|
-
t11 = $[9];
|
|
991
|
-
t12 = $[10];
|
|
992
|
-
}
|
|
993
|
-
const t13 = initialSearchQuery || "";
|
|
994
|
-
let t14;
|
|
995
|
-
if ($[11] !== t13 || $[12] !== t9) {
|
|
996
|
-
t14 = {
|
|
997
|
-
isActive: t9,
|
|
998
|
-
onExit: t10,
|
|
999
|
-
onExitUp: t11,
|
|
1000
|
-
passthroughCtrlKeys: t12,
|
|
1001
|
-
initialQuery: t13
|
|
1002
|
-
};
|
|
1003
|
-
$[11] = t13;
|
|
1004
|
-
$[12] = t9;
|
|
1005
|
-
$[13] = t14;
|
|
1006
|
-
} else {
|
|
1007
|
-
t14 = $[13];
|
|
1008
|
-
}
|
|
1009
|
-
const {
|
|
1010
|
-
query: searchQuery,
|
|
1011
|
-
setQuery: setSearchQuery,
|
|
1012
|
-
cursorOffset: searchCursorOffset
|
|
1013
|
-
} = useSearchInput(t14);
|
|
1014
|
-
const deferredSearchQuery = import_react3.default.useDeferredValue(searchQuery);
|
|
1015
|
-
const [debouncedDeepSearchQuery, setDebouncedDeepSearchQuery] = import_react3.default.useState("");
|
|
1016
|
-
let t15;
|
|
1017
|
-
let t16;
|
|
1018
|
-
if ($[14] !== deferredSearchQuery) {
|
|
1019
|
-
t15 = () => {
|
|
1020
|
-
if (!deferredSearchQuery) {
|
|
1021
|
-
setDebouncedDeepSearchQuery("");
|
|
1022
|
-
return;
|
|
1023
|
-
}
|
|
1024
|
-
const timeoutId = setTimeout(setDebouncedDeepSearchQuery, 300, deferredSearchQuery);
|
|
1025
|
-
return () => clearTimeout(timeoutId);
|
|
1026
|
-
};
|
|
1027
|
-
t16 = [deferredSearchQuery];
|
|
1028
|
-
$[14] = deferredSearchQuery;
|
|
1029
|
-
$[15] = t15;
|
|
1030
|
-
$[16] = t16;
|
|
1031
|
-
} else {
|
|
1032
|
-
t15 = $[15];
|
|
1033
|
-
t16 = $[16];
|
|
1034
|
-
}
|
|
1035
|
-
import_react3.default.useEffect(t15, t16);
|
|
1036
|
-
const [deepSearchResults, setDeepSearchResults] = import_react3.default.useState(null);
|
|
1037
|
-
const [isSearching, setIsSearching] = import_react3.default.useState(false);
|
|
1038
|
-
let t17;
|
|
1039
|
-
let t18;
|
|
1040
|
-
if ($[17] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1041
|
-
t17 = () => {
|
|
1042
|
-
getBranch().then((branch) => setCurrentBranch(branch));
|
|
1043
|
-
getWorktreePaths(currentCwd).then((paths) => {
|
|
1044
|
-
setHasMultipleWorktrees(paths.length > 1);
|
|
1045
|
-
});
|
|
1046
|
-
};
|
|
1047
|
-
t18 = [currentCwd];
|
|
1048
|
-
$[17] = t17;
|
|
1049
|
-
$[18] = t18;
|
|
1050
|
-
} else {
|
|
1051
|
-
t17 = $[17];
|
|
1052
|
-
t18 = $[18];
|
|
1053
|
-
}
|
|
1054
|
-
import_react3.default.useEffect(t17, t18);
|
|
1055
|
-
const searchableTextByLog = new Map(logs.map(_temp8));
|
|
1056
|
-
let t19;
|
|
1057
|
-
t19 = null;
|
|
1058
|
-
let t20;
|
|
1059
|
-
if ($[19] !== logs) {
|
|
1060
|
-
t20 = getUniqueTags(logs);
|
|
1061
|
-
$[19] = logs;
|
|
1062
|
-
$[20] = t20;
|
|
1063
|
-
} else {
|
|
1064
|
-
t20 = $[20];
|
|
1065
|
-
}
|
|
1066
|
-
const uniqueTags = t20;
|
|
1067
|
-
const hasTags = uniqueTags.length > 0;
|
|
1068
|
-
let t21;
|
|
1069
|
-
if ($[21] !== hasTags || $[22] !== uniqueTags) {
|
|
1070
|
-
t21 = hasTags ? ["All", ...uniqueTags] : [];
|
|
1071
|
-
$[21] = hasTags;
|
|
1072
|
-
$[22] = uniqueTags;
|
|
1073
|
-
$[23] = t21;
|
|
1074
|
-
} else {
|
|
1075
|
-
t21 = $[23];
|
|
1076
|
-
}
|
|
1077
|
-
const tagTabs = t21;
|
|
1078
|
-
const effectiveTagIndex = tagTabs.length > 0 && selectedTagIndex < tagTabs.length ? selectedTagIndex : 0;
|
|
1079
|
-
const selectedTab = tagTabs[effectiveTagIndex];
|
|
1080
|
-
const tagFilter = selectedTab === "All" ? undefined : selectedTab;
|
|
1081
|
-
const tagTabsLines = hasTags ? 1 : 0;
|
|
1082
|
-
let filtered = logs;
|
|
1083
|
-
if (isResumeWithRenameEnabled) {
|
|
1084
|
-
let t222;
|
|
1085
|
-
if ($[24] !== logs) {
|
|
1086
|
-
t222 = logs.filter(_temp22);
|
|
1087
|
-
$[24] = logs;
|
|
1088
|
-
$[25] = t222;
|
|
1089
|
-
} else {
|
|
1090
|
-
t222 = $[25];
|
|
1091
|
-
}
|
|
1092
|
-
filtered = t222;
|
|
1093
|
-
}
|
|
1094
|
-
if (tagFilter !== undefined) {
|
|
1095
|
-
let t222;
|
|
1096
|
-
if ($[26] !== filtered || $[27] !== tagFilter) {
|
|
1097
|
-
let t232;
|
|
1098
|
-
if ($[29] !== tagFilter) {
|
|
1099
|
-
t232 = (log_2) => log_2.tag === tagFilter;
|
|
1100
|
-
$[29] = tagFilter;
|
|
1101
|
-
$[30] = t232;
|
|
1102
|
-
} else {
|
|
1103
|
-
t232 = $[30];
|
|
1104
|
-
}
|
|
1105
|
-
t222 = filtered.filter(t232);
|
|
1106
|
-
$[26] = filtered;
|
|
1107
|
-
$[27] = tagFilter;
|
|
1108
|
-
$[28] = t222;
|
|
1109
|
-
} else {
|
|
1110
|
-
t222 = $[28];
|
|
1111
|
-
}
|
|
1112
|
-
filtered = t222;
|
|
1113
|
-
}
|
|
1114
|
-
if (branchFilterEnabled && currentBranch) {
|
|
1115
|
-
let t222;
|
|
1116
|
-
if ($[31] !== currentBranch || $[32] !== filtered) {
|
|
1117
|
-
let t232;
|
|
1118
|
-
if ($[34] !== currentBranch) {
|
|
1119
|
-
t232 = (log_3) => log_3.gitBranch === currentBranch;
|
|
1120
|
-
$[34] = currentBranch;
|
|
1121
|
-
$[35] = t232;
|
|
1122
|
-
} else {
|
|
1123
|
-
t232 = $[35];
|
|
1124
|
-
}
|
|
1125
|
-
t222 = filtered.filter(t232);
|
|
1126
|
-
$[31] = currentBranch;
|
|
1127
|
-
$[32] = filtered;
|
|
1128
|
-
$[33] = t222;
|
|
1129
|
-
} else {
|
|
1130
|
-
t222 = $[33];
|
|
1131
|
-
}
|
|
1132
|
-
filtered = t222;
|
|
1133
|
-
}
|
|
1134
|
-
if (hasMultipleWorktrees && !showAllWorktrees) {
|
|
1135
|
-
let t222;
|
|
1136
|
-
if ($[36] !== filtered) {
|
|
1137
|
-
let t232;
|
|
1138
|
-
if ($[38] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1139
|
-
t232 = (log_4) => log_4.projectPath === currentCwd;
|
|
1140
|
-
$[38] = t232;
|
|
1141
|
-
} else {
|
|
1142
|
-
t232 = $[38];
|
|
1143
|
-
}
|
|
1144
|
-
t222 = filtered.filter(t232);
|
|
1145
|
-
$[36] = filtered;
|
|
1146
|
-
$[37] = t222;
|
|
1147
|
-
} else {
|
|
1148
|
-
t222 = $[37];
|
|
1149
|
-
}
|
|
1150
|
-
filtered = t222;
|
|
1151
|
-
}
|
|
1152
|
-
const baseFilteredLogs = filtered;
|
|
1153
|
-
let t22;
|
|
1154
|
-
bb0: {
|
|
1155
|
-
if (!searchQuery) {
|
|
1156
|
-
t22 = baseFilteredLogs;
|
|
1157
|
-
break bb0;
|
|
1158
|
-
}
|
|
1159
|
-
let t232;
|
|
1160
|
-
if ($[39] !== baseFilteredLogs || $[40] !== searchQuery) {
|
|
1161
|
-
const query = searchQuery.toLowerCase();
|
|
1162
|
-
t232 = baseFilteredLogs.filter((log_5) => {
|
|
1163
|
-
const displayedTitle = getLogDisplayTitle(log_5).toLowerCase();
|
|
1164
|
-
const branch_0 = (log_5.gitBranch || "").toLowerCase();
|
|
1165
|
-
const tag = (log_5.tag || "").toLowerCase();
|
|
1166
|
-
const prInfo = log_5.prNumber ? `pr #${log_5.prNumber} ${log_5.prRepository || ""}`.toLowerCase() : "";
|
|
1167
|
-
return displayedTitle.includes(query) || branch_0.includes(query) || tag.includes(query) || prInfo.includes(query);
|
|
1168
|
-
});
|
|
1169
|
-
$[39] = baseFilteredLogs;
|
|
1170
|
-
$[40] = searchQuery;
|
|
1171
|
-
$[41] = t232;
|
|
1172
|
-
} else {
|
|
1173
|
-
t232 = $[41];
|
|
1174
|
-
}
|
|
1175
|
-
t22 = t232;
|
|
1176
|
-
}
|
|
1177
|
-
const titleFilteredLogs = t22;
|
|
1178
|
-
let t23;
|
|
1179
|
-
let t24;
|
|
1180
|
-
if ($[42] !== debouncedDeepSearchQuery || $[43] !== deferredSearchQuery) {
|
|
1181
|
-
t23 = () => {
|
|
1182
|
-
if (false) {}
|
|
1183
|
-
};
|
|
1184
|
-
t24 = [deferredSearchQuery, debouncedDeepSearchQuery, false];
|
|
1185
|
-
$[42] = debouncedDeepSearchQuery;
|
|
1186
|
-
$[43] = deferredSearchQuery;
|
|
1187
|
-
$[44] = t23;
|
|
1188
|
-
$[45] = t24;
|
|
1189
|
-
} else {
|
|
1190
|
-
t23 = $[44];
|
|
1191
|
-
t24 = $[45];
|
|
1192
|
-
}
|
|
1193
|
-
import_react3.default.useEffect(t23, t24);
|
|
1194
|
-
let t25;
|
|
1195
|
-
let t26;
|
|
1196
|
-
if ($[46] !== debouncedDeepSearchQuery) {
|
|
1197
|
-
t25 = () => {
|
|
1198
|
-
if (true) {
|
|
1199
|
-
setDeepSearchResults(null);
|
|
1200
|
-
setIsSearching(false);
|
|
1201
|
-
return;
|
|
1202
|
-
}
|
|
1203
|
-
const timeoutId_0 = setTimeout(_temp5, 0, null, debouncedDeepSearchQuery, setDeepSearchResults, setIsSearching);
|
|
1204
|
-
return () => {
|
|
1205
|
-
clearTimeout(timeoutId_0);
|
|
1206
|
-
};
|
|
1207
|
-
};
|
|
1208
|
-
t26 = [debouncedDeepSearchQuery, null, false];
|
|
1209
|
-
$[46] = debouncedDeepSearchQuery;
|
|
1210
|
-
$[47] = t25;
|
|
1211
|
-
$[48] = t26;
|
|
1212
|
-
} else {
|
|
1213
|
-
t25 = $[47];
|
|
1214
|
-
t26 = $[48];
|
|
1215
|
-
}
|
|
1216
|
-
import_react3.default.useEffect(t25, t26);
|
|
1217
|
-
let filtered_0;
|
|
1218
|
-
let snippetMap;
|
|
1219
|
-
if ($[49] !== debouncedDeepSearchQuery || $[50] !== deepSearchResults || $[51] !== titleFilteredLogs) {
|
|
1220
|
-
snippetMap = new Map;
|
|
1221
|
-
filtered_0 = titleFilteredLogs;
|
|
1222
|
-
if (deepSearchResults && debouncedDeepSearchQuery && deepSearchResults.query === debouncedDeepSearchQuery) {
|
|
1223
|
-
for (const result of deepSearchResults.results) {
|
|
1224
|
-
if (result.searchableText) {
|
|
1225
|
-
const snippet = extractSnippet(result.searchableText, debouncedDeepSearchQuery, SNIPPET_CONTEXT_CHARS);
|
|
1226
|
-
if (snippet) {
|
|
1227
|
-
snippetMap.set(result.log, snippet);
|
|
1228
|
-
}
|
|
1229
|
-
}
|
|
1230
|
-
}
|
|
1231
|
-
let t272;
|
|
1232
|
-
if ($[54] !== filtered_0) {
|
|
1233
|
-
t272 = new Set(filtered_0.map(_temp6));
|
|
1234
|
-
$[54] = filtered_0;
|
|
1235
|
-
$[55] = t272;
|
|
1236
|
-
} else {
|
|
1237
|
-
t272 = $[55];
|
|
1238
|
-
}
|
|
1239
|
-
const titleMatchIds = t272;
|
|
1240
|
-
let t282;
|
|
1241
|
-
if ($[56] !== deepSearchResults.results || $[57] !== filtered_0 || $[58] !== titleMatchIds) {
|
|
1242
|
-
let t292;
|
|
1243
|
-
if ($[60] !== titleMatchIds) {
|
|
1244
|
-
t292 = (log_7) => !titleMatchIds.has(log_7.messages[0]?.uuid);
|
|
1245
|
-
$[60] = titleMatchIds;
|
|
1246
|
-
$[61] = t292;
|
|
1247
|
-
} else {
|
|
1248
|
-
t292 = $[61];
|
|
1249
|
-
}
|
|
1250
|
-
const transcriptOnlyMatches = deepSearchResults.results.map(_temp7).filter(t292);
|
|
1251
|
-
t282 = [...filtered_0, ...transcriptOnlyMatches];
|
|
1252
|
-
$[56] = deepSearchResults.results;
|
|
1253
|
-
$[57] = filtered_0;
|
|
1254
|
-
$[58] = titleMatchIds;
|
|
1255
|
-
$[59] = t282;
|
|
1256
|
-
} else {
|
|
1257
|
-
t282 = $[59];
|
|
1258
|
-
}
|
|
1259
|
-
filtered_0 = t282;
|
|
1260
|
-
}
|
|
1261
|
-
$[49] = debouncedDeepSearchQuery;
|
|
1262
|
-
$[50] = deepSearchResults;
|
|
1263
|
-
$[51] = titleFilteredLogs;
|
|
1264
|
-
$[52] = filtered_0;
|
|
1265
|
-
$[53] = snippetMap;
|
|
1266
|
-
} else {
|
|
1267
|
-
filtered_0 = $[52];
|
|
1268
|
-
snippetMap = $[53];
|
|
1269
|
-
}
|
|
1270
|
-
let t27;
|
|
1271
|
-
if ($[62] !== filtered_0 || $[63] !== snippetMap) {
|
|
1272
|
-
t27 = {
|
|
1273
|
-
filteredLogs: filtered_0,
|
|
1274
|
-
snippets: snippetMap
|
|
1275
|
-
};
|
|
1276
|
-
$[62] = filtered_0;
|
|
1277
|
-
$[63] = snippetMap;
|
|
1278
|
-
$[64] = t27;
|
|
1279
|
-
} else {
|
|
1280
|
-
t27 = $[64];
|
|
1281
|
-
}
|
|
1282
|
-
const {
|
|
1283
|
-
filteredLogs,
|
|
1284
|
-
snippets
|
|
1285
|
-
} = t27;
|
|
1286
|
-
let t28;
|
|
1287
|
-
bb1: {
|
|
1288
|
-
if (agenticSearchState.status === "results" && agenticSearchState.results.length > 0) {
|
|
1289
|
-
t28 = agenticSearchState.results;
|
|
1290
|
-
break bb1;
|
|
1291
|
-
}
|
|
1292
|
-
t28 = filteredLogs;
|
|
1293
|
-
}
|
|
1294
|
-
const displayedLogs = t28;
|
|
1295
|
-
const maxLabelWidth = Math.max(30, columns - 4);
|
|
1296
|
-
let t29;
|
|
1297
|
-
bb2: {
|
|
1298
|
-
if (!isResumeWithRenameEnabled) {
|
|
1299
|
-
let t303;
|
|
1300
|
-
if ($[65] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1301
|
-
t303 = [];
|
|
1302
|
-
$[65] = t303;
|
|
1303
|
-
} else {
|
|
1304
|
-
t303 = $[65];
|
|
1305
|
-
}
|
|
1306
|
-
t29 = t303;
|
|
1307
|
-
break bb2;
|
|
1308
|
-
}
|
|
1309
|
-
let t302;
|
|
1310
|
-
if ($[66] !== displayedLogs || $[67] !== highlightColor || $[68] !== maxLabelWidth || $[69] !== showAllProjects || $[70] !== snippets) {
|
|
1311
|
-
const sessionGroups = groupLogsBySessionId(displayedLogs);
|
|
1312
|
-
t302 = Array.from(sessionGroups.entries()).map((t312) => {
|
|
1313
|
-
const [sessionId, groupLogs] = t312;
|
|
1314
|
-
const latestLog = groupLogs[0];
|
|
1315
|
-
const indexInFiltered = displayedLogs.indexOf(latestLog);
|
|
1316
|
-
const snippet_0 = snippets.get(latestLog);
|
|
1317
|
-
const snippetStr = snippet_0 ? formatSnippet(snippet_0, highlightColor) : null;
|
|
1318
|
-
if (groupLogs.length === 1) {
|
|
1319
|
-
const metadata = buildLogMetadata(latestLog, {
|
|
1320
|
-
showProjectPath: showAllProjects
|
|
1321
|
-
});
|
|
1322
|
-
return {
|
|
1323
|
-
id: `log:${sessionId}:0`,
|
|
1324
|
-
value: {
|
|
1325
|
-
log: latestLog,
|
|
1326
|
-
indexInFiltered
|
|
1327
|
-
},
|
|
1328
|
-
label: buildLogLabel(latestLog, maxLabelWidth),
|
|
1329
|
-
description: snippetStr ? `${metadata}
|
|
1330
|
-
${snippetStr}` : metadata,
|
|
1331
|
-
dimDescription: true
|
|
1332
|
-
};
|
|
1333
|
-
}
|
|
1334
|
-
const forkCount = groupLogs.length - 1;
|
|
1335
|
-
const children = groupLogs.slice(1).map((log_8, index) => {
|
|
1336
|
-
const childIndexInFiltered = displayedLogs.indexOf(log_8);
|
|
1337
|
-
const childSnippet = snippets.get(log_8);
|
|
1338
|
-
const childSnippetStr = childSnippet ? formatSnippet(childSnippet, highlightColor) : null;
|
|
1339
|
-
const childMetadata = buildLogMetadata(log_8, {
|
|
1340
|
-
isChild: true,
|
|
1341
|
-
showProjectPath: showAllProjects
|
|
1342
|
-
});
|
|
1343
|
-
return {
|
|
1344
|
-
id: `log:${sessionId}:${index + 1}`,
|
|
1345
|
-
value: {
|
|
1346
|
-
log: log_8,
|
|
1347
|
-
indexInFiltered: childIndexInFiltered
|
|
1348
|
-
},
|
|
1349
|
-
label: buildLogLabel(log_8, maxLabelWidth, {
|
|
1350
|
-
isChild: true
|
|
1351
|
-
}),
|
|
1352
|
-
description: childSnippetStr ? `${childMetadata}
|
|
1353
|
-
${childSnippetStr}` : childMetadata,
|
|
1354
|
-
dimDescription: true
|
|
1355
|
-
};
|
|
1356
|
-
});
|
|
1357
|
-
const parentMetadata = buildLogMetadata(latestLog, {
|
|
1358
|
-
showProjectPath: showAllProjects
|
|
1359
|
-
});
|
|
1360
|
-
return {
|
|
1361
|
-
id: `group:${sessionId}`,
|
|
1362
|
-
value: {
|
|
1363
|
-
log: latestLog,
|
|
1364
|
-
indexInFiltered
|
|
1365
|
-
},
|
|
1366
|
-
label: buildLogLabel(latestLog, maxLabelWidth, {
|
|
1367
|
-
isGroupHeader: true,
|
|
1368
|
-
forkCount
|
|
1369
|
-
}),
|
|
1370
|
-
description: snippetStr ? `${parentMetadata}
|
|
1371
|
-
${snippetStr}` : parentMetadata,
|
|
1372
|
-
dimDescription: true,
|
|
1373
|
-
children
|
|
1374
|
-
};
|
|
1375
|
-
});
|
|
1376
|
-
$[66] = displayedLogs;
|
|
1377
|
-
$[67] = highlightColor;
|
|
1378
|
-
$[68] = maxLabelWidth;
|
|
1379
|
-
$[69] = showAllProjects;
|
|
1380
|
-
$[70] = snippets;
|
|
1381
|
-
$[71] = t302;
|
|
1382
|
-
} else {
|
|
1383
|
-
t302 = $[71];
|
|
1384
|
-
}
|
|
1385
|
-
t29 = t302;
|
|
1386
|
-
}
|
|
1387
|
-
const treeNodes = t29;
|
|
1388
|
-
let t30;
|
|
1389
|
-
bb3: {
|
|
1390
|
-
if (isResumeWithRenameEnabled) {
|
|
1391
|
-
let t313;
|
|
1392
|
-
if ($[72] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1393
|
-
t313 = [];
|
|
1394
|
-
$[72] = t313;
|
|
1395
|
-
} else {
|
|
1396
|
-
t313 = $[72];
|
|
1397
|
-
}
|
|
1398
|
-
t30 = t313;
|
|
1399
|
-
break bb3;
|
|
1400
|
-
}
|
|
1401
|
-
let t312;
|
|
1402
|
-
if ($[73] !== displayedLogs || $[74] !== highlightColor || $[75] !== maxLabelWidth || $[76] !== showAllProjects || $[77] !== snippets) {
|
|
1403
|
-
let t322;
|
|
1404
|
-
if ($[79] !== highlightColor || $[80] !== maxLabelWidth || $[81] !== showAllProjects || $[82] !== snippets) {
|
|
1405
|
-
t322 = (log_9, index_0) => {
|
|
1406
|
-
const rawSummary = getLogDisplayTitle(log_9);
|
|
1407
|
-
const summaryWithSidechain = rawSummary + (log_9.isSidechain ? " (sidechain)" : "");
|
|
1408
|
-
const summary = normalizeAndTruncateToWidth(summaryWithSidechain, maxLabelWidth);
|
|
1409
|
-
const baseDescription = formatLogMetadata(log_9);
|
|
1410
|
-
const projectSuffix = showAllProjects && log_9.projectPath ? ` \xB7 ${log_9.projectPath}` : "";
|
|
1411
|
-
const snippet_1 = snippets.get(log_9);
|
|
1412
|
-
const snippetStr_0 = snippet_1 ? formatSnippet(snippet_1, highlightColor) : null;
|
|
1413
|
-
return {
|
|
1414
|
-
label: summary,
|
|
1415
|
-
description: snippetStr_0 ? `${baseDescription}${projectSuffix}
|
|
1416
|
-
${snippetStr_0}` : baseDescription + projectSuffix,
|
|
1417
|
-
dimDescription: true,
|
|
1418
|
-
value: index_0.toString()
|
|
1419
|
-
};
|
|
1420
|
-
};
|
|
1421
|
-
$[79] = highlightColor;
|
|
1422
|
-
$[80] = maxLabelWidth;
|
|
1423
|
-
$[81] = showAllProjects;
|
|
1424
|
-
$[82] = snippets;
|
|
1425
|
-
$[83] = t322;
|
|
1426
|
-
} else {
|
|
1427
|
-
t322 = $[83];
|
|
1428
|
-
}
|
|
1429
|
-
t312 = displayedLogs.map(t322);
|
|
1430
|
-
$[73] = displayedLogs;
|
|
1431
|
-
$[74] = highlightColor;
|
|
1432
|
-
$[75] = maxLabelWidth;
|
|
1433
|
-
$[76] = showAllProjects;
|
|
1434
|
-
$[77] = snippets;
|
|
1435
|
-
$[78] = t312;
|
|
1436
|
-
} else {
|
|
1437
|
-
t312 = $[78];
|
|
1438
|
-
}
|
|
1439
|
-
t30 = t312;
|
|
1440
|
-
}
|
|
1441
|
-
const flatOptions = t30;
|
|
1442
|
-
const focusedLog = focusedNode?.value.log ?? null;
|
|
1443
|
-
let t31;
|
|
1444
|
-
if ($[84] !== displayedLogs || $[85] !== expandedGroupSessionIds || $[86] !== focusedLog) {
|
|
1445
|
-
t31 = () => {
|
|
1446
|
-
if (!isResumeWithRenameEnabled || !focusedLog) {
|
|
1447
|
-
return "";
|
|
1448
|
-
}
|
|
1449
|
-
const sessionId_0 = getSessionIdFromLog(focusedLog);
|
|
1450
|
-
if (!sessionId_0) {
|
|
1451
|
-
return "";
|
|
1452
|
-
}
|
|
1453
|
-
const sessionLogs = displayedLogs.filter((log_10) => getSessionIdFromLog(log_10) === sessionId_0);
|
|
1454
|
-
const hasMultipleLogs = sessionLogs.length > 1;
|
|
1455
|
-
if (!hasMultipleLogs) {
|
|
1456
|
-
return "";
|
|
1457
|
-
}
|
|
1458
|
-
const isExpanded = expandedGroupSessionIds.has(sessionId_0);
|
|
1459
|
-
const isChildNode = sessionLogs.indexOf(focusedLog) > 0;
|
|
1460
|
-
if (isChildNode) {
|
|
1461
|
-
return "\u2190 to collapse";
|
|
1462
|
-
}
|
|
1463
|
-
return isExpanded ? "\u2190 to collapse" : "\u2192 to expand";
|
|
1464
|
-
};
|
|
1465
|
-
$[84] = displayedLogs;
|
|
1466
|
-
$[85] = expandedGroupSessionIds;
|
|
1467
|
-
$[86] = focusedLog;
|
|
1468
|
-
$[87] = t31;
|
|
1469
|
-
} else {
|
|
1470
|
-
t31 = $[87];
|
|
1471
|
-
}
|
|
1472
|
-
const getExpandCollapseHint = t31;
|
|
1473
|
-
let t32;
|
|
1474
|
-
if ($[88] !== focusedLog || $[89] !== onLogsChanged || $[90] !== renameValue) {
|
|
1475
|
-
t32 = async () => {
|
|
1476
|
-
const sessionId_1 = focusedLog ? getSessionIdFromLog(focusedLog) : undefined;
|
|
1477
|
-
if (!focusedLog || !sessionId_1) {
|
|
1478
|
-
setViewMode("list");
|
|
1479
|
-
setRenameValue("");
|
|
1480
|
-
return;
|
|
1481
|
-
}
|
|
1482
|
-
if (renameValue.trim()) {
|
|
1483
|
-
await saveCustomTitle(sessionId_1, renameValue.trim(), focusedLog.fullPath);
|
|
1484
|
-
if (isResumeWithRenameEnabled && onLogsChanged) {
|
|
1485
|
-
onLogsChanged();
|
|
1486
|
-
}
|
|
1487
|
-
}
|
|
1488
|
-
setViewMode("list");
|
|
1489
|
-
setRenameValue("");
|
|
1490
|
-
};
|
|
1491
|
-
$[88] = focusedLog;
|
|
1492
|
-
$[89] = onLogsChanged;
|
|
1493
|
-
$[90] = renameValue;
|
|
1494
|
-
$[91] = t32;
|
|
1495
|
-
} else {
|
|
1496
|
-
t32 = $[91];
|
|
1497
|
-
}
|
|
1498
|
-
const handleRenameSubmit = t32;
|
|
1499
|
-
let t33;
|
|
1500
|
-
if ($[92] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1501
|
-
t33 = () => {
|
|
1502
|
-
setViewMode("list");
|
|
1503
|
-
logEvent("tengu_session_search_toggled", {
|
|
1504
|
-
enabled: false
|
|
1505
|
-
});
|
|
1506
|
-
};
|
|
1507
|
-
$[92] = t33;
|
|
1508
|
-
} else {
|
|
1509
|
-
t33 = $[92];
|
|
1510
|
-
}
|
|
1511
|
-
const exitSearchMode = t33;
|
|
1512
|
-
let t34;
|
|
1513
|
-
if ($[93] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1514
|
-
t34 = () => {
|
|
1515
|
-
setViewMode("search");
|
|
1516
|
-
logEvent("tengu_session_search_toggled", {
|
|
1517
|
-
enabled: true
|
|
1518
|
-
});
|
|
1519
|
-
};
|
|
1520
|
-
$[93] = t34;
|
|
1521
|
-
} else {
|
|
1522
|
-
t34 = $[93];
|
|
1523
|
-
}
|
|
1524
|
-
const enterSearchMode = t34;
|
|
1525
|
-
let t35;
|
|
1526
|
-
if ($[94] !== logs || $[95] !== onAgenticSearch || $[96] !== searchQuery) {
|
|
1527
|
-
t35 = async () => {
|
|
1528
|
-
if (!searchQuery.trim() || !onAgenticSearch || true) {
|
|
1529
|
-
return;
|
|
1530
|
-
}
|
|
1531
|
-
agenticSearchAbortRef.current?.abort();
|
|
1532
|
-
const abortController = new AbortController;
|
|
1533
|
-
agenticSearchAbortRef.current = abortController;
|
|
1534
|
-
setAgenticSearchState({
|
|
1535
|
-
status: "searching"
|
|
1536
|
-
});
|
|
1537
|
-
logEvent("tengu_agentic_search_started", {
|
|
1538
|
-
query_length: searchQuery.length
|
|
1539
|
-
});
|
|
1540
|
-
try {
|
|
1541
|
-
const results_0 = await onAgenticSearch(searchQuery, logs, abortController.signal);
|
|
1542
|
-
if (abortController.signal.aborted) {
|
|
1543
|
-
return;
|
|
1544
|
-
}
|
|
1545
|
-
setAgenticSearchState({
|
|
1546
|
-
status: "results",
|
|
1547
|
-
results: results_0,
|
|
1548
|
-
query: searchQuery
|
|
1549
|
-
});
|
|
1550
|
-
logEvent("tengu_agentic_search_completed", {
|
|
1551
|
-
query_length: searchQuery.length,
|
|
1552
|
-
results_count: results_0.length
|
|
1553
|
-
});
|
|
1554
|
-
} catch (t362) {
|
|
1555
|
-
const error = t362;
|
|
1556
|
-
if (abortController.signal.aborted) {
|
|
1557
|
-
return;
|
|
1558
|
-
}
|
|
1559
|
-
setAgenticSearchState({
|
|
1560
|
-
status: "error",
|
|
1561
|
-
message: error instanceof Error ? error.message : "Search failed"
|
|
1562
|
-
});
|
|
1563
|
-
logEvent("tengu_agentic_search_error", {
|
|
1564
|
-
query_length: searchQuery.length
|
|
1565
|
-
});
|
|
1566
|
-
}
|
|
1567
|
-
};
|
|
1568
|
-
$[94] = logs;
|
|
1569
|
-
$[95] = onAgenticSearch;
|
|
1570
|
-
$[96] = searchQuery;
|
|
1571
|
-
$[97] = t35;
|
|
1572
|
-
} else {
|
|
1573
|
-
t35 = $[97];
|
|
1574
|
-
}
|
|
1575
|
-
const handleAgenticSearch = t35;
|
|
1576
|
-
let t36;
|
|
1577
|
-
if ($[98] !== agenticSearchState.query || $[99] !== agenticSearchState.status || $[100] !== searchQuery) {
|
|
1578
|
-
t36 = () => {
|
|
1579
|
-
if (agenticSearchState.status !== "idle" && agenticSearchState.status !== "searching") {
|
|
1580
|
-
if (agenticSearchState.status === "results" && agenticSearchState.query !== searchQuery || agenticSearchState.status === "error") {
|
|
1581
|
-
setAgenticSearchState({
|
|
1582
|
-
status: "idle"
|
|
1583
|
-
});
|
|
1584
|
-
}
|
|
1585
|
-
}
|
|
1586
|
-
};
|
|
1587
|
-
$[98] = agenticSearchState.query;
|
|
1588
|
-
$[99] = agenticSearchState.status;
|
|
1589
|
-
$[100] = searchQuery;
|
|
1590
|
-
$[101] = t36;
|
|
1591
|
-
} else {
|
|
1592
|
-
t36 = $[101];
|
|
1593
|
-
}
|
|
1594
|
-
let t37;
|
|
1595
|
-
if ($[102] !== agenticSearchState || $[103] !== searchQuery) {
|
|
1596
|
-
t37 = [searchQuery, agenticSearchState];
|
|
1597
|
-
$[102] = agenticSearchState;
|
|
1598
|
-
$[103] = searchQuery;
|
|
1599
|
-
$[104] = t37;
|
|
1600
|
-
} else {
|
|
1601
|
-
t37 = $[104];
|
|
1602
|
-
}
|
|
1603
|
-
import_react3.default.useEffect(t36, t37);
|
|
1604
|
-
let t38;
|
|
1605
|
-
let t39;
|
|
1606
|
-
if ($[105] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1607
|
-
t38 = () => () => {
|
|
1608
|
-
agenticSearchAbortRef.current?.abort();
|
|
1609
|
-
};
|
|
1610
|
-
t39 = [];
|
|
1611
|
-
$[105] = t38;
|
|
1612
|
-
$[106] = t39;
|
|
1613
|
-
} else {
|
|
1614
|
-
t38 = $[105];
|
|
1615
|
-
t39 = $[106];
|
|
1616
|
-
}
|
|
1617
|
-
import_react3.default.useEffect(t38, t39);
|
|
1618
|
-
const prevAgenticStatusRef = import_react3.default.useRef(agenticSearchState.status);
|
|
1619
|
-
let t40;
|
|
1620
|
-
if ($[107] !== agenticSearchState.status || $[108] !== displayedLogs[0] || $[109] !== displayedLogs.length || $[110] !== treeNodes) {
|
|
1621
|
-
t40 = () => {
|
|
1622
|
-
const prevStatus = prevAgenticStatusRef.current;
|
|
1623
|
-
prevAgenticStatusRef.current = agenticSearchState.status;
|
|
1624
|
-
if (prevStatus === "searching" && agenticSearchState.status === "results") {
|
|
1625
|
-
if (isResumeWithRenameEnabled && treeNodes.length > 0) {
|
|
1626
|
-
setFocusedNode(treeNodes[0]);
|
|
1627
|
-
} else {
|
|
1628
|
-
if (!isResumeWithRenameEnabled && displayedLogs.length > 0) {
|
|
1629
|
-
const firstLog = displayedLogs[0];
|
|
1630
|
-
setFocusedNode({
|
|
1631
|
-
id: "0",
|
|
1632
|
-
value: {
|
|
1633
|
-
log: firstLog,
|
|
1634
|
-
indexInFiltered: 0
|
|
1635
|
-
},
|
|
1636
|
-
label: ""
|
|
1637
|
-
});
|
|
1638
|
-
}
|
|
1639
|
-
}
|
|
1640
|
-
}
|
|
1641
|
-
};
|
|
1642
|
-
$[107] = agenticSearchState.status;
|
|
1643
|
-
$[108] = displayedLogs[0];
|
|
1644
|
-
$[109] = displayedLogs.length;
|
|
1645
|
-
$[110] = treeNodes;
|
|
1646
|
-
$[111] = t40;
|
|
1647
|
-
} else {
|
|
1648
|
-
t40 = $[111];
|
|
1649
|
-
}
|
|
1650
|
-
let t41;
|
|
1651
|
-
if ($[112] !== agenticSearchState.status || $[113] !== displayedLogs || $[114] !== treeNodes) {
|
|
1652
|
-
t41 = [agenticSearchState.status, isResumeWithRenameEnabled, treeNodes, displayedLogs];
|
|
1653
|
-
$[112] = agenticSearchState.status;
|
|
1654
|
-
$[113] = displayedLogs;
|
|
1655
|
-
$[114] = treeNodes;
|
|
1656
|
-
$[115] = t41;
|
|
1657
|
-
} else {
|
|
1658
|
-
t41 = $[115];
|
|
1659
|
-
}
|
|
1660
|
-
import_react3.default.useEffect(t40, t41);
|
|
1661
|
-
let t42;
|
|
1662
|
-
if ($[116] !== displayedLogs) {
|
|
1663
|
-
t42 = (value) => {
|
|
1664
|
-
const index_1 = parseInt(value, 10);
|
|
1665
|
-
const log_11 = displayedLogs[index_1];
|
|
1666
|
-
if (!log_11 || prevFocusedIdRef.current === index_1.toString()) {
|
|
1667
|
-
return;
|
|
1668
|
-
}
|
|
1669
|
-
prevFocusedIdRef.current = index_1.toString();
|
|
1670
|
-
setFocusedNode({
|
|
1671
|
-
id: index_1.toString(),
|
|
1672
|
-
value: {
|
|
1673
|
-
log: log_11,
|
|
1674
|
-
indexInFiltered: index_1
|
|
1675
|
-
},
|
|
1676
|
-
label: ""
|
|
1677
|
-
});
|
|
1678
|
-
setFocusedIndex(index_1 + 1);
|
|
1679
|
-
};
|
|
1680
|
-
$[116] = displayedLogs;
|
|
1681
|
-
$[117] = t42;
|
|
1682
|
-
} else {
|
|
1683
|
-
t42 = $[117];
|
|
1684
|
-
}
|
|
1685
|
-
const handleFlatOptionsSelectFocus = t42;
|
|
1686
|
-
let t43;
|
|
1687
|
-
if ($[118] !== displayedLogs) {
|
|
1688
|
-
t43 = (node) => {
|
|
1689
|
-
setFocusedNode(node);
|
|
1690
|
-
const index_2 = displayedLogs.findIndex((log_12) => getSessionIdFromLog(log_12) === getSessionIdFromLog(node.value.log));
|
|
1691
|
-
if (index_2 >= 0) {
|
|
1692
|
-
setFocusedIndex(index_2 + 1);
|
|
1693
|
-
}
|
|
1694
|
-
};
|
|
1695
|
-
$[118] = displayedLogs;
|
|
1696
|
-
$[119] = t43;
|
|
1697
|
-
} else {
|
|
1698
|
-
t43 = $[119];
|
|
1699
|
-
}
|
|
1700
|
-
const handleTreeSelectFocus = t43;
|
|
1701
|
-
let t44;
|
|
1702
|
-
if ($[120] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1703
|
-
t44 = () => {
|
|
1704
|
-
agenticSearchAbortRef.current?.abort();
|
|
1705
|
-
setAgenticSearchState({
|
|
1706
|
-
status: "idle"
|
|
1707
|
-
});
|
|
1708
|
-
logEvent("tengu_agentic_search_cancelled", {});
|
|
1709
|
-
};
|
|
1710
|
-
$[120] = t44;
|
|
1711
|
-
} else {
|
|
1712
|
-
t44 = $[120];
|
|
1713
|
-
}
|
|
1714
|
-
const t45 = viewMode !== "preview" && agenticSearchState.status === "searching";
|
|
1715
|
-
let t46;
|
|
1716
|
-
if ($[121] !== t45) {
|
|
1717
|
-
t46 = {
|
|
1718
|
-
context: "Confirmation",
|
|
1719
|
-
isActive: t45
|
|
1720
|
-
};
|
|
1721
|
-
$[121] = t45;
|
|
1722
|
-
$[122] = t46;
|
|
1723
|
-
} else {
|
|
1724
|
-
t46 = $[122];
|
|
1725
|
-
}
|
|
1726
|
-
useKeybinding("confirm:no", t44, t46);
|
|
1727
|
-
let t47;
|
|
1728
|
-
if ($[123] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1729
|
-
t47 = () => {
|
|
1730
|
-
setViewMode("list");
|
|
1731
|
-
setRenameValue("");
|
|
1732
|
-
};
|
|
1733
|
-
$[123] = t47;
|
|
1734
|
-
} else {
|
|
1735
|
-
t47 = $[123];
|
|
1736
|
-
}
|
|
1737
|
-
const t48 = viewMode === "rename" && agenticSearchState.status !== "searching";
|
|
1738
|
-
let t49;
|
|
1739
|
-
if ($[124] !== t48) {
|
|
1740
|
-
t49 = {
|
|
1741
|
-
context: "Settings",
|
|
1742
|
-
isActive: t48
|
|
1743
|
-
};
|
|
1744
|
-
$[124] = t48;
|
|
1745
|
-
$[125] = t49;
|
|
1746
|
-
} else {
|
|
1747
|
-
t49 = $[125];
|
|
1748
|
-
}
|
|
1749
|
-
useKeybinding("confirm:no", t47, t49);
|
|
1750
|
-
let t50;
|
|
1751
|
-
if ($[126] !== onCancel || $[127] !== setSearchQuery) {
|
|
1752
|
-
t50 = () => {
|
|
1753
|
-
setSearchQuery("");
|
|
1754
|
-
setIsAgenticSearchOptionFocused(false);
|
|
1755
|
-
onCancel?.();
|
|
1756
|
-
};
|
|
1757
|
-
$[126] = onCancel;
|
|
1758
|
-
$[127] = setSearchQuery;
|
|
1759
|
-
$[128] = t50;
|
|
1760
|
-
} else {
|
|
1761
|
-
t50 = $[128];
|
|
1762
|
-
}
|
|
1763
|
-
const t51 = viewMode !== "preview" && viewMode !== "rename" && viewMode !== "search" && isAgenticSearchOptionFocused && agenticSearchState.status !== "searching";
|
|
1764
|
-
let t52;
|
|
1765
|
-
if ($[129] !== t51) {
|
|
1766
|
-
t52 = {
|
|
1767
|
-
context: "Confirmation",
|
|
1768
|
-
isActive: t51
|
|
1769
|
-
};
|
|
1770
|
-
$[129] = t51;
|
|
1771
|
-
$[130] = t52;
|
|
1772
|
-
} else {
|
|
1773
|
-
t52 = $[130];
|
|
1774
|
-
}
|
|
1775
|
-
useKeybinding("confirm:no", t50, t52);
|
|
1776
|
-
let t53;
|
|
1777
|
-
if ($[131] !== agenticSearchState.status || $[132] !== branchFilterEnabled || $[133] !== focusedLog || $[134] !== handleAgenticSearch || $[135] !== hasMultipleWorktrees || $[136] !== hasTags || $[137] !== isAgenticSearchOptionFocused || $[138] !== onAgenticSearch || $[139] !== onToggleAllProjects || $[140] !== searchQuery || $[141] !== setSearchQuery || $[142] !== showAllProjects || $[143] !== showAllWorktrees || $[144] !== tagTabs || $[145] !== uniqueTags || $[146] !== viewMode) {
|
|
1778
|
-
t53 = (input, key) => {
|
|
1779
|
-
if (viewMode === "preview") {
|
|
1780
|
-
return;
|
|
1781
|
-
}
|
|
1782
|
-
if (agenticSearchState.status === "searching") {
|
|
1783
|
-
return;
|
|
1784
|
-
}
|
|
1785
|
-
if (viewMode === "rename") {} else {
|
|
1786
|
-
if (viewMode === "search") {
|
|
1787
|
-
if (input.toLowerCase() === "n" && key.ctrl) {
|
|
1788
|
-
exitSearchMode();
|
|
1789
|
-
} else {
|
|
1790
|
-
if (key.return || key.downArrow) {
|
|
1791
|
-
if (searchQuery.trim() && onAgenticSearch && false) {}
|
|
1792
|
-
}
|
|
1793
|
-
}
|
|
1794
|
-
} else {
|
|
1795
|
-
if (isAgenticSearchOptionFocused) {
|
|
1796
|
-
if (key.return) {
|
|
1797
|
-
handleAgenticSearch();
|
|
1798
|
-
setIsAgenticSearchOptionFocused(false);
|
|
1799
|
-
return;
|
|
1800
|
-
} else {
|
|
1801
|
-
if (key.downArrow) {
|
|
1802
|
-
setIsAgenticSearchOptionFocused(false);
|
|
1803
|
-
return;
|
|
1804
|
-
} else {
|
|
1805
|
-
if (key.upArrow) {
|
|
1806
|
-
setViewMode("search");
|
|
1807
|
-
setIsAgenticSearchOptionFocused(false);
|
|
1808
|
-
return;
|
|
1809
|
-
}
|
|
1810
|
-
}
|
|
1811
|
-
}
|
|
1812
|
-
}
|
|
1813
|
-
if (hasTags && key.tab) {
|
|
1814
|
-
const offset = key.shift ? -1 : 1;
|
|
1815
|
-
setSelectedTagIndex((prev) => {
|
|
1816
|
-
const current = prev < tagTabs.length ? prev : 0;
|
|
1817
|
-
const newIndex = (current + tagTabs.length + offset) % tagTabs.length;
|
|
1818
|
-
const newTab = tagTabs[newIndex];
|
|
1819
|
-
logEvent("tengu_session_tag_filter_changed", {
|
|
1820
|
-
is_all: newTab === "All",
|
|
1821
|
-
tag_count: uniqueTags.length
|
|
1822
|
-
});
|
|
1823
|
-
return newIndex;
|
|
1824
|
-
});
|
|
1825
|
-
return;
|
|
1826
|
-
}
|
|
1827
|
-
const keyIsNotCtrlOrMeta = !key.ctrl && !key.meta;
|
|
1828
|
-
const lowerInput = input.toLowerCase();
|
|
1829
|
-
if (lowerInput === "a" && key.ctrl && onToggleAllProjects) {
|
|
1830
|
-
onToggleAllProjects();
|
|
1831
|
-
logEvent("tengu_session_all_projects_toggled", {
|
|
1832
|
-
enabled: !showAllProjects
|
|
1833
|
-
});
|
|
1834
|
-
} else {
|
|
1835
|
-
if (lowerInput === "b" && key.ctrl) {
|
|
1836
|
-
const newEnabled = !branchFilterEnabled;
|
|
1837
|
-
setBranchFilterEnabled(newEnabled);
|
|
1838
|
-
logEvent("tengu_session_branch_filter_toggled", {
|
|
1839
|
-
enabled: newEnabled
|
|
1840
|
-
});
|
|
1841
|
-
} else {
|
|
1842
|
-
if (lowerInput === "w" && key.ctrl && hasMultipleWorktrees) {
|
|
1843
|
-
const newValue = !showAllWorktrees;
|
|
1844
|
-
setShowAllWorktrees(newValue);
|
|
1845
|
-
logEvent("tengu_session_worktree_filter_toggled", {
|
|
1846
|
-
enabled: newValue
|
|
1847
|
-
});
|
|
1848
|
-
} else {
|
|
1849
|
-
if (lowerInput === "/" && keyIsNotCtrlOrMeta) {
|
|
1850
|
-
setViewMode("search");
|
|
1851
|
-
logEvent("tengu_session_search_toggled", {
|
|
1852
|
-
enabled: true
|
|
1853
|
-
});
|
|
1854
|
-
} else {
|
|
1855
|
-
if (lowerInput === "r" && key.ctrl && focusedLog) {
|
|
1856
|
-
setViewMode("rename");
|
|
1857
|
-
setRenameValue("");
|
|
1858
|
-
logEvent("tengu_session_rename_started", {});
|
|
1859
|
-
} else {
|
|
1860
|
-
if (lowerInput === "v" && key.ctrl && focusedLog) {
|
|
1861
|
-
setPreviewLog(focusedLog);
|
|
1862
|
-
setViewMode("preview");
|
|
1863
|
-
logEvent("tengu_session_preview_opened", {
|
|
1864
|
-
messageCount: focusedLog.messageCount
|
|
1865
|
-
});
|
|
1866
|
-
} else {
|
|
1867
|
-
if (focusedLog && keyIsNotCtrlOrMeta && input.length > 0 && !/^\s+$/.test(input)) {
|
|
1868
|
-
setViewMode("search");
|
|
1869
|
-
setSearchQuery(input);
|
|
1870
|
-
logEvent("tengu_session_search_toggled", {
|
|
1871
|
-
enabled: true
|
|
1872
|
-
});
|
|
1873
|
-
}
|
|
1874
|
-
}
|
|
1875
|
-
}
|
|
1876
|
-
}
|
|
1877
|
-
}
|
|
1878
|
-
}
|
|
1879
|
-
}
|
|
1880
|
-
}
|
|
1881
|
-
}
|
|
1882
|
-
};
|
|
1883
|
-
$[131] = agenticSearchState.status;
|
|
1884
|
-
$[132] = branchFilterEnabled;
|
|
1885
|
-
$[133] = focusedLog;
|
|
1886
|
-
$[134] = handleAgenticSearch;
|
|
1887
|
-
$[135] = hasMultipleWorktrees;
|
|
1888
|
-
$[136] = hasTags;
|
|
1889
|
-
$[137] = isAgenticSearchOptionFocused;
|
|
1890
|
-
$[138] = onAgenticSearch;
|
|
1891
|
-
$[139] = onToggleAllProjects;
|
|
1892
|
-
$[140] = searchQuery;
|
|
1893
|
-
$[141] = setSearchQuery;
|
|
1894
|
-
$[142] = showAllProjects;
|
|
1895
|
-
$[143] = showAllWorktrees;
|
|
1896
|
-
$[144] = tagTabs;
|
|
1897
|
-
$[145] = uniqueTags;
|
|
1898
|
-
$[146] = viewMode;
|
|
1899
|
-
$[147] = t53;
|
|
1900
|
-
} else {
|
|
1901
|
-
t53 = $[147];
|
|
1902
|
-
}
|
|
1903
|
-
let t54;
|
|
1904
|
-
if ($[148] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1905
|
-
t54 = {
|
|
1906
|
-
isActive: true
|
|
1907
|
-
};
|
|
1908
|
-
$[148] = t54;
|
|
1909
|
-
} else {
|
|
1910
|
-
t54 = $[148];
|
|
1911
|
-
}
|
|
1912
|
-
use_input_default(t53, t54);
|
|
1913
|
-
let filterIndicators;
|
|
1914
|
-
if ($[149] !== branchFilterEnabled || $[150] !== currentBranch || $[151] !== hasMultipleWorktrees || $[152] !== showAllWorktrees) {
|
|
1915
|
-
filterIndicators = [];
|
|
1916
|
-
if (branchFilterEnabled && currentBranch) {
|
|
1917
|
-
filterIndicators.push(currentBranch);
|
|
1918
|
-
}
|
|
1919
|
-
if (hasMultipleWorktrees && !showAllWorktrees) {
|
|
1920
|
-
filterIndicators.push("current worktree");
|
|
1921
|
-
}
|
|
1922
|
-
$[149] = branchFilterEnabled;
|
|
1923
|
-
$[150] = currentBranch;
|
|
1924
|
-
$[151] = hasMultipleWorktrees;
|
|
1925
|
-
$[152] = showAllWorktrees;
|
|
1926
|
-
$[153] = filterIndicators;
|
|
1927
|
-
} else {
|
|
1928
|
-
filterIndicators = $[153];
|
|
1929
|
-
}
|
|
1930
|
-
const showAdditionalFilterLine = filterIndicators.length > 0 && viewMode !== "search";
|
|
1931
|
-
const headerLines = 8 + (showAdditionalFilterLine ? 1 : 0) + tagTabsLines;
|
|
1932
|
-
const visibleCount = Math.max(1, Math.floor((maxHeight - headerLines - 2) / 3));
|
|
1933
|
-
let t55;
|
|
1934
|
-
let t56;
|
|
1935
|
-
if ($[154] !== displayedLogs.length || $[155] !== focusedIndex || $[156] !== onLoadMore || $[157] !== visibleCount) {
|
|
1936
|
-
t55 = () => {
|
|
1937
|
-
if (!onLoadMore) {
|
|
1938
|
-
return;
|
|
1939
|
-
}
|
|
1940
|
-
const buffer = visibleCount * 2;
|
|
1941
|
-
if (focusedIndex + buffer >= displayedLogs.length) {
|
|
1942
|
-
onLoadMore(visibleCount * 3);
|
|
1943
|
-
}
|
|
1944
|
-
};
|
|
1945
|
-
t56 = [focusedIndex, visibleCount, displayedLogs.length, onLoadMore];
|
|
1946
|
-
$[154] = displayedLogs.length;
|
|
1947
|
-
$[155] = focusedIndex;
|
|
1948
|
-
$[156] = onLoadMore;
|
|
1949
|
-
$[157] = visibleCount;
|
|
1950
|
-
$[158] = t55;
|
|
1951
|
-
$[159] = t56;
|
|
1952
|
-
} else {
|
|
1953
|
-
t55 = $[158];
|
|
1954
|
-
t56 = $[159];
|
|
1955
|
-
}
|
|
1956
|
-
import_react3.default.useEffect(t55, t56);
|
|
1957
|
-
if (logs.length === 0) {
|
|
1958
|
-
return null;
|
|
1959
|
-
}
|
|
1960
|
-
if (viewMode === "preview" && previewLog && isResumeWithRenameEnabled) {
|
|
1961
|
-
let t572;
|
|
1962
|
-
if ($[160] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1963
|
-
t572 = () => {
|
|
1964
|
-
setViewMode("list");
|
|
1965
|
-
setPreviewLog(null);
|
|
1966
|
-
};
|
|
1967
|
-
$[160] = t572;
|
|
1968
|
-
} else {
|
|
1969
|
-
t572 = $[160];
|
|
1970
|
-
}
|
|
1971
|
-
let t582;
|
|
1972
|
-
if ($[161] !== onSelect || $[162] !== previewLog) {
|
|
1973
|
-
t582 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(SessionPreview, {
|
|
1974
|
-
log: previewLog,
|
|
1975
|
-
onExit: t572,
|
|
1976
|
-
onSelect
|
|
1977
|
-
}, undefined, false, undefined, this);
|
|
1978
|
-
$[161] = onSelect;
|
|
1979
|
-
$[162] = previewLog;
|
|
1980
|
-
$[163] = t582;
|
|
1981
|
-
} else {
|
|
1982
|
-
t582 = $[163];
|
|
1983
|
-
}
|
|
1984
|
-
return t582;
|
|
1985
|
-
}
|
|
1986
|
-
const t57 = maxHeight - 1;
|
|
1987
|
-
let t58;
|
|
1988
|
-
if ($[164] === Symbol.for("react.memo_cache_sentinel")) {
|
|
1989
|
-
t58 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
1990
|
-
flexShrink: 0,
|
|
1991
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Divider, {
|
|
1992
|
-
color: "suggestion"
|
|
1993
|
-
}, undefined, false, undefined, this)
|
|
1994
|
-
}, undefined, false, undefined, this);
|
|
1995
|
-
$[164] = t58;
|
|
1996
|
-
} else {
|
|
1997
|
-
t58 = $[164];
|
|
1998
|
-
}
|
|
1999
|
-
let t59;
|
|
2000
|
-
if ($[165] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2001
|
-
t59 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2002
|
-
flexShrink: 0,
|
|
2003
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2004
|
-
children: " "
|
|
2005
|
-
}, undefined, false, undefined, this)
|
|
2006
|
-
}, undefined, false, undefined, this);
|
|
2007
|
-
$[165] = t59;
|
|
2008
|
-
} else {
|
|
2009
|
-
t59 = $[165];
|
|
2010
|
-
}
|
|
2011
|
-
let t60;
|
|
2012
|
-
if ($[166] !== columns || $[167] !== displayedLogs.length || $[168] !== effectiveTagIndex || $[169] !== focusedIndex || $[170] !== hasTags || $[171] !== showAllProjects || $[172] !== tagTabs || $[173] !== viewMode || $[174] !== visibleCount) {
|
|
2013
|
-
t60 = hasTags ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(TagTabs, {
|
|
2014
|
-
tabs: tagTabs,
|
|
2015
|
-
selectedIndex: effectiveTagIndex,
|
|
2016
|
-
availableWidth: columns,
|
|
2017
|
-
showAllProjects
|
|
2018
|
-
}, undefined, false, undefined, this) : /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2019
|
-
flexShrink: 0,
|
|
2020
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2021
|
-
bold: true,
|
|
2022
|
-
color: "suggestion",
|
|
2023
|
-
children: [
|
|
2024
|
-
"Resume Session",
|
|
2025
|
-
viewMode === "list" && displayedLogs.length > visibleCount && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2026
|
-
dimColor: true,
|
|
2027
|
-
children: [
|
|
2028
|
-
" ",
|
|
2029
|
-
"(",
|
|
2030
|
-
focusedIndex,
|
|
2031
|
-
" of ",
|
|
2032
|
-
displayedLogs.length,
|
|
2033
|
-
")"
|
|
2034
|
-
]
|
|
2035
|
-
}, undefined, true, undefined, this)
|
|
2036
|
-
]
|
|
2037
|
-
}, undefined, true, undefined, this)
|
|
2038
|
-
}, undefined, false, undefined, this);
|
|
2039
|
-
$[166] = columns;
|
|
2040
|
-
$[167] = displayedLogs.length;
|
|
2041
|
-
$[168] = effectiveTagIndex;
|
|
2042
|
-
$[169] = focusedIndex;
|
|
2043
|
-
$[170] = hasTags;
|
|
2044
|
-
$[171] = showAllProjects;
|
|
2045
|
-
$[172] = tagTabs;
|
|
2046
|
-
$[173] = viewMode;
|
|
2047
|
-
$[174] = visibleCount;
|
|
2048
|
-
$[175] = t60;
|
|
2049
|
-
} else {
|
|
2050
|
-
t60 = $[175];
|
|
2051
|
-
}
|
|
2052
|
-
const t61 = viewMode === "search";
|
|
2053
|
-
let t62;
|
|
2054
|
-
if ($[176] !== isTerminalFocused || $[177] !== searchCursorOffset || $[178] !== searchQuery || $[179] !== t61) {
|
|
2055
|
-
t62 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(SearchBox, {
|
|
2056
|
-
query: searchQuery,
|
|
2057
|
-
isFocused: t61,
|
|
2058
|
-
isTerminalFocused,
|
|
2059
|
-
cursorOffset: searchCursorOffset
|
|
2060
|
-
}, undefined, false, undefined, this);
|
|
2061
|
-
$[176] = isTerminalFocused;
|
|
2062
|
-
$[177] = searchCursorOffset;
|
|
2063
|
-
$[178] = searchQuery;
|
|
2064
|
-
$[179] = t61;
|
|
2065
|
-
$[180] = t62;
|
|
2066
|
-
} else {
|
|
2067
|
-
t62 = $[180];
|
|
2068
|
-
}
|
|
2069
|
-
let t63;
|
|
2070
|
-
if ($[181] !== filterIndicators || $[182] !== viewMode) {
|
|
2071
|
-
t63 = filterIndicators.length > 0 && viewMode !== "search" && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2072
|
-
flexShrink: 0,
|
|
2073
|
-
paddingLeft: 2,
|
|
2074
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2075
|
-
dimColor: true,
|
|
2076
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Byline, {
|
|
2077
|
-
children: filterIndicators
|
|
2078
|
-
}, undefined, false, undefined, this)
|
|
2079
|
-
}, undefined, false, undefined, this)
|
|
2080
|
-
}, undefined, false, undefined, this);
|
|
2081
|
-
$[181] = filterIndicators;
|
|
2082
|
-
$[182] = viewMode;
|
|
2083
|
-
$[183] = t63;
|
|
2084
|
-
} else {
|
|
2085
|
-
t63 = $[183];
|
|
2086
|
-
}
|
|
2087
|
-
let t64;
|
|
2088
|
-
if ($[184] === Symbol.for("react.memo_cache_sentinel")) {
|
|
2089
|
-
t64 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2090
|
-
flexShrink: 0,
|
|
2091
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2092
|
-
children: " "
|
|
2093
|
-
}, undefined, false, undefined, this)
|
|
2094
|
-
}, undefined, false, undefined, this);
|
|
2095
|
-
$[184] = t64;
|
|
2096
|
-
} else {
|
|
2097
|
-
t64 = $[184];
|
|
2098
|
-
}
|
|
2099
|
-
let t65;
|
|
2100
|
-
if ($[185] !== agenticSearchState.status) {
|
|
2101
|
-
t65 = agenticSearchState.status === "searching" && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2102
|
-
paddingLeft: 1,
|
|
2103
|
-
flexShrink: 0,
|
|
2104
|
-
children: [
|
|
2105
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Spinner, {}, undefined, false, undefined, this),
|
|
2106
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2107
|
-
children: " Searching\u2026"
|
|
2108
|
-
}, undefined, false, undefined, this)
|
|
2109
|
-
]
|
|
2110
|
-
}, undefined, true, undefined, this);
|
|
2111
|
-
$[185] = agenticSearchState.status;
|
|
2112
|
-
$[186] = t65;
|
|
2113
|
-
} else {
|
|
2114
|
-
t65 = $[186];
|
|
2115
|
-
}
|
|
2116
|
-
let t66;
|
|
2117
|
-
if ($[187] !== agenticSearchState.results || $[188] !== agenticSearchState.status) {
|
|
2118
|
-
t66 = agenticSearchState.status === "results" && agenticSearchState.results.length > 0 && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2119
|
-
paddingLeft: 1,
|
|
2120
|
-
marginBottom: 1,
|
|
2121
|
-
flexShrink: 0,
|
|
2122
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2123
|
-
dimColor: true,
|
|
2124
|
-
italic: true,
|
|
2125
|
-
children: "Claude found these results:"
|
|
2126
|
-
}, undefined, false, undefined, this)
|
|
2127
|
-
}, undefined, false, undefined, this);
|
|
2128
|
-
$[187] = agenticSearchState.results;
|
|
2129
|
-
$[188] = agenticSearchState.status;
|
|
2130
|
-
$[189] = t66;
|
|
2131
|
-
} else {
|
|
2132
|
-
t66 = $[189];
|
|
2133
|
-
}
|
|
2134
|
-
let t67;
|
|
2135
|
-
if ($[190] !== agenticSearchState.results || $[191] !== agenticSearchState.status || $[192] !== filteredLogs) {
|
|
2136
|
-
t67 = agenticSearchState.status === "results" && agenticSearchState.results.length === 0 && filteredLogs.length === 0 && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2137
|
-
paddingLeft: 1,
|
|
2138
|
-
marginBottom: 1,
|
|
2139
|
-
flexShrink: 0,
|
|
2140
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2141
|
-
dimColor: true,
|
|
2142
|
-
italic: true,
|
|
2143
|
-
children: "No matching sessions found."
|
|
2144
|
-
}, undefined, false, undefined, this)
|
|
2145
|
-
}, undefined, false, undefined, this);
|
|
2146
|
-
$[190] = agenticSearchState.results;
|
|
2147
|
-
$[191] = agenticSearchState.status;
|
|
2148
|
-
$[192] = filteredLogs;
|
|
2149
|
-
$[193] = t67;
|
|
2150
|
-
} else {
|
|
2151
|
-
t67 = $[193];
|
|
2152
|
-
}
|
|
2153
|
-
let t68;
|
|
2154
|
-
if ($[194] !== agenticSearchState.status || $[195] !== filteredLogs) {
|
|
2155
|
-
t68 = agenticSearchState.status === "error" && filteredLogs.length === 0 && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2156
|
-
paddingLeft: 1,
|
|
2157
|
-
marginBottom: 1,
|
|
2158
|
-
flexShrink: 0,
|
|
2159
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2160
|
-
dimColor: true,
|
|
2161
|
-
italic: true,
|
|
2162
|
-
children: "No matching sessions found."
|
|
2163
|
-
}, undefined, false, undefined, this)
|
|
2164
|
-
}, undefined, false, undefined, this);
|
|
2165
|
-
$[194] = agenticSearchState.status;
|
|
2166
|
-
$[195] = filteredLogs;
|
|
2167
|
-
$[196] = t68;
|
|
2168
|
-
} else {
|
|
2169
|
-
t68 = $[196];
|
|
2170
|
-
}
|
|
2171
|
-
let t69;
|
|
2172
|
-
if ($[197] !== agenticSearchState.status || $[198] !== isAgenticSearchOptionFocused || $[199] !== onAgenticSearch || $[200] !== searchQuery) {
|
|
2173
|
-
t69 = Boolean(searchQuery.trim()) && onAgenticSearch && false;
|
|
2174
|
-
$[197] = agenticSearchState.status;
|
|
2175
|
-
$[198] = isAgenticSearchOptionFocused;
|
|
2176
|
-
$[199] = onAgenticSearch;
|
|
2177
|
-
$[200] = searchQuery;
|
|
2178
|
-
$[201] = t69;
|
|
2179
|
-
} else {
|
|
2180
|
-
t69 = $[201];
|
|
2181
|
-
}
|
|
2182
|
-
let t70;
|
|
2183
|
-
if ($[202] !== agenticSearchState.status || $[203] !== branchFilterEnabled || $[204] !== columns || $[205] !== displayedLogs || $[206] !== expandedGroupSessionIds || $[207] !== flatOptions || $[208] !== focusedLog || $[209] !== focusedNode?.id || $[210] !== handleFlatOptionsSelectFocus || $[211] !== handleRenameSubmit || $[212] !== handleTreeSelectFocus || $[213] !== isAgenticSearchOptionFocused || $[214] !== onCancel || $[215] !== onSelect || $[216] !== renameCursorOffset || $[217] !== renameValue || $[218] !== treeNodes || $[219] !== viewMode || $[220] !== visibleCount) {
|
|
2184
|
-
t70 = agenticSearchState.status === "searching" ? null : viewMode === "rename" && focusedLog ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2185
|
-
paddingLeft: 2,
|
|
2186
|
-
flexDirection: "column",
|
|
2187
|
-
children: [
|
|
2188
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2189
|
-
bold: true,
|
|
2190
|
-
children: "Rename session:"
|
|
2191
|
-
}, undefined, false, undefined, this),
|
|
2192
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2193
|
-
paddingTop: 1,
|
|
2194
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(TextInput, {
|
|
2195
|
-
value: renameValue,
|
|
2196
|
-
onChange: setRenameValue,
|
|
2197
|
-
onSubmit: handleRenameSubmit,
|
|
2198
|
-
placeholder: getLogDisplayTitle(focusedLog, "Enter new session name"),
|
|
2199
|
-
columns,
|
|
2200
|
-
cursorOffset: renameCursorOffset,
|
|
2201
|
-
onChangeCursorOffset: setRenameCursorOffset,
|
|
2202
|
-
showCursor: true
|
|
2203
|
-
}, undefined, false, undefined, this)
|
|
2204
|
-
}, undefined, false, undefined, this)
|
|
2205
|
-
]
|
|
2206
|
-
}, undefined, true, undefined, this) : isResumeWithRenameEnabled ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(TreeSelect, {
|
|
2207
|
-
nodes: treeNodes,
|
|
2208
|
-
onSelect: (node_0) => {
|
|
2209
|
-
onSelect(node_0.value.log);
|
|
2210
|
-
},
|
|
2211
|
-
onFocus: handleTreeSelectFocus,
|
|
2212
|
-
onCancel,
|
|
2213
|
-
focusNodeId: focusedNode?.id,
|
|
2214
|
-
visibleOptionCount: visibleCount,
|
|
2215
|
-
layout: "expanded",
|
|
2216
|
-
isDisabled: viewMode === "search" || isAgenticSearchOptionFocused,
|
|
2217
|
-
hideIndexes: false,
|
|
2218
|
-
isNodeExpanded: (nodeId) => {
|
|
2219
|
-
if (viewMode === "search" || branchFilterEnabled) {
|
|
2220
|
-
return true;
|
|
2221
|
-
}
|
|
2222
|
-
const sessionId_2 = typeof nodeId === "string" && nodeId.startsWith("group:") ? nodeId.substring(6) : null;
|
|
2223
|
-
return sessionId_2 ? expandedGroupSessionIds.has(sessionId_2) : false;
|
|
2224
|
-
},
|
|
2225
|
-
onExpand: (nodeId_0) => {
|
|
2226
|
-
const sessionId_3 = typeof nodeId_0 === "string" && nodeId_0.startsWith("group:") ? nodeId_0.substring(6) : null;
|
|
2227
|
-
if (sessionId_3) {
|
|
2228
|
-
setExpandedGroupSessionIds((prev_0) => new Set(prev_0).add(sessionId_3));
|
|
2229
|
-
logEvent("tengu_session_group_expanded", {});
|
|
2230
|
-
}
|
|
2231
|
-
},
|
|
2232
|
-
onCollapse: (nodeId_1) => {
|
|
2233
|
-
const sessionId_4 = typeof nodeId_1 === "string" && nodeId_1.startsWith("group:") ? nodeId_1.substring(6) : null;
|
|
2234
|
-
if (sessionId_4) {
|
|
2235
|
-
setExpandedGroupSessionIds((prev_1) => {
|
|
2236
|
-
const newSet = new Set(prev_1);
|
|
2237
|
-
newSet.delete(sessionId_4);
|
|
2238
|
-
return newSet;
|
|
2239
|
-
});
|
|
2240
|
-
}
|
|
2241
|
-
},
|
|
2242
|
-
onUpFromFirstItem: enterSearchMode
|
|
2243
|
-
}, undefined, false, undefined, this) : /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Select, {
|
|
2244
|
-
options: flatOptions,
|
|
2245
|
-
onChange: (value_0) => {
|
|
2246
|
-
const itemIndex = parseInt(value_0, 10);
|
|
2247
|
-
const log_13 = displayedLogs[itemIndex];
|
|
2248
|
-
if (log_13) {
|
|
2249
|
-
onSelect(log_13);
|
|
2250
|
-
}
|
|
2251
|
-
},
|
|
2252
|
-
visibleOptionCount: visibleCount,
|
|
2253
|
-
onCancel,
|
|
2254
|
-
onFocus: handleFlatOptionsSelectFocus,
|
|
2255
|
-
defaultFocusValue: focusedNode?.id.toString(),
|
|
2256
|
-
layout: "expanded",
|
|
2257
|
-
isDisabled: viewMode === "search" || isAgenticSearchOptionFocused,
|
|
2258
|
-
onUpFromFirstItem: enterSearchMode
|
|
2259
|
-
}, undefined, false, undefined, this);
|
|
2260
|
-
$[202] = agenticSearchState.status;
|
|
2261
|
-
$[203] = branchFilterEnabled;
|
|
2262
|
-
$[204] = columns;
|
|
2263
|
-
$[205] = displayedLogs;
|
|
2264
|
-
$[206] = expandedGroupSessionIds;
|
|
2265
|
-
$[207] = flatOptions;
|
|
2266
|
-
$[208] = focusedLog;
|
|
2267
|
-
$[209] = focusedNode?.id;
|
|
2268
|
-
$[210] = handleFlatOptionsSelectFocus;
|
|
2269
|
-
$[211] = handleRenameSubmit;
|
|
2270
|
-
$[212] = handleTreeSelectFocus;
|
|
2271
|
-
$[213] = isAgenticSearchOptionFocused;
|
|
2272
|
-
$[214] = onCancel;
|
|
2273
|
-
$[215] = onSelect;
|
|
2274
|
-
$[216] = renameCursorOffset;
|
|
2275
|
-
$[217] = renameValue;
|
|
2276
|
-
$[218] = treeNodes;
|
|
2277
|
-
$[219] = viewMode;
|
|
2278
|
-
$[220] = visibleCount;
|
|
2279
|
-
$[221] = t70;
|
|
2280
|
-
} else {
|
|
2281
|
-
t70 = $[221];
|
|
2282
|
-
}
|
|
2283
|
-
let t71;
|
|
2284
|
-
if ($[222] !== agenticSearchState.status || $[223] !== currentBranch || $[224] !== exitState.keyName || $[225] !== exitState.pending || $[226] !== getExpandCollapseHint || $[227] !== hasMultipleWorktrees || $[228] !== isAgenticSearchOptionFocused || $[229] !== isSearching || $[230] !== onToggleAllProjects || $[231] !== showAllProjects || $[232] !== showAllWorktrees || $[233] !== viewMode) {
|
|
2285
|
-
t71 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2286
|
-
paddingLeft: 2,
|
|
2287
|
-
children: exitState.pending ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2288
|
-
dimColor: true,
|
|
2289
|
-
children: [
|
|
2290
|
-
"Press ",
|
|
2291
|
-
exitState.keyName,
|
|
2292
|
-
" again to exit"
|
|
2293
|
-
]
|
|
2294
|
-
}, undefined, true, undefined, this) : viewMode === "rename" ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2295
|
-
dimColor: true,
|
|
2296
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Byline, {
|
|
2297
|
-
children: [
|
|
2298
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2299
|
-
shortcut: "Enter",
|
|
2300
|
-
action: "save"
|
|
2301
|
-
}, undefined, false, undefined, this),
|
|
2302
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ConfigurableShortcutHint, {
|
|
2303
|
-
action: "confirm:no",
|
|
2304
|
-
context: "Confirmation",
|
|
2305
|
-
fallback: "Esc",
|
|
2306
|
-
description: "cancel"
|
|
2307
|
-
}, undefined, false, undefined, this)
|
|
2308
|
-
]
|
|
2309
|
-
}, undefined, true, undefined, this)
|
|
2310
|
-
}, undefined, false, undefined, this) : agenticSearchState.status === "searching" ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2311
|
-
dimColor: true,
|
|
2312
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Byline, {
|
|
2313
|
-
children: [
|
|
2314
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2315
|
-
children: "Searching with Claude\u2026"
|
|
2316
|
-
}, undefined, false, undefined, this),
|
|
2317
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ConfigurableShortcutHint, {
|
|
2318
|
-
action: "confirm:no",
|
|
2319
|
-
context: "Confirmation",
|
|
2320
|
-
fallback: "Esc",
|
|
2321
|
-
description: "cancel"
|
|
2322
|
-
}, undefined, false, undefined, this)
|
|
2323
|
-
]
|
|
2324
|
-
}, undefined, true, undefined, this)
|
|
2325
|
-
}, undefined, false, undefined, this) : isAgenticSearchOptionFocused ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2326
|
-
dimColor: true,
|
|
2327
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Byline, {
|
|
2328
|
-
children: [
|
|
2329
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2330
|
-
shortcut: "Enter",
|
|
2331
|
-
action: "search"
|
|
2332
|
-
}, undefined, false, undefined, this),
|
|
2333
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2334
|
-
shortcut: "\u2193",
|
|
2335
|
-
action: "skip"
|
|
2336
|
-
}, undefined, false, undefined, this),
|
|
2337
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ConfigurableShortcutHint, {
|
|
2338
|
-
action: "confirm:no",
|
|
2339
|
-
context: "Confirmation",
|
|
2340
|
-
fallback: "Esc",
|
|
2341
|
-
description: "cancel"
|
|
2342
|
-
}, undefined, false, undefined, this)
|
|
2343
|
-
]
|
|
2344
|
-
}, undefined, true, undefined, this)
|
|
2345
|
-
}, undefined, false, undefined, this) : viewMode === "search" ? /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2346
|
-
dimColor: true,
|
|
2347
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Byline, {
|
|
2348
|
-
children: [
|
|
2349
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2350
|
-
children: "Type to Search"
|
|
2351
|
-
}, undefined, false, undefined, this),
|
|
2352
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2353
|
-
shortcut: "Enter",
|
|
2354
|
-
action: "select"
|
|
2355
|
-
}, undefined, false, undefined, this),
|
|
2356
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ConfigurableShortcutHint, {
|
|
2357
|
-
action: "confirm:no",
|
|
2358
|
-
context: "Confirmation",
|
|
2359
|
-
fallback: "Esc",
|
|
2360
|
-
description: "clear"
|
|
2361
|
-
}, undefined, false, undefined, this)
|
|
2362
|
-
]
|
|
2363
|
-
}, undefined, true, undefined, this)
|
|
2364
|
-
}, undefined, false, undefined, this) : /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2365
|
-
dimColor: true,
|
|
2366
|
-
children: /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(Byline, {
|
|
2367
|
-
children: [
|
|
2368
|
-
onToggleAllProjects && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2369
|
-
shortcut: "Ctrl+A",
|
|
2370
|
-
action: `show ${showAllProjects ? "current dir" : "all projects"}`
|
|
2371
|
-
}, undefined, false, undefined, this),
|
|
2372
|
-
currentBranch && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2373
|
-
shortcut: "Ctrl+B",
|
|
2374
|
-
action: "toggle branch"
|
|
2375
|
-
}, undefined, false, undefined, this),
|
|
2376
|
-
hasMultipleWorktrees && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2377
|
-
shortcut: "Ctrl+W",
|
|
2378
|
-
action: `show ${showAllWorktrees ? "current worktree" : "all worktrees"}`
|
|
2379
|
-
}, undefined, false, undefined, this),
|
|
2380
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2381
|
-
shortcut: "Ctrl+V",
|
|
2382
|
-
action: "preview"
|
|
2383
|
-
}, undefined, false, undefined, this),
|
|
2384
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(KeyboardShortcutHint, {
|
|
2385
|
-
shortcut: "Ctrl+R",
|
|
2386
|
-
action: "rename"
|
|
2387
|
-
}, undefined, false, undefined, this),
|
|
2388
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2389
|
-
children: "Type to search"
|
|
2390
|
-
}, undefined, false, undefined, this),
|
|
2391
|
-
/* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ConfigurableShortcutHint, {
|
|
2392
|
-
action: "confirm:no",
|
|
2393
|
-
context: "Confirmation",
|
|
2394
|
-
fallback: "Esc",
|
|
2395
|
-
description: "cancel"
|
|
2396
|
-
}, undefined, false, undefined, this),
|
|
2397
|
-
getExpandCollapseHint() && /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedText, {
|
|
2398
|
-
children: getExpandCollapseHint()
|
|
2399
|
-
}, undefined, false, undefined, this)
|
|
2400
|
-
]
|
|
2401
|
-
}, undefined, true, undefined, this)
|
|
2402
|
-
}, undefined, false, undefined, this)
|
|
2403
|
-
}, undefined, false, undefined, this);
|
|
2404
|
-
$[222] = agenticSearchState.status;
|
|
2405
|
-
$[223] = currentBranch;
|
|
2406
|
-
$[224] = exitState.keyName;
|
|
2407
|
-
$[225] = exitState.pending;
|
|
2408
|
-
$[226] = getExpandCollapseHint;
|
|
2409
|
-
$[227] = hasMultipleWorktrees;
|
|
2410
|
-
$[228] = isAgenticSearchOptionFocused;
|
|
2411
|
-
$[229] = isSearching;
|
|
2412
|
-
$[230] = onToggleAllProjects;
|
|
2413
|
-
$[231] = showAllProjects;
|
|
2414
|
-
$[232] = showAllWorktrees;
|
|
2415
|
-
$[233] = viewMode;
|
|
2416
|
-
$[234] = t71;
|
|
2417
|
-
} else {
|
|
2418
|
-
t71 = $[234];
|
|
2419
|
-
}
|
|
2420
|
-
let t72;
|
|
2421
|
-
if ($[235] !== t57 || $[236] !== t60 || $[237] !== t62 || $[238] !== t63 || $[239] !== t65 || $[240] !== t66 || $[241] !== t67 || $[242] !== t68 || $[243] !== t69 || $[244] !== t70 || $[245] !== t71) {
|
|
2422
|
-
t72 = /* @__PURE__ */ jsx_dev_runtime4.jsxDEV(ThemedBox_default, {
|
|
2423
|
-
flexDirection: "column",
|
|
2424
|
-
height: t57,
|
|
2425
|
-
children: [
|
|
2426
|
-
t58,
|
|
2427
|
-
t59,
|
|
2428
|
-
t60,
|
|
2429
|
-
t62,
|
|
2430
|
-
t63,
|
|
2431
|
-
t64,
|
|
2432
|
-
t65,
|
|
2433
|
-
t66,
|
|
2434
|
-
t67,
|
|
2435
|
-
t68,
|
|
2436
|
-
t69,
|
|
2437
|
-
t70,
|
|
2438
|
-
t71
|
|
2439
|
-
]
|
|
2440
|
-
}, undefined, true, undefined, this);
|
|
2441
|
-
$[235] = t57;
|
|
2442
|
-
$[236] = t60;
|
|
2443
|
-
$[237] = t62;
|
|
2444
|
-
$[238] = t63;
|
|
2445
|
-
$[239] = t65;
|
|
2446
|
-
$[240] = t66;
|
|
2447
|
-
$[241] = t67;
|
|
2448
|
-
$[242] = t68;
|
|
2449
|
-
$[243] = t69;
|
|
2450
|
-
$[244] = t70;
|
|
2451
|
-
$[245] = t71;
|
|
2452
|
-
$[246] = t72;
|
|
2453
|
-
} else {
|
|
2454
|
-
t72 = $[246];
|
|
2455
|
-
}
|
|
2456
|
-
return t72;
|
|
2457
|
-
}
|
|
2458
|
-
function _temp7(r_0) {
|
|
2459
|
-
return r_0.log;
|
|
2460
|
-
}
|
|
2461
|
-
function _temp6(log_6) {
|
|
2462
|
-
return log_6.messages[0]?.uuid;
|
|
2463
|
-
}
|
|
2464
|
-
function _temp5(fuseIndex_0, debouncedDeepSearchQuery_0, setDeepSearchResults_0, setIsSearching_0) {
|
|
2465
|
-
const results = fuseIndex_0.search(debouncedDeepSearchQuery_0);
|
|
2466
|
-
results.sort(_temp3);
|
|
2467
|
-
setDeepSearchResults_0({
|
|
2468
|
-
results: results.map(_temp4),
|
|
2469
|
-
query: debouncedDeepSearchQuery_0
|
|
2470
|
-
});
|
|
2471
|
-
setIsSearching_0(false);
|
|
2472
|
-
}
|
|
2473
|
-
function _temp4(r) {
|
|
2474
|
-
return {
|
|
2475
|
-
log: r.item.log,
|
|
2476
|
-
score: r.score,
|
|
2477
|
-
searchableText: r.item.searchableText
|
|
2478
|
-
};
|
|
2479
|
-
}
|
|
2480
|
-
function _temp3(a, b) {
|
|
2481
|
-
const aTime = new Date(a.item.log.modified).getTime();
|
|
2482
|
-
const bTime = new Date(b.item.log.modified).getTime();
|
|
2483
|
-
const timeDiff = bTime - aTime;
|
|
2484
|
-
if (Math.abs(timeDiff) > DATE_TIE_THRESHOLD_MS) {
|
|
2485
|
-
return timeDiff;
|
|
2486
|
-
}
|
|
2487
|
-
return (a.score ?? 1) - (b.score ?? 1);
|
|
2488
|
-
}
|
|
2489
|
-
function _temp22(log_1) {
|
|
2490
|
-
const currentSessionId = getSessionId();
|
|
2491
|
-
const logSessionId = getSessionIdFromLog(log_1);
|
|
2492
|
-
const isCurrentSession = currentSessionId && logSessionId === currentSessionId;
|
|
2493
|
-
if (isCurrentSession) {
|
|
2494
|
-
return true;
|
|
2495
|
-
}
|
|
2496
|
-
if (log_1.customTitle) {
|
|
2497
|
-
return true;
|
|
2498
|
-
}
|
|
2499
|
-
const fromMessages = getFirstMeaningfulUserMessageTextContent(log_1.messages);
|
|
2500
|
-
if (fromMessages) {
|
|
2501
|
-
return true;
|
|
2502
|
-
}
|
|
2503
|
-
if (log_1.firstPrompt || log_1.customTitle) {
|
|
2504
|
-
return true;
|
|
2505
|
-
}
|
|
2506
|
-
return false;
|
|
2507
|
-
}
|
|
2508
|
-
function _temp8(log) {
|
|
2509
|
-
return [log, buildSearchableText(log)];
|
|
2510
|
-
}
|
|
2511
|
-
function extractSearchableText(message) {
|
|
2512
|
-
if (message.type !== "user" && message.type !== "assistant") {
|
|
2513
|
-
return "";
|
|
2514
|
-
}
|
|
2515
|
-
const content = "message" in message ? message.message?.content : undefined;
|
|
2516
|
-
if (!content)
|
|
2517
|
-
return "";
|
|
2518
|
-
if (typeof content === "string") {
|
|
2519
|
-
return content;
|
|
2520
|
-
}
|
|
2521
|
-
if (Array.isArray(content)) {
|
|
2522
|
-
return content.map((block) => {
|
|
2523
|
-
if (typeof block === "string")
|
|
2524
|
-
return block;
|
|
2525
|
-
if ("text" in block && typeof block.text === "string")
|
|
2526
|
-
return block.text;
|
|
2527
|
-
return "";
|
|
2528
|
-
}).filter(Boolean).join(" ");
|
|
2529
|
-
}
|
|
2530
|
-
return "";
|
|
2531
|
-
}
|
|
2532
|
-
function buildSearchableText(log) {
|
|
2533
|
-
const searchableMessages = log.messages.length <= DEEP_SEARCH_MAX_MESSAGES ? log.messages : [...log.messages.slice(0, DEEP_SEARCH_CROP_SIZE), ...log.messages.slice(-DEEP_SEARCH_CROP_SIZE)];
|
|
2534
|
-
const messageText = searchableMessages.map(extractSearchableText).filter(Boolean).join(" ");
|
|
2535
|
-
const metadata = [log.customTitle, log.summary, log.firstPrompt, log.gitBranch, log.tag, log.prNumber ? `PR #${log.prNumber}` : undefined, log.prRepository].filter(Boolean).join(" ");
|
|
2536
|
-
const fullText = `${metadata} ${messageText}`.trim();
|
|
2537
|
-
return fullText.length > DEEP_SEARCH_MAX_TEXT_LENGTH ? fullText.slice(0, DEEP_SEARCH_MAX_TEXT_LENGTH) : fullText;
|
|
2538
|
-
}
|
|
2539
|
-
function groupLogsBySessionId(filteredLogs) {
|
|
2540
|
-
const groups = new Map;
|
|
2541
|
-
for (const log of filteredLogs) {
|
|
2542
|
-
const sessionId = getSessionIdFromLog(log);
|
|
2543
|
-
if (sessionId) {
|
|
2544
|
-
const existing = groups.get(sessionId);
|
|
2545
|
-
if (existing) {
|
|
2546
|
-
existing.push(log);
|
|
2547
|
-
} else {
|
|
2548
|
-
groups.set(sessionId, [log]);
|
|
2549
|
-
}
|
|
2550
|
-
}
|
|
2551
|
-
}
|
|
2552
|
-
groups.forEach((logs) => logs.sort((a, b) => new Date(b.modified).getTime() - new Date(a.modified).getTime()));
|
|
2553
|
-
return groups;
|
|
2554
|
-
}
|
|
2555
|
-
function getUniqueTags(logs) {
|
|
2556
|
-
const tags = new Set;
|
|
2557
|
-
for (const log of logs) {
|
|
2558
|
-
if (log.tag) {
|
|
2559
|
-
tags.add(log.tag);
|
|
2560
|
-
}
|
|
2561
|
-
}
|
|
2562
|
-
return Array.from(tags).sort((a, b) => a.localeCompare(b));
|
|
2563
|
-
}
|
|
2564
|
-
var import_compiler_runtime3, import_react3, jsx_dev_runtime4, PARENT_PREFIX_WIDTH = 2, CHILD_PREFIX_WIDTH = 4, DEEP_SEARCH_MAX_MESSAGES = 2000, DEEP_SEARCH_CROP_SIZE = 1000, DEEP_SEARCH_MAX_TEXT_LENGTH = 50000, DATE_TIE_THRESHOLD_MS, SNIPPET_CONTEXT_CHARS = 50;
|
|
2565
|
-
var init_LogSelector = __esm(() => {
|
|
2566
|
-
init_source();
|
|
2567
|
-
init_state();
|
|
2568
|
-
init_useExitOnCtrlCDWithKeybindings();
|
|
2569
|
-
init_useSearchInput();
|
|
2570
|
-
init_useTerminalSize();
|
|
2571
|
-
init_colorize();
|
|
2572
|
-
init_ink();
|
|
2573
|
-
init_useKeybinding();
|
|
2574
|
-
init_analytics();
|
|
2575
|
-
init_format();
|
|
2576
|
-
init_getWorktreePaths();
|
|
2577
|
-
init_git();
|
|
2578
|
-
init_log();
|
|
2579
|
-
init_sessionStorage();
|
|
2580
|
-
init_theme();
|
|
2581
|
-
init_ConfigurableShortcutHint();
|
|
2582
|
-
init_select();
|
|
2583
|
-
init_Byline();
|
|
2584
|
-
init_Divider();
|
|
2585
|
-
init_KeyboardShortcutHint();
|
|
2586
|
-
init_SearchBox();
|
|
2587
|
-
init_SessionPreview();
|
|
2588
|
-
init_Spinner();
|
|
2589
|
-
init_TagTabs();
|
|
2590
|
-
init_TextInput();
|
|
2591
|
-
init_TreeSelect();
|
|
2592
|
-
import_compiler_runtime3 = __toESM(require_compiler_runtime(), 1);
|
|
2593
|
-
import_react3 = __toESM(require_react(), 1);
|
|
2594
|
-
jsx_dev_runtime4 = __toESM(require_jsx_dev_runtime(), 1);
|
|
2595
|
-
DATE_TIE_THRESHOLD_MS = 60 * 1000;
|
|
2596
|
-
});
|
|
2597
|
-
|
|
2598
|
-
// src/utils/agenticSessionSearch.ts
|
|
2599
|
-
function extractMessageText(message) {
|
|
2600
|
-
if (message.type !== "user" && message.type !== "assistant") {
|
|
2601
|
-
return "";
|
|
2602
|
-
}
|
|
2603
|
-
const content = "message" in message ? message.message?.content : undefined;
|
|
2604
|
-
if (!content)
|
|
2605
|
-
return "";
|
|
2606
|
-
if (typeof content === "string") {
|
|
2607
|
-
return content;
|
|
2608
|
-
}
|
|
2609
|
-
if (Array.isArray(content)) {
|
|
2610
|
-
return content.map((block) => {
|
|
2611
|
-
if (typeof block === "string")
|
|
2612
|
-
return block;
|
|
2613
|
-
if ("text" in block && typeof block.text === "string")
|
|
2614
|
-
return block.text;
|
|
2615
|
-
return "";
|
|
2616
|
-
}).filter(Boolean).join(" ");
|
|
2617
|
-
}
|
|
2618
|
-
return "";
|
|
2619
|
-
}
|
|
2620
|
-
function extractTranscript(messages) {
|
|
2621
|
-
if (messages.length === 0)
|
|
2622
|
-
return "";
|
|
2623
|
-
const messagesToScan = messages.length <= MAX_MESSAGES_TO_SCAN ? messages : [
|
|
2624
|
-
...messages.slice(0, MAX_MESSAGES_TO_SCAN / 2),
|
|
2625
|
-
...messages.slice(-MAX_MESSAGES_TO_SCAN / 2)
|
|
2626
|
-
];
|
|
2627
|
-
const text = messagesToScan.map(extractMessageText).filter(Boolean).join(" ").replace(/\s+/g, " ").trim();
|
|
2628
|
-
return text.length > MAX_TRANSCRIPT_CHARS ? text.slice(0, MAX_TRANSCRIPT_CHARS) + "\u2026" : text;
|
|
2629
|
-
}
|
|
2630
|
-
function logContainsQuery(log, queryLower) {
|
|
2631
|
-
const title = getLogDisplayTitle(log).toLowerCase();
|
|
2632
|
-
if (title.includes(queryLower))
|
|
2633
|
-
return true;
|
|
2634
|
-
if (log.customTitle?.toLowerCase().includes(queryLower))
|
|
2635
|
-
return true;
|
|
2636
|
-
if (log.tag?.toLowerCase().includes(queryLower))
|
|
2637
|
-
return true;
|
|
2638
|
-
if (log.gitBranch?.toLowerCase().includes(queryLower))
|
|
2639
|
-
return true;
|
|
2640
|
-
if (log.summary?.toLowerCase().includes(queryLower))
|
|
2641
|
-
return true;
|
|
2642
|
-
if (log.firstPrompt?.toLowerCase().includes(queryLower))
|
|
2643
|
-
return true;
|
|
2644
|
-
if (log.messages && log.messages.length > 0) {
|
|
2645
|
-
const transcript = extractTranscript(log.messages).toLowerCase();
|
|
2646
|
-
if (transcript.includes(queryLower))
|
|
2647
|
-
return true;
|
|
2648
|
-
}
|
|
2649
|
-
return false;
|
|
2650
|
-
}
|
|
2651
|
-
async function agenticSessionSearch(query, logs, signal) {
|
|
2652
|
-
if (!query.trim() || logs.length === 0) {
|
|
2653
|
-
return [];
|
|
2654
|
-
}
|
|
2655
|
-
const queryLower = query.toLowerCase();
|
|
2656
|
-
const matchingLogs = logs.filter((log) => logContainsQuery(log, queryLower));
|
|
2657
|
-
let logsToSearch;
|
|
2658
|
-
if (matchingLogs.length >= MAX_SESSIONS_TO_SEARCH) {
|
|
2659
|
-
logsToSearch = matchingLogs.slice(0, MAX_SESSIONS_TO_SEARCH);
|
|
2660
|
-
} else {
|
|
2661
|
-
const nonMatchingLogs = logs.filter((log) => !logContainsQuery(log, queryLower));
|
|
2662
|
-
const remainingSlots = MAX_SESSIONS_TO_SEARCH - matchingLogs.length;
|
|
2663
|
-
logsToSearch = [
|
|
2664
|
-
...matchingLogs,
|
|
2665
|
-
...nonMatchingLogs.slice(0, remainingSlots)
|
|
2666
|
-
];
|
|
2667
|
-
}
|
|
2668
|
-
logForDebugging(`Agentic search: ${logsToSearch.length}/${logs.length} logs, query="${query}", ` + `matching: ${matchingLogs.length}, with messages: ${count(logsToSearch, (l) => l.messages?.length > 0)}`);
|
|
2669
|
-
const logsWithTranscriptsPromises = logsToSearch.map(async (log) => {
|
|
2670
|
-
if (isLiteLog(log)) {
|
|
2671
|
-
try {
|
|
2672
|
-
return await loadFullLog(log);
|
|
2673
|
-
} catch (error) {
|
|
2674
|
-
logError(error);
|
|
2675
|
-
return log;
|
|
2676
|
-
}
|
|
2677
|
-
}
|
|
2678
|
-
return log;
|
|
2679
|
-
});
|
|
2680
|
-
const logsWithTranscripts = await Promise.all(logsWithTranscriptsPromises);
|
|
2681
|
-
logForDebugging(`Agentic search: loaded ${count(logsWithTranscripts, (l) => l.messages?.length > 0)}/${logsToSearch.length} logs with transcripts`);
|
|
2682
|
-
const sessionList = logsWithTranscripts.map((log, index) => {
|
|
2683
|
-
const parts = [`${index}:`];
|
|
2684
|
-
const displayTitle = getLogDisplayTitle(log);
|
|
2685
|
-
parts.push(displayTitle);
|
|
2686
|
-
if (log.customTitle && log.customTitle !== displayTitle) {
|
|
2687
|
-
parts.push(`[custom title: ${log.customTitle}]`);
|
|
2688
|
-
}
|
|
2689
|
-
if (log.tag) {
|
|
2690
|
-
parts.push(`[tag: ${log.tag}]`);
|
|
2691
|
-
}
|
|
2692
|
-
if (log.gitBranch) {
|
|
2693
|
-
parts.push(`[branch: ${log.gitBranch}]`);
|
|
2694
|
-
}
|
|
2695
|
-
if (log.summary) {
|
|
2696
|
-
parts.push(`- Summary: ${log.summary}`);
|
|
2697
|
-
}
|
|
2698
|
-
if (log.firstPrompt && log.firstPrompt !== "No prompt") {
|
|
2699
|
-
parts.push(`- First message: ${log.firstPrompt.slice(0, 300)}`);
|
|
2700
|
-
}
|
|
2701
|
-
if (log.messages && log.messages.length > 0) {
|
|
2702
|
-
const transcript = extractTranscript(log.messages);
|
|
2703
|
-
if (transcript) {
|
|
2704
|
-
parts.push(`- Transcript: ${transcript}`);
|
|
2705
|
-
}
|
|
2706
|
-
}
|
|
2707
|
-
return parts.join(" ");
|
|
2708
|
-
}).join(`
|
|
2709
|
-
`);
|
|
2710
|
-
const userMessage = `Sessions:
|
|
2711
|
-
${sessionList}
|
|
2712
|
-
|
|
2713
|
-
Search query: "${query}"
|
|
2714
|
-
|
|
2715
|
-
Find the sessions that are most relevant to this query.`;
|
|
2716
|
-
logForDebugging(`Agentic search prompt (first 500 chars): ${userMessage.slice(0, 500)}...`);
|
|
2717
|
-
try {
|
|
2718
|
-
const model = getSmallFastModel();
|
|
2719
|
-
logForDebugging(`Agentic search using model: ${model}`);
|
|
2720
|
-
const response = await sideQuery({
|
|
2721
|
-
model,
|
|
2722
|
-
system: SESSION_SEARCH_SYSTEM_PROMPT,
|
|
2723
|
-
messages: [{ role: "user", content: userMessage }],
|
|
2724
|
-
signal,
|
|
2725
|
-
querySource: "session_search"
|
|
2726
|
-
});
|
|
2727
|
-
const textContent = response.content.find((block) => block.type === "text");
|
|
2728
|
-
if (!textContent || textContent.type !== "text") {
|
|
2729
|
-
logForDebugging("No text content in agentic search response");
|
|
2730
|
-
return [];
|
|
2731
|
-
}
|
|
2732
|
-
logForDebugging(`Agentic search response: ${textContent.text}`);
|
|
2733
|
-
const jsonMatch = textContent.text.match(/\{[\s\S]*\}/);
|
|
2734
|
-
if (!jsonMatch) {
|
|
2735
|
-
logForDebugging("Could not find JSON in agentic search response");
|
|
2736
|
-
return [];
|
|
2737
|
-
}
|
|
2738
|
-
const result = jsonParse(jsonMatch[0]);
|
|
2739
|
-
const relevantIndices = result.relevant_indices || [];
|
|
2740
|
-
const relevantLogs = relevantIndices.filter((index) => index >= 0 && index < logsWithTranscripts.length).map((index) => logsWithTranscripts[index]);
|
|
2741
|
-
logForDebugging(`Agentic search found ${relevantLogs.length} relevant sessions`);
|
|
2742
|
-
return relevantLogs;
|
|
2743
|
-
} catch (error) {
|
|
2744
|
-
logError(error);
|
|
2745
|
-
logForDebugging(`Agentic search error: ${error}`);
|
|
2746
|
-
return [];
|
|
2747
|
-
}
|
|
2748
|
-
}
|
|
2749
|
-
var MAX_TRANSCRIPT_CHARS = 2000, MAX_MESSAGES_TO_SCAN = 100, MAX_SESSIONS_TO_SEARCH = 100, SESSION_SEARCH_SYSTEM_PROMPT = `Your goal is to find relevant sessions based on a user's search query.
|
|
2750
|
-
|
|
2751
|
-
You will be given a list of sessions with their metadata and a search query. Identify which sessions are most relevant to the query.
|
|
2752
|
-
|
|
2753
|
-
Each session may include:
|
|
2754
|
-
- Title (display name or custom title)
|
|
2755
|
-
- Tag (user-assigned category, shown as [tag: name] - users tag sessions with /tag command to categorize them)
|
|
2756
|
-
- Branch (git branch name, shown as [branch: name])
|
|
2757
|
-
- Summary (AI-generated summary)
|
|
2758
|
-
- First message (beginning of the conversation)
|
|
2759
|
-
- Transcript (excerpt of conversation content)
|
|
2760
|
-
|
|
2761
|
-
IMPORTANT: Tags are user-assigned labels that indicate the session's topic or category. If the query matches a tag exactly or partially, those sessions should be highly prioritized.
|
|
2762
|
-
|
|
2763
|
-
For each session, consider (in order of priority):
|
|
2764
|
-
1. Exact tag matches (highest priority - user explicitly categorized this session)
|
|
2765
|
-
2. Partial tag matches or tag-related terms
|
|
2766
|
-
3. Title matches (custom titles or first message content)
|
|
2767
|
-
4. Branch name matches
|
|
2768
|
-
5. Summary and transcript content matches
|
|
2769
|
-
6. Semantic similarity and related concepts
|
|
2770
|
-
|
|
2771
|
-
CRITICAL: Be VERY inclusive in your matching. Include sessions that:
|
|
2772
|
-
- Contain the query term anywhere in any field
|
|
2773
|
-
- Are semantically related to the query (e.g., "testing" matches sessions about "tests", "unit tests", "QA", etc.)
|
|
2774
|
-
- Discuss topics that could be related to the query
|
|
2775
|
-
- Have transcripts that mention the concept even in passing
|
|
2776
|
-
|
|
2777
|
-
When in doubt, INCLUDE the session. It's better to return too many results than too few. The user can easily scan through results, but missing relevant sessions is frustrating.
|
|
2778
|
-
|
|
2779
|
-
Return sessions ordered by relevance (most relevant first). If truly no sessions have ANY connection to the query, return an empty array - but this should be rare.
|
|
2780
|
-
|
|
2781
|
-
Respond with ONLY the JSON object, no markdown formatting:
|
|
2782
|
-
{"relevant_indices": [2, 5, 0]}`;
|
|
2783
|
-
var init_agenticSessionSearch = __esm(() => {
|
|
2784
|
-
init_array();
|
|
2785
|
-
init_debug();
|
|
2786
|
-
init_log();
|
|
2787
|
-
init_model();
|
|
2788
|
-
init_sessionStorage();
|
|
2789
|
-
init_sideQuery();
|
|
2790
|
-
init_slowOperations();
|
|
2791
|
-
});
|
|
2792
|
-
|
|
2793
|
-
// src/utils/crossProjectResume.ts
|
|
2794
|
-
import { sep } from "path";
|
|
2795
|
-
function checkCrossProjectResume(log, showAllProjects, worktreePaths) {
|
|
2796
|
-
const currentCwd = getOriginalCwd();
|
|
2797
|
-
if (!showAllProjects || !log.projectPath || log.projectPath === currentCwd) {
|
|
2798
|
-
return { isCrossProject: false };
|
|
2799
|
-
}
|
|
2800
|
-
if (process.env.USER_TYPE !== "ant") {
|
|
2801
|
-
const sessionId2 = getSessionIdFromLog(log);
|
|
2802
|
-
const command2 = `cd ${quote([log.projectPath])} && claude --resume ${sessionId2}`;
|
|
2803
|
-
return {
|
|
2804
|
-
isCrossProject: true,
|
|
2805
|
-
isSameRepoWorktree: false,
|
|
2806
|
-
command: command2,
|
|
2807
|
-
projectPath: log.projectPath
|
|
2808
|
-
};
|
|
2809
|
-
}
|
|
2810
|
-
const isSameRepo = worktreePaths.some((wt) => log.projectPath === wt || log.projectPath.startsWith(wt + sep));
|
|
2811
|
-
if (isSameRepo) {
|
|
2812
|
-
return {
|
|
2813
|
-
isCrossProject: true,
|
|
2814
|
-
isSameRepoWorktree: true,
|
|
2815
|
-
projectPath: log.projectPath
|
|
2816
|
-
};
|
|
2817
|
-
}
|
|
2818
|
-
const sessionId = getSessionIdFromLog(log);
|
|
2819
|
-
const command = `cd ${quote([log.projectPath])} && claude --resume ${sessionId}`;
|
|
2820
|
-
return {
|
|
2821
|
-
isCrossProject: true,
|
|
2822
|
-
isSameRepoWorktree: false,
|
|
2823
|
-
command,
|
|
2824
|
-
projectPath: log.projectPath
|
|
2825
|
-
};
|
|
2826
|
-
}
|
|
2827
|
-
var init_crossProjectResume = __esm(() => {
|
|
2828
|
-
init_state();
|
|
2829
|
-
init_shellQuote();
|
|
2830
|
-
init_sessionStorage();
|
|
2831
|
-
});
|
|
2832
|
-
|
|
2833
|
-
export { LogSelector, init_LogSelector, agenticSessionSearch, init_agenticSessionSearch, checkCrossProjectResume, init_crossProjectResume };
|