@dylanpiercey/work 0.2.19 → 0.2.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (506) hide show
  1. package/README.md +3 -1
  2. package/bin/cli/plan.mjs +85 -0
  3. package/bin/cli/session.mjs +267 -31
  4. package/bin/cli/topic.mjs +63 -40
  5. package/dist/_BHlbSSAl.js +182 -0
  6. package/dist/_C9c_BxRk.js +787 -0
  7. package/dist/_DrEeyoLF.js +2 -0
  8. package/dist/_E0fWorAK.js +2 -0
  9. package/dist/{_CsokArOR.js → _Hb3LeA5Q.js} +218 -58
  10. package/dist/index.mjs +3456 -2299
  11. package/dist/public/assets/_-TUXzZ5j.js +1 -0
  12. package/dist/public/assets/_-TUXzZ5j.js.br +0 -0
  13. package/dist/public/assets/_0BO-2AH8.js +1 -0
  14. package/dist/public/assets/_1MkpPhCv.js +1 -0
  15. package/dist/public/assets/_2Czzn44S.js +2 -0
  16. package/dist/public/assets/_2Czzn44S.js.br +0 -0
  17. package/dist/public/assets/{_B9qGqvit.js → _2M3NjHcy.js} +1 -1
  18. package/dist/public/assets/_3J3NCTfA.js +1 -0
  19. package/dist/public/assets/_3yfaou9w.js +1 -0
  20. package/dist/public/assets/{_DSeQngGR.js → _6fcPfRKt.js} +1 -1
  21. package/dist/public/assets/_6fcPfRKt.js.br +0 -0
  22. package/dist/public/assets/_9kzNcuvf.js +1 -0
  23. package/dist/public/assets/_AbxeWvtk.js +1 -0
  24. package/dist/public/assets/{_D__ojGam.js → _B1AH7m_8.js} +1 -1
  25. package/dist/public/assets/_B1AH7m_8.js.br +0 -0
  26. package/dist/public/assets/{_BAWjkhA8.js → _B2zs9J9f.js} +1 -1
  27. package/dist/public/assets/_B2zs9J9f.js.br +0 -0
  28. package/dist/public/assets/_B4Tl4g-I.js +1 -0
  29. package/dist/public/assets/_B6GPBTnX.js +1 -0
  30. package/dist/public/assets/{_qxffRpjc.js → _B7u83Fqc.js} +1 -1
  31. package/dist/public/assets/_B89z0EK7.js +1 -0
  32. package/dist/public/assets/{_C6Yt6h_R.js → _BCYHTWZd.js} +1 -1
  33. package/dist/public/assets/_BCYHTWZd.js.br +0 -0
  34. package/dist/public/assets/_BD01_px3.js +1 -0
  35. package/dist/public/assets/_BDt0PKxz.js +1 -0
  36. package/dist/public/assets/{_0sTkxfPx.js → _BFD3zDfn.js} +1 -1
  37. package/dist/public/assets/_BFD3zDfn.js.br +0 -0
  38. package/dist/public/assets/{_CBEKHwUV.js → _BH5TfgM7.js} +1 -1
  39. package/dist/public/assets/_BH5TfgM7.js.br +0 -0
  40. package/dist/public/assets/_BHEzkZBl.js +1 -0
  41. package/dist/public/assets/{_CB52LkYt.js → _BHxaJLxf.js} +1 -1
  42. package/dist/public/assets/_BHxaJLxf.js.br +0 -0
  43. package/dist/public/assets/{_D8ac72_O.js → _BJc28pt5.js} +1 -1
  44. package/dist/public/assets/_BJc28pt5.js.br +0 -0
  45. package/dist/public/assets/{_BBCzcNZY.js → _BJpqJK9r.js} +1 -1
  46. package/dist/public/assets/_BJpqJK9r.js.br +0 -0
  47. package/dist/public/assets/_BKSNShOz.js +1 -0
  48. package/dist/public/assets/{_DTNiWZFr.js → _BKcc-iTi.js} +1 -1
  49. package/dist/public/assets/_BKcc-iTi.js.br +0 -0
  50. package/dist/public/assets/{_CG383oZY.js → _BMXIDoUj.js} +1 -1
  51. package/dist/public/assets/_BMXIDoUj.js.br +0 -0
  52. package/dist/public/assets/{_CEC5O89D.js → _BQMwlV-0.js} +1 -1
  53. package/dist/public/assets/_BQMwlV-0.js.br +0 -0
  54. package/dist/public/assets/_BUjgl28E.js +1 -0
  55. package/dist/public/assets/_BYUg95ML.js +1 -0
  56. package/dist/public/assets/{_CspPbDoP.js → _B_LxZatx.js} +1 -1
  57. package/dist/public/assets/_B_LxZatx.js.br +0 -0
  58. package/dist/public/assets/{_CfP0f0PU.js → _BeQUut65.js} +1 -1
  59. package/dist/public/assets/_BeQUut65.js.br +0 -0
  60. package/dist/public/assets/{_DJBR8Qwq.js → _Bf7EsJwj.js} +1 -1
  61. package/dist/public/assets/_Bf7EsJwj.js.br +0 -0
  62. package/dist/public/assets/_BfVmvTXe.js +1 -0
  63. package/dist/public/assets/_BfqDnPV7.js +1 -0
  64. package/dist/public/assets/{_BdSsUhCi.js → _Bfuu6mAX.js} +1 -1
  65. package/dist/public/assets/_Bfuu6mAX.js.br +0 -0
  66. package/dist/public/assets/{_CPaMvBMG.js → _BgBUZElB.js} +1 -1
  67. package/dist/public/assets/_BgBUZElB.js.br +0 -0
  68. package/dist/public/assets/{_CToqok6Q.js → _Bgbj7Vl5.js} +1 -1
  69. package/dist/public/assets/_Bgbj7Vl5.js.br +0 -0
  70. package/dist/public/assets/{_J3wdy6bJ.js → _BhrCWDl2.js} +1 -1
  71. package/dist/public/assets/_BhrCWDl2.js.br +0 -0
  72. package/dist/public/assets/_Bjsevhjr.js +1 -0
  73. package/dist/public/assets/_BjzBYn47.js +1 -0
  74. package/dist/public/assets/_BmyB1F-C.js +1 -0
  75. package/dist/public/assets/{_bDI-pCZR.js → _BpGvpggY.js} +1 -1
  76. package/dist/public/assets/_BpGvpggY.js.br +0 -0
  77. package/dist/public/assets/_BpjknrsF.js +1 -0
  78. package/dist/public/assets/{_BClUYs-k.js → _BpunB-I_.js} +1 -1
  79. package/dist/public/assets/_BpunB-I_.js.br +0 -0
  80. package/dist/public/assets/{_DsehEuMD.js → _Bqgtb-fc.js} +1 -1
  81. package/dist/public/assets/_Bqgtb-fc.js.br +0 -0
  82. package/dist/public/assets/_BtkDWVh9.js +1 -0
  83. package/dist/public/assets/{_zN8SypHW.js → _BvEJgNLp.js} +1 -1
  84. package/dist/public/assets/_BvEJgNLp.js.br +0 -0
  85. package/dist/public/assets/_BvYgAZl3.js +1 -0
  86. package/dist/public/assets/_C0Bfz_Is.js +1 -0
  87. package/dist/public/assets/_C1Aa6bJ9.js +1 -0
  88. package/dist/public/assets/_C3i3LRNx.js +1 -0
  89. package/dist/public/assets/_C4RHKQLq.js +1 -0
  90. package/dist/public/assets/{_DN7pTn2g.js → _C5Wk6L8u.js} +1 -1
  91. package/dist/public/assets/_C5Wk6L8u.js.br +0 -0
  92. package/dist/public/assets/_C7N1s7w_.js +1 -0
  93. package/dist/public/assets/_C7N1s7w_.js.br +0 -0
  94. package/dist/public/assets/_C96lrIeU.js +1 -0
  95. package/dist/public/assets/{_CPj_VL66.js → _CAhkFk0k.js} +1 -1
  96. package/dist/public/assets/_CAhkFk0k.js.br +0 -0
  97. package/dist/public/assets/{_bHL-NcWS.js → _CCmHKlXX.js} +1 -1
  98. package/dist/public/assets/_CCmHKlXX.js.br +0 -0
  99. package/dist/public/assets/{_DpbHp8yR.js → _CEY_n10t.js} +1 -1
  100. package/dist/public/assets/_CEY_n10t.js.br +0 -0
  101. package/dist/public/assets/_CEejNMib.js +1 -0
  102. package/dist/public/assets/_CFo4GZR9.js +1 -0
  103. package/dist/public/assets/{_Cmtl59QM.js → _CGH2Busx.js} +1 -1
  104. package/dist/public/assets/_CGH2Busx.js.br +0 -0
  105. package/dist/public/assets/{_DuyCZnNC.js → _CHwp4prQ.js} +1 -1
  106. package/dist/public/assets/_CHwp4prQ.js.br +0 -0
  107. package/dist/public/assets/{_C_D5TPb7.js → _CN7Wz2eA.js} +1 -1
  108. package/dist/public/assets/_CN7Wz2eA.js.br +0 -0
  109. package/dist/public/assets/_CP58TjsV.js +1 -0
  110. package/dist/public/assets/_CP58TjsV.js.br +0 -0
  111. package/dist/public/assets/_CPruMiA4.js +1 -0
  112. package/dist/public/assets/_CQEZuOE_.js +1 -0
  113. package/dist/public/assets/_CSMoDPwM.js +16 -0
  114. package/dist/public/assets/_CSMoDPwM.js.br +0 -0
  115. package/dist/public/assets/{_briyaWgK.js → _CVEabnQh.js} +1 -1
  116. package/dist/public/assets/_CVEabnQh.js.br +0 -0
  117. package/dist/public/assets/{_J1v2clxU.js → _CWTelCGM.js} +1 -1
  118. package/dist/public/assets/_CWTelCGM.js.br +0 -0
  119. package/dist/public/assets/_CXpplsaj.js +1 -0
  120. package/dist/public/assets/{_BhecGD7y.js → _CY0xLX0Y.js} +1 -1
  121. package/dist/public/assets/_CY0xLX0Y.js.br +0 -0
  122. package/dist/public/assets/{_dVHSDgPC.js → _CZNztOn6.js} +1 -1
  123. package/dist/public/assets/_CZNztOn6.js.br +0 -0
  124. package/dist/public/assets/{_Dtx52FYB.js → _Cabq459u.js} +1 -1
  125. package/dist/public/assets/_Cb593OOX.js +1 -0
  126. package/dist/public/assets/_Cbis2WSl.js +1 -0
  127. package/dist/public/assets/{_T5HFHZgl.js → _CeZa36O-.js} +1 -1
  128. package/dist/public/assets/_CeZa36O-.js.br +0 -0
  129. package/dist/public/assets/{_CCoTlnvb.js → _ChTMXnIu.js} +1 -1
  130. package/dist/public/assets/_ChTMXnIu.js.br +0 -0
  131. package/dist/public/assets/_Cig63HLr.js +1 -0
  132. package/dist/public/assets/_CjkPh72t.js +1 -0
  133. package/dist/public/assets/_Cm6nigjK.js +1 -0
  134. package/dist/public/assets/_CnAEQUMb.js +1 -0
  135. package/dist/public/assets/{_uCKs5N6Q.js → _Coroy2lI.js} +1 -1
  136. package/dist/public/assets/_Coroy2lI.js.br +0 -0
  137. package/dist/public/assets/_CpAeLnqO.js +1 -0
  138. package/dist/public/assets/_CpAeLnqO.js.br +0 -0
  139. package/dist/public/assets/_Cpkby1iI.js +1 -0
  140. package/dist/public/assets/_Cs0Q8LaN.js +1 -0
  141. package/dist/public/assets/_Ct2pbvTU.js +1 -0
  142. package/dist/public/assets/{_DWb03VKf.js → _CtC83UyG.js} +1 -1
  143. package/dist/public/assets/_CtC83UyG.js.br +0 -0
  144. package/dist/public/assets/_CtVSUTWd.js +1 -0
  145. package/dist/public/assets/_Ctf0pL3c.js +1 -0
  146. package/dist/public/assets/_CtvMc-Fn.js +1 -0
  147. package/dist/public/assets/_Cv7TctYK.js +1 -0
  148. package/dist/public/assets/_Cv7TctYK.js.br +0 -0
  149. package/dist/public/assets/{_DmoI4cIl.js → _CvKDzuxc.js} +1 -1
  150. package/dist/public/assets/_CvKDzuxc.js.br +0 -0
  151. package/dist/public/assets/_CvxhsaLv.js +1 -0
  152. package/dist/public/assets/_CwxTh04m.js +1 -0
  153. package/dist/public/assets/_CyMRBJfa.js +1 -0
  154. package/dist/public/assets/{_CdtjIoUd.js → _D-wwbDX7.js} +1 -1
  155. package/dist/public/assets/_D-wwbDX7.js.br +0 -0
  156. package/dist/public/assets/_D02jmNge.js +1 -0
  157. package/dist/public/assets/{_C1RigMYD.js → _D0gWUr-E.js} +1 -1
  158. package/dist/public/assets/_D0gWUr-E.js.br +0 -0
  159. package/dist/public/assets/_D2wtQpHN.js +1 -0
  160. package/dist/public/assets/_D2wtQpHN.js.br +0 -0
  161. package/dist/public/assets/_D3uCXh8z.js +2 -0
  162. package/dist/public/assets/_D3uCXh8z.js.br +0 -0
  163. package/dist/public/assets/_D5GW0gg0.js +1 -0
  164. package/dist/public/assets/_D5GW0gg0.js.br +0 -0
  165. package/dist/public/assets/{_BmpOmFbo.js → _D6YVA8vA.js} +1 -1
  166. package/dist/public/assets/_D6YVA8vA.js.br +0 -0
  167. package/dist/public/assets/_D85prZ-z.js +1 -0
  168. package/dist/public/assets/_D8QlsPTv.js +1 -0
  169. package/dist/public/assets/_D8QlsPTv.js.br +0 -0
  170. package/dist/public/assets/_D8rDqOqJ.js +1 -0
  171. package/dist/public/assets/{_1M3oZPSf.js → _DAcmaIgY.js} +1 -1
  172. package/dist/public/assets/_DAcmaIgY.js.br +0 -0
  173. package/dist/public/assets/_DBlahxfT.js +1 -0
  174. package/dist/public/assets/_DCPGqAo6.js +1 -0
  175. package/dist/public/assets/{_MHZgY1AQ.js → _DDBuDrkA.js} +1 -1
  176. package/dist/public/assets/_DDBuDrkA.js.br +0 -0
  177. package/dist/public/assets/_DDfwtidv.js +1 -0
  178. package/dist/public/assets/_DDfwtidv.js.br +0 -0
  179. package/dist/public/assets/_DEqzNO7a.js +1 -0
  180. package/dist/public/assets/_DEyhBnnd.js +1 -0
  181. package/dist/public/assets/{_DYUFCi44.js → _DG1LpTGX.js} +1 -1
  182. package/dist/public/assets/_DG1LpTGX.js.br +0 -0
  183. package/dist/public/assets/_DJK-MioE.js +1 -0
  184. package/dist/public/assets/{_DDcVFyaQ.js → _DLCgfhNS.js} +1 -1
  185. package/dist/public/assets/_DLCgfhNS.js.br +0 -0
  186. package/dist/public/assets/_DLYvRpNz.js +6 -0
  187. package/dist/public/assets/_DLYvRpNz.js.br +0 -0
  188. package/dist/public/assets/_DPzjUc1B.js +1 -0
  189. package/dist/public/assets/_DRDW7RgT.js +1 -0
  190. package/dist/public/assets/{_CHmEM8Sm.js → _DSoJ6ck3.js} +1 -1
  191. package/dist/public/assets/_DSoJ6ck3.js.br +0 -0
  192. package/dist/public/assets/{_C3fslTAD.js → _DW92UwGh.js} +1 -1
  193. package/dist/public/assets/_DW92UwGh.js.br +0 -0
  194. package/dist/public/assets/{_Bcc0Xs64.js → _DYIjiPYY.js} +1 -1
  195. package/dist/public/assets/_DYIjiPYY.js.br +0 -0
  196. package/dist/public/assets/_DZeeRtLs.js +1 -0
  197. package/dist/public/assets/{_XsB9KmcW.js → _DZzucnmx.js} +1 -1
  198. package/dist/public/assets/_DZzucnmx.js.br +0 -0
  199. package/dist/public/assets/{_EcMqP1xI.js → _D_AjKzkm.js} +1 -1
  200. package/dist/public/assets/_D_AjKzkm.js.br +0 -0
  201. package/dist/public/assets/{_DYhs8iJg.js → _DdVG8Rbg.js} +116 -116
  202. package/dist/public/assets/_DdVG8Rbg.js.br +0 -0
  203. package/dist/public/assets/{_BH9BIky6.js → _DdcPtDZz.js} +1 -1
  204. package/dist/public/assets/_DdcPtDZz.js.br +0 -0
  205. package/dist/public/assets/{_-7Amnss4.js → _De_msLFQ.js} +1 -1
  206. package/dist/public/assets/_De_msLFQ.js.br +0 -0
  207. package/dist/public/assets/_DeiCZJcm.js +1 -0
  208. package/dist/public/assets/_DeiCZJcm.js.br +0 -0
  209. package/dist/public/assets/{_CL8DzBla.js → _DfNM5GDo.js} +1 -1
  210. package/dist/public/assets/_DfNM5GDo.js.br +0 -0
  211. package/dist/public/assets/{_C7Y4xApK.js → _Dg6OsRrR.js} +1 -1
  212. package/dist/public/assets/_Dg6OsRrR.js.br +0 -0
  213. package/dist/public/assets/_DgrmX7cI.js +1 -0
  214. package/dist/public/assets/_DiPK_ps-.js +1 -0
  215. package/dist/public/assets/{_DbT6uo7W.js → _Dow17jzJ.js} +1 -1
  216. package/dist/public/assets/_Dow17jzJ.js.br +0 -0
  217. package/dist/public/assets/{_BtedGrGs.js → _DpSZYTyI.js} +1 -1
  218. package/dist/public/assets/_DpSZYTyI.js.br +0 -0
  219. package/dist/public/assets/_DpXO9fPK.js +1 -0
  220. package/dist/public/assets/_DpXO9fPK.js.br +0 -0
  221. package/dist/public/assets/{_DzNFlI0M.js → _DqiBcDpF.js} +1 -1
  222. package/dist/public/assets/_DqiBcDpF.js.br +0 -0
  223. package/dist/public/assets/_DqkJjiCU.js +1 -0
  224. package/dist/public/assets/{_ahCaQNeo.js → _Draa__tn.js} +1 -1
  225. package/dist/public/assets/_Draa__tn.js.br +0 -0
  226. package/dist/public/assets/_Drs3T7dh.js +1 -0
  227. package/dist/public/assets/_Drs3T7dh.js.br +0 -0
  228. package/dist/public/assets/_DtBGe4AJ.js +1 -0
  229. package/dist/public/assets/{_Dw1P6xZJ.js → _DxSnjCPi.js} +1 -1
  230. package/dist/public/assets/_DxSnjCPi.js.br +0 -0
  231. package/dist/public/assets/{_B9I2AEux.js → _DyEhTpVE.js} +1 -1
  232. package/dist/public/assets/_DyEhTpVE.js.br +0 -0
  233. package/dist/public/assets/{_D3IviZbJ.js → _DyFcXAXE.js} +1 -1
  234. package/dist/public/assets/_DyFcXAXE.js.br +0 -0
  235. package/dist/public/assets/_FPItrlZz.js +1 -0
  236. package/dist/public/assets/{_UZAFx6D8.js → _HGP7qpI4.js} +1 -1
  237. package/dist/public/assets/_HGP7qpI4.js.br +0 -0
  238. package/dist/public/assets/{_DCrPsldZ.js → _L-b7Vsug.js} +1 -1
  239. package/dist/public/assets/_L-b7Vsug.js.br +0 -0
  240. package/dist/public/assets/{_Cl7LTITm.js → _LWpc-K1g.js} +1 -1
  241. package/dist/public/assets/_LWpc-K1g.js.br +0 -0
  242. package/dist/public/assets/{_C-DhXiEm.js → _MwkLbzHQ.js} +1 -1
  243. package/dist/public/assets/_MwkLbzHQ.js.br +0 -0
  244. package/dist/public/assets/_O4DIriLZ.js +1 -0
  245. package/dist/public/assets/{_YoXk_8Bl.js → _T0Ktx7Km.js} +1 -1
  246. package/dist/public/assets/_T0Ktx7Km.js.br +0 -0
  247. package/dist/public/assets/_T6O8KX0b.js +1 -0
  248. package/dist/public/assets/_TWZgGi12.js +1 -0
  249. package/dist/public/assets/{_C-BYkx5h.js → _UBgRR4E9.js} +1 -1
  250. package/dist/public/assets/_UBgRR4E9.js.br +0 -0
  251. package/dist/public/assets/_X3T0JcUM.js +87 -0
  252. package/dist/public/assets/_X3T0JcUM.js.br +0 -0
  253. package/dist/public/assets/_YtP2gTmD.js +1 -0
  254. package/dist/public/assets/{_BQW1kIop.js → __1UtPhZb.js} +1 -1
  255. package/dist/public/assets/__1UtPhZb.js.br +0 -0
  256. package/dist/public/assets/__WDcLOp3.js +1 -0
  257. package/dist/public/assets/{_CIfCdAzS.js → __cyNMcUU.js} +1 -1
  258. package/dist/public/assets/{_BPDSQUbl.js → _csFWQzWs.js} +1 -1
  259. package/dist/public/assets/_csFWQzWs.js.br +0 -0
  260. package/dist/public/assets/_eURsGF_D.js +1 -0
  261. package/dist/public/assets/_fEPizk9T.js +1 -0
  262. package/dist/public/assets/{_B9xuaMHt.js → _hC5RUmrf.js} +1 -1
  263. package/dist/public/assets/_hC5RUmrf.js.br +0 -0
  264. package/dist/public/assets/_hfgYVPfe.js +1 -0
  265. package/dist/public/assets/_i51v5tw8.js +1 -0
  266. package/dist/public/assets/{_CuglAToi.js → _k1uZxEJ-.js} +1 -1
  267. package/dist/public/assets/_k1uZxEJ-.js.br +0 -0
  268. package/dist/public/assets/_l4nNKr9o.js +1 -0
  269. package/dist/public/assets/{_D7qWWxdI.js → _lA6BOkV1.js} +1 -1
  270. package/dist/public/assets/_lA6BOkV1.js.br +0 -0
  271. package/dist/public/assets/_qyrPXpIj.js +1 -0
  272. package/dist/public/assets/{_Bt03HU8S.js → _sLUOjXIk.js} +1 -1
  273. package/dist/public/assets/{_G1BLeMns.js → _sjeWoc5X.js} +1 -1
  274. package/dist/public/assets/_sjeWoc5X.js.br +0 -0
  275. package/dist/public/assets/_tByKwKUc.js +1 -0
  276. package/dist/public/assets/{_G8KNSVdM.js → _tFVcmmKI.js} +1 -1
  277. package/dist/public/assets/_tFVcmmKI.js.br +0 -0
  278. package/dist/public/assets/{_Ctjz3BD9.js → _txvO7pXr.js} +1 -1
  279. package/dist/public/assets/_txvO7pXr.js.br +0 -0
  280. package/dist/public/assets/_um7Vy7NX.js +1 -0
  281. package/dist/public/assets/_veNUvOqP.js +1 -0
  282. package/dist/public/assets/{_DSCqWPO0.js → _w8hTnp0H.js} +1 -1
  283. package/dist/public/assets/_w8hTnp0H.js.br +0 -0
  284. package/dist/public/assets/_wGWNa6Sp.js +1 -0
  285. package/dist/public/assets/_wxbEv1JK.js +1 -0
  286. package/dist/public/assets/files-view-BOE5HTrF.js +2 -0
  287. package/dist/public/assets/manage-workspace-ClwsrQ4a.js +2 -0
  288. package/dist/public/assets/new-CJ6ZElay.js +1 -0
  289. package/dist/public/assets/new-workspace-DWSBO4Vx.js +2 -0
  290. package/dist/public/assets/review-view-DffAZHOz.js +2 -0
  291. package/dist/public/assets/settings-CJ6ZElay.js +1 -0
  292. package/dist/public/assets/settings-page-CYL_T3Vf.js +2 -0
  293. package/dist/public/assets/styles-taHUfRpm.css +1 -0
  294. package/dist/public/assets/styles-taHUfRpm.css.br +0 -0
  295. package/dist/public/assets/w-CJ6ZElay.js +1 -0
  296. package/dist/public/assets/w._-CJ6ZElay.js +1 -0
  297. package/dist/public/assets/w._-ChCIRlhY.js +1 -0
  298. package/dist/public/assets/w._-WsR2-skZ.js +1 -0
  299. package/package.json +1 -1
  300. package/dist/_L2HNAA_8.js +0 -2
  301. package/dist/__TCdgPY5.js +0 -173
  302. package/dist/public/assets/_-7Amnss4.js.br +0 -0
  303. package/dist/public/assets/_0XXNUttq.js +0 -1
  304. package/dist/public/assets/_0sTkxfPx.js.br +0 -0
  305. package/dist/public/assets/_0zzYbK0A.js +0 -1
  306. package/dist/public/assets/_1M3oZPSf.js.br +0 -0
  307. package/dist/public/assets/_2O5HnHht.js +0 -1
  308. package/dist/public/assets/_7WlUaJPH.js +0 -1
  309. package/dist/public/assets/_8Tr7ByPg.js +0 -1
  310. package/dist/public/assets/_9AXMmQSO.js +0 -1
  311. package/dist/public/assets/_B1VqbV-X.js +0 -1
  312. package/dist/public/assets/_B9I2AEux.js.br +0 -0
  313. package/dist/public/assets/_B9xuaMHt.js.br +0 -0
  314. package/dist/public/assets/_BAWjkhA8.js.br +0 -0
  315. package/dist/public/assets/_BBCzcNZY.js.br +0 -0
  316. package/dist/public/assets/_BBW2szHh.js +0 -1
  317. package/dist/public/assets/_BCP2Njnu.js +0 -1
  318. package/dist/public/assets/_BClUYs-k.js.br +0 -0
  319. package/dist/public/assets/_BDdZkZRc.js +0 -1
  320. package/dist/public/assets/_BDdZkZRc.js.br +0 -0
  321. package/dist/public/assets/_BEDmGSgS.js +0 -1
  322. package/dist/public/assets/_BEDmGSgS.js.br +0 -0
  323. package/dist/public/assets/_BH9BIky6.js.br +0 -0
  324. package/dist/public/assets/_BLdi8Ee5.js +0 -1
  325. package/dist/public/assets/_BPDSQUbl.js.br +0 -0
  326. package/dist/public/assets/_BQW1kIop.js.br +0 -0
  327. package/dist/public/assets/_BQeoUfFw.js +0 -1
  328. package/dist/public/assets/_BRzroLbh.js +0 -1
  329. package/dist/public/assets/_BSXsTYSe.js +0 -1
  330. package/dist/public/assets/_BTXDT3Na.js +0 -1
  331. package/dist/public/assets/_BXm4xeFI.js +0 -1
  332. package/dist/public/assets/_BY8UeogK.js +0 -1
  333. package/dist/public/assets/_BYpyhp64.js +0 -1
  334. package/dist/public/assets/_BYpyhp64.js.br +0 -0
  335. package/dist/public/assets/_B_Kz7LnY.js +0 -1
  336. package/dist/public/assets/_Bcc0Xs64.js.br +0 -0
  337. package/dist/public/assets/_BdSsUhCi.js.br +0 -0
  338. package/dist/public/assets/_BdaWssEH.js +0 -1
  339. package/dist/public/assets/_BhecGD7y.js.br +0 -0
  340. package/dist/public/assets/_Bj9dpPhN.js +0 -1
  341. package/dist/public/assets/_BjZqS7za.js +0 -1
  342. package/dist/public/assets/_BjZqS7za.js.br +0 -0
  343. package/dist/public/assets/_BkSUiyHK.js +0 -1
  344. package/dist/public/assets/_BlshXH2Y.js +0 -16
  345. package/dist/public/assets/_BlshXH2Y.js.br +0 -0
  346. package/dist/public/assets/_BmX-VP7w.js +0 -1
  347. package/dist/public/assets/_BmpOmFbo.js.br +0 -0
  348. package/dist/public/assets/_Bo6YntUl.js +0 -1
  349. package/dist/public/assets/_BprZx4vg.js +0 -2
  350. package/dist/public/assets/_BprZx4vg.js.br +0 -0
  351. package/dist/public/assets/_Bqm7OnIV.js +0 -1
  352. package/dist/public/assets/_BquBGUNK.js +0 -1
  353. package/dist/public/assets/_BquBGUNK.js.br +0 -0
  354. package/dist/public/assets/_BrB66aRZ.js +0 -1
  355. package/dist/public/assets/_BtedGrGs.js.br +0 -0
  356. package/dist/public/assets/_C-BYkx5h.js.br +0 -0
  357. package/dist/public/assets/_C-DhXiEm.js.br +0 -0
  358. package/dist/public/assets/_C-NBFnST.js +0 -1
  359. package/dist/public/assets/_C1RigMYD.js.br +0 -0
  360. package/dist/public/assets/_C2vRS-ES.js +0 -1
  361. package/dist/public/assets/_C3fslTAD.js.br +0 -0
  362. package/dist/public/assets/_C4EYjWGn.js +0 -1
  363. package/dist/public/assets/_C4EYjWGn.js.br +0 -0
  364. package/dist/public/assets/_C6Yt6h_R.js.br +0 -0
  365. package/dist/public/assets/_C7Y4xApK.js.br +0 -0
  366. package/dist/public/assets/_CB52LkYt.js.br +0 -0
  367. package/dist/public/assets/_CBEKHwUV.js.br +0 -0
  368. package/dist/public/assets/_CBSLBYQF.js +0 -1
  369. package/dist/public/assets/_CBgzBB_k.js +0 -1
  370. package/dist/public/assets/_CBgzBB_k.js.br +0 -0
  371. package/dist/public/assets/_CCoTlnvb.js.br +0 -0
  372. package/dist/public/assets/_CD26To-f.js +0 -1
  373. package/dist/public/assets/_CDyWgQ0v.js +0 -6
  374. package/dist/public/assets/_CDyWgQ0v.js.br +0 -0
  375. package/dist/public/assets/_CEC5O89D.js.br +0 -0
  376. package/dist/public/assets/_CF2kEAU7.js +0 -1
  377. package/dist/public/assets/_CFURqbmO.js +0 -1
  378. package/dist/public/assets/_CG383oZY.js.br +0 -0
  379. package/dist/public/assets/_CHNJosg3.js +0 -1
  380. package/dist/public/assets/_CHmEM8Sm.js.br +0 -0
  381. package/dist/public/assets/_CKyzH0fl.js +0 -1
  382. package/dist/public/assets/_CL8DzBla.js.br +0 -0
  383. package/dist/public/assets/_CNYS94C5.js +0 -1
  384. package/dist/public/assets/_CNhypHJN.js +0 -1
  385. package/dist/public/assets/_CO-FkxlA.js +0 -1
  386. package/dist/public/assets/_COiGBSpO.js +0 -1
  387. package/dist/public/assets/_COvolvRQ.js +0 -1
  388. package/dist/public/assets/_CPaMvBMG.js.br +0 -0
  389. package/dist/public/assets/_CPj_VL66.js.br +0 -0
  390. package/dist/public/assets/_CQJC8Vx4.js +0 -1
  391. package/dist/public/assets/_CRHNlzBC.js +0 -1
  392. package/dist/public/assets/_CToqok6Q.js.br +0 -0
  393. package/dist/public/assets/_CUFKkl0B.js +0 -1
  394. package/dist/public/assets/_CZsOUa-q.js +0 -1
  395. package/dist/public/assets/_C_D5TPb7.js.br +0 -0
  396. package/dist/public/assets/_CdHI48v6.js +0 -1
  397. package/dist/public/assets/_CdpmkkzR.js +0 -1
  398. package/dist/public/assets/_CdpmkkzR.js.br +0 -0
  399. package/dist/public/assets/_CdtjIoUd.js.br +0 -0
  400. package/dist/public/assets/_Ce9Tv01m.js +0 -1
  401. package/dist/public/assets/_CeC7Lv10.js +0 -1
  402. package/dist/public/assets/_CfP0f0PU.js.br +0 -0
  403. package/dist/public/assets/_Cg7DH3xk.js +0 -1
  404. package/dist/public/assets/_Cg7DH3xk.js.br +0 -0
  405. package/dist/public/assets/_CikNq0z8.js +0 -1
  406. package/dist/public/assets/_Cl7LTITm.js.br +0 -0
  407. package/dist/public/assets/_Cmtl59QM.js.br +0 -0
  408. package/dist/public/assets/_CshYq_Dp.js +0 -1
  409. package/dist/public/assets/_CspPbDoP.js.br +0 -0
  410. package/dist/public/assets/_Ctjz3BD9.js.br +0 -0
  411. package/dist/public/assets/_CuglAToi.js.br +0 -0
  412. package/dist/public/assets/_CwSoAVRN.js +0 -1
  413. package/dist/public/assets/_D0XQV-Hm.js +0 -1
  414. package/dist/public/assets/_D36PnqCD.js +0 -1
  415. package/dist/public/assets/_D36PnqCD.js.br +0 -0
  416. package/dist/public/assets/_D3IviZbJ.js.br +0 -0
  417. package/dist/public/assets/_D6rgUB9O.js +0 -1
  418. package/dist/public/assets/_D7qWWxdI.js.br +0 -0
  419. package/dist/public/assets/_D8ac72_O.js.br +0 -0
  420. package/dist/public/assets/_D9WWxrQR.js +0 -1
  421. package/dist/public/assets/_D9hI5dSA.js +0 -1
  422. package/dist/public/assets/_DCrPsldZ.js.br +0 -0
  423. package/dist/public/assets/_DDcVFyaQ.js.br +0 -0
  424. package/dist/public/assets/_DDhkKo8Q.js +0 -1
  425. package/dist/public/assets/_DJBR8Qwq.js.br +0 -0
  426. package/dist/public/assets/_DLpa6VYT.js +0 -1
  427. package/dist/public/assets/_DMqe6rR-.js +0 -1
  428. package/dist/public/assets/_DN7pTn2g.js.br +0 -0
  429. package/dist/public/assets/_DP8UuFuJ.js +0 -1
  430. package/dist/public/assets/_DQedUaqM.js +0 -1
  431. package/dist/public/assets/_DSCqWPO0.js.br +0 -0
  432. package/dist/public/assets/_DSeQngGR.js.br +0 -0
  433. package/dist/public/assets/_DTNiWZFr.js.br +0 -0
  434. package/dist/public/assets/_DThlusXY.js +0 -1
  435. package/dist/public/assets/_DUK16H19.js +0 -1
  436. package/dist/public/assets/_DUZ13t3U.js +0 -1
  437. package/dist/public/assets/_DWb03VKf.js.br +0 -0
  438. package/dist/public/assets/_DWsyhfgn.js +0 -1
  439. package/dist/public/assets/_DXuzYhW6.js +0 -1
  440. package/dist/public/assets/_DXyOzA2b.js +0 -1
  441. package/dist/public/assets/_DYUFCi44.js.br +0 -0
  442. package/dist/public/assets/_DYhs8iJg.js.br +0 -0
  443. package/dist/public/assets/_D__ojGam.js.br +0 -0
  444. package/dist/public/assets/_DaFI_W5D.js +0 -1
  445. package/dist/public/assets/_DbT6uo7W.js.br +0 -0
  446. package/dist/public/assets/_DhnT0cCE.js +0 -1
  447. package/dist/public/assets/_Dm9OGn2q.js +0 -1
  448. package/dist/public/assets/_DmkeGFoM.js +0 -1
  449. package/dist/public/assets/_DmoI4cIl.js.br +0 -0
  450. package/dist/public/assets/_DpbHp8yR.js.br +0 -0
  451. package/dist/public/assets/_Dqz_HBE1.js +0 -1
  452. package/dist/public/assets/_DsehEuMD.js.br +0 -0
  453. package/dist/public/assets/_DuEyirL6.js +0 -1
  454. package/dist/public/assets/_DuuloSIi.js +0 -1
  455. package/dist/public/assets/_DuyCZnNC.js.br +0 -0
  456. package/dist/public/assets/_Dw1P6xZJ.js.br +0 -0
  457. package/dist/public/assets/_DzNFlI0M.js.br +0 -0
  458. package/dist/public/assets/_EcMqP1xI.js.br +0 -0
  459. package/dist/public/assets/_G1BLeMns.js.br +0 -0
  460. package/dist/public/assets/_G8KNSVdM.js.br +0 -0
  461. package/dist/public/assets/_J1v2clxU.js.br +0 -0
  462. package/dist/public/assets/_J3wdy6bJ.js.br +0 -0
  463. package/dist/public/assets/_MHZgY1AQ.js.br +0 -0
  464. package/dist/public/assets/_NHTZitq1.js +0 -2
  465. package/dist/public/assets/_NHTZitq1.js.br +0 -0
  466. package/dist/public/assets/_PsuNqRL9.js +0 -86
  467. package/dist/public/assets/_PsuNqRL9.js.br +0 -0
  468. package/dist/public/assets/_T5HFHZgl.js.br +0 -0
  469. package/dist/public/assets/_UZAFx6D8.js.br +0 -0
  470. package/dist/public/assets/_XA8_RQXF.js +0 -1
  471. package/dist/public/assets/_XsB9KmcW.js.br +0 -0
  472. package/dist/public/assets/_YoXk_8Bl.js.br +0 -0
  473. package/dist/public/assets/_YubCdy3Z.js +0 -1
  474. package/dist/public/assets/_ahCaQNeo.js.br +0 -0
  475. package/dist/public/assets/_bDI-pCZR.js.br +0 -0
  476. package/dist/public/assets/_bHL-NcWS.js.br +0 -0
  477. package/dist/public/assets/_bqRzDYc8.js +0 -1
  478. package/dist/public/assets/_briyaWgK.js.br +0 -0
  479. package/dist/public/assets/_dVHSDgPC.js.br +0 -0
  480. package/dist/public/assets/_gkZjZ9I4.js +0 -1
  481. package/dist/public/assets/_plyCYAnN.js +0 -1
  482. package/dist/public/assets/_q0Z44mWJ.js +0 -1
  483. package/dist/public/assets/_q0Z44mWJ.js.br +0 -0
  484. package/dist/public/assets/_qAsGEOt5.js +0 -1
  485. package/dist/public/assets/_qAsGEOt5.js.br +0 -0
  486. package/dist/public/assets/_uCKs5N6Q.js.br +0 -0
  487. package/dist/public/assets/_utWnC80Q.js +0 -1
  488. package/dist/public/assets/_utvzcBHT.js +0 -1
  489. package/dist/public/assets/_v8WbCPI8.js +0 -1
  490. package/dist/public/assets/_yK4b_Bl5.js +0 -1
  491. package/dist/public/assets/_yoQW4BY5.js +0 -1
  492. package/dist/public/assets/_zB6USXHX.js +0 -1
  493. package/dist/public/assets/_zN8SypHW.js.br +0 -0
  494. package/dist/public/assets/files-view-Fl0rU3Ns.js +0 -2
  495. package/dist/public/assets/manage-workspace-DggRcsXf.js +0 -2
  496. package/dist/public/assets/new-C7NxTJAT.js +0 -1
  497. package/dist/public/assets/new-workspace-C0pw5Iz1.js +0 -2
  498. package/dist/public/assets/review-view-C4YQ0J-X.js +0 -2
  499. package/dist/public/assets/settings-C7NxTJAT.js +0 -1
  500. package/dist/public/assets/settings-page-Cl_1tWCv.js +0 -2
  501. package/dist/public/assets/styles-Vcsj4CA7.css +0 -1
  502. package/dist/public/assets/styles-Vcsj4CA7.css.br +0 -0
  503. package/dist/public/assets/w-C7NxTJAT.js +0 -1
  504. package/dist/public/assets/w._-BbFH2lR-.js +0 -1
  505. package/dist/public/assets/w._-C7NxTJAT.js +0 -1
  506. package/dist/public/assets/w._-YIzLOiyZ.js +0 -1
@@ -0,0 +1,16 @@
1
+ import{$ as e,$t as t,A as n,At as r,B as i,Bt as a,C as o,Ct as s,D as c,Dt as l,E as u,Et as d,F as f,Ft as p,G as m,Gt as h,H as ee,Ht as te,I as g,It as ne,J as re,Jt as _,K as ie,Kt as ae,L as v,Lt as y,M as oe,Mt as se,N as ce,Nt as le,O as ue,P as de,Pt as fe,Q as pe,Qt as me,R as b,Rt as x,S as he,St as ge,T as _e,Tt as ve,U as ye,Ut as be,V as xe,Vt as Se,W as Ce,Wt as S,X as we,Xt as Te,Y as Ee,Yt as De,Z as Oe,Zt as ke,_ as Ae,_t as je,a as Me,at as Ne,b as Pe,bt as Fe,c as Ie,ct as Le,d as Re,dt as ze,en as Be,et as Ve,f as He,ft as Ue,g as We,gt as Ge,h as Ke,ht as qe,i as Je,it as C,j as Ye,jt as Xe,k as Ze,kt as Qe,l as $e,lt as et,m as tt,mt as w,n as nt,nt as rt,o as it,ot as at,p as ot,pt as st,q as ct,qt as lt,r as ut,rt as dt,s as ft,st as pt,t as mt,tn as ht,tt as gt,u as _t,ut as vt,v as yt,vt as bt,w as xt,wt as St,x as Ct,xt as wt,y as Tt,yt as Et,z as Dt}from"./_DdVG8Rbg.js";import{Et as T,It as Ot,Pt as kt,R as At,Tt as jt,_ as Mt,g as Nt,h as Pt,m as Ft,p as It,wt as E,z as Lt,zt as Rt}from"./_DDfwtidv.js";import{A as zt,B as Bt,D as Vt,G as D,H as O,I as k,J as Ht,K as A,L as j,N as Ut,O as M,R as N,S as Wt,U as P,V as F,W as Gt,X as Kt,a as I,b as L,f as qt,i as R,j as Jt,n as Yt,p as Xt,q as Zt,r as Qt,v as $t,w as en,x as z,y as B,z as tn}from"./_Draa__tn.js";import{$n as nn,$t as rn,A as an,An as on,Bn as sn,Bt as cn,C as ln,Ct as un,D as dn,E as fn,Et as pn,Gt as mn,H as hn,Hn as gn,Ht as _n,J as vn,L as yn,Lt as bn,Mt as xn,O as Sn,Qn as Cn,Rn as wn,S as Tn,T as En,Un as Dn,Ut as On,Vn as kn,Vt as An,Wt as jn,Y as Mn,_ as Nn,a as Pn,an as Fn,b as In,bt as Ln,c as Rn,cn as zn,d as Bn,dn as Vn,et as Hn,f as Un,g as Wn,h as Gn,i as Kn,j as qn,jt as Jn,k as Yn,l as Xn,m as Zn,n as Qn,o as $n,on as er,p as tr,q as nr,r as rr,s as ir,sn as ar,t as or,tn as sr,tt as cr,u as lr,un as ur,v as dr,w as fr,wn as pr,wt as mr,x as hr,xt as gr,y as _r,zn as vr,zt as yr}from"./_D3uCXh8z.js";import{A as br,C as xr,H as Sr,I as Cr,K as wr,M as Tr,N as Er,P as Dr,R as Or,U as kr,V as Ar,_ as jr,b as Mr,c as Nr,d as Pr,f as Fr,g as Ir,h as Lr,j as Rr,l as zr,m as Br,o as Vr,ot as Hr,p as Ur,s as Wr,u as Gr,v as Kr,y as qr}from"./_DeiCZJcm.js";import{r as Jr}from"./_DSoJ6ck3.js";import{B as Yr,C as Xr,R as Zr,S as Qr,T as $r,U as V,V as ei,W as ti,X as ni,w as ri,x as ii}from"./_DdcPtDZz.js";import{a as ai,i as oi,n as si,r as ci,t as li}from"./_9kzNcuvf.js";import{t as ui}from"./_D2pdXUO3.js";import{a as di,c as fi,d as pi,f as mi,i as hi,l as gi,n as _i,o as vi,p as yi,r as bi,s as xi,t as Si,u as Ci}from"./_CP58TjsV.js";import{a as wi,c as Ti,l as Ei,n as Di,r as Oi,s as H,t as ki}from"./_DxSnjCPi.js";import{a as Ai,i as ji,n as Mi,r as Ni,t as Pi}from"./_C4RHKQLq.js";var Fi=2e4;function Ii(){return{byKey:new Map,answered:new Map,flight:new Map,later:new Map,epoch:0,repos:null,ctl:null,timer:0,retry:0,hosts:new Map}}function Li(e,t,n,r){let i=[];for(let r of n){let n=t.get(r);(e.byKey.get(r)?.length??0)!==(n?.length??0)&&i.push(r),n?e.byKey.set(r,n):e.byKey.delete(r)}let a=new Set(n);for(let[t,n]of e.hosts)a.has(n)&&h(t,e.byKey.get(n)??[],`additions`);for(let e of i)r.redraw(e)}function Ri(e,t){e.timer||=setTimeout(()=>{if(e.timer=0,!t.live())return;if(!rn()){e.ctl?.abort(),e.ctl=null,e.flight.clear(),e.answered.clear(),Li(e,new Map,[...e.byKey.keys()],t);return}let n=new Set(t.onScreen()),r=new Map,i=[...t.shown()].sort((e,t)=>+n.has(t.key)-n.has(e.key));for(let e of i){if(e.binary||!e.patch||e.status===`D`)continue;let n=t.source(e.key);n&&r.set(e.key,{file:n,patch:e.patch,sig:`${n.rev}:${e.hash??e.patch.length}`})}let a=[...e.byKey.keys()].filter(e=>!r.has(e));a.length&&Li(e,new Map,a,t);for(let t of e.answered.keys())r.has(t)||e.answered.delete(t);[...e.flight].some(([e,t])=>r.get(e)?.sig!==t)&&(e.ctl?.abort(),e.ctl=null,e.flight.clear());let o=Date.now(),s=1/0,c=[];for(let[t,i]of r){if(e.flight.has(t))continue;let r=e.later.get(t)??0;if(r>o){s=Math.min(s,r);continue}let a=e.answered.get(t);a?.sig===i.sig&&(a.epoch>=e.epoch||!n.has(t))||c.push(t)}if(e.retry&&clearTimeout(e.retry),e.retry=0,s<1/0&&(e.retry=setTimeout(()=>{e.retry=0,Ri(e,t)},s-o)),!c.length)return;let l=e.ctl??=new AbortController,u=e.epoch;for(let t of c)e.flight.set(t,r.get(t).sig);let d=new Map(c.map(e=>[ae(r.get(e).file),e]));be(t.workspaceId(),c.map(e=>r.get(e).file),(n,i)=>{let a=new Map,o=[];for(let[t,i]of n){let n=d.get(t),s=n&&r.get(n);if(!n||!s||e.flight.get(n)!==s.sig)continue;e.flight.delete(n),e.later.delete(n),e.answered.set(n,{sig:s.sig,epoch:u});let c=te(s.patch),l=i.filter(e=>c.has(e.line));l.length&&a.set(n,l),o.push(n)}for(let t of i){let n=d.get(t);n&&e.flight.get(n)===r.get(n)?.sig&&(e.flight.delete(n),e.later.set(n,Date.now()+Fi))}o.length&&Li(e,a,o,t),i.length&&Ri(e,t)},l.signal).finally(()=>{e.ctl===l&&!e.flight.size&&(e.ctl=null)})},1e3)}function zi(e,t){e.answered.clear(),e.later.clear(),Ri(e,t)}function Bi(e,t){t&&t!==e.repos&&(e.repos=t,e.epoch++)}function Vi(e,t,n){e.hosts.set(t,n),h(t,e.byKey.get(n)??[],`additions`)}function Hi(e,t){e.hosts.delete(t),S(t)}function Ui(e){e.timer&&clearTimeout(e.timer),e.retry&&clearTimeout(e.retry),e.ctl?.abort();for(let t of e.hosts.keys())S(t);e.hosts.clear()}function Wi(e){let t=e.filter(e=>!e.headRef);return t.filter(e=>e.pr||!t.some(t=>t.pr&&t.worktree===e.worktree)).map(e=>{let t=e.pr?String(e.pr.number):`-`,n=e.pr&&(e.pr.headRefOid||e.head)||``,r=e.localHead||e.head||``;return`${e.worktree}#${t}:${n}:L${r}`}).sort().join(`\0`)}function Gi(e){return e.repos.flatMap(e=>{let t=e.localHead||``,n=e.prs.filter(e=>e.state===`OPEN`||e.state===void 0);return n.length?n.map(n=>`${e.worktree}#${n.number}:${n.headRefOid||``}:L${t}`):[`${e.worktree}#-::L${t}`]}).sort().join(`\0`)}var Ki=new WeakMap,qi=()=>new Map;function Ji(e,t){for(let n of e.keys())t.has(n)||e.delete(n)}function Yi(e,t,n){if(Ki.has(e))return Ki.get(e);let r=e.patch?n.get(t):void 0;if(r&&r.patch===e.patch)return r.patch=e.patch,Ki.set(e,r.meta),r.meta;let i=null;if(e.patch)try{i=ht(e.patch,`${t}#${Xi(e.patch)}`)[0]?.files[0]??null}catch{i=null}return Ki.set(e,i),e.patch&&n.set(t,{patch:e.patch,meta:i}),i}function Xi(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return`${(t>>>0).toString(36)}${e.length.toString(36)}`}var Zi=new WeakMap;function Qi(e,t){let n=Zi.get(e);if(!n){n={additions:new Map,deletions:new Map};let t=e=>(e??``).replace(/\r?\n$/,``);for(let r of e.hunks){let i=r.additionStart,a=r.deletionStart,o=r.additionLineIndex,s=r.deletionLineIndex;for(let c of r.hunkContent)if(c.type===`context`)for(let r=0;r<c.lines;r++)n.additions.set(i++,t(e.additionLines[o++])),n.deletions.set(a++,t(e.deletionLines[s++]));else{for(let r=0;r<c.deletions;r++)n.deletions.set(a++,t(e.deletionLines[s++]));for(let r=0;r<c.additions;r++)n.additions.set(i++,t(e.additionLines[o++]))}}Zi.set(e,n)}return n[t]}function $i(e,t,n){let r=Qi(e,t);if(!r.size)return!0;let i=n.split(`
2
+ `);for(let[e,t]of r){let n=i[e-1];if(n===void 0||n.replace(/\r$/,``)!==t)return!1}return!0}var ea=3;function ta(e,t,n,r){let i=Qi(e,t),a=t===`deletions`?`-`:`+`,o=[];for(let e=Math.max(1,n-ea);e<=r+ea;e++){let t=i.get(e);if(t==null)continue;let s=e>=n&&e<=r?a:` `;o.push(`${s}${String(e).padStart(4)} | ${t}`)}return o.join(`
3
+ `)}function na(e,t){let n=null,r=()=>{if(!n||t.aborted)return;let i=e().closest(`[data-diff-main]`);if(i){let t=i.getBoundingClientRect(),r=0;if(n.y>=t.bottom-110?r=Math.max(4,Math.min(20,(n.y-(t.bottom-110))/3)):n.y<=t.top+110&&(r=-Math.max(4,Math.min(20,(t.top+110-n.y)/3))),r){i.scrollTop+=r;let a=e().getBoundingClientRect(),o=Math.max(t.top+12,a.top+48),s=Math.min(t.bottom-12,a.bottom-48),c=Math.max(o,Math.min(n.y,s));document.dispatchEvent(new PointerEvent(`pointermove`,{clientX:n.x,clientY:c,pointerId:n.pointerId,pointerType:`touch`,bubbles:!0,composed:!0}))}}requestAnimationFrame(r)};e().addEventListener(`pointerdown`,e=>{e.pointerType!==`mouse`&&e.composedPath().some(e=>e instanceof HTMLElement&&e.hasAttribute?.(`data-column-number`))&&(n={pointerId:e.pointerId,x:e.clientX,y:e.clientY},requestAnimationFrame(r))},{capture:!0,signal:t}),document.addEventListener(`pointermove`,e=>{n&&e.pointerId===n.pointerId&&e.isTrusted&&(n.x=e.clientX,n.y=e.clientY)},{capture:!0,passive:!0,signal:t});for(let e of[`pointerup`,`pointercancel`])document.addEventListener(e,e=>{n&&e.pointerId===n.pointerId&&(n=null)},{capture:!0,signal:t})}function U(e,t){let n=document.createElement(e);return t&&(n.className=t),n}function ra(e,t,n){let r=U(`div`,`_mP`),i=U(`span`,`_by`);i.textContent=n;let a=U(`a`,`_bm`);return a.href=e,a.target=`_blank`,a.rel=`noreferrer`,a.textContent=`Open in a new tab`,r.append(i,a),r}function ia(e,t,n){let r=U(`div`,`_mL`),i=U(`span`,`_by`);i.textContent=n;let a=U(`img`,`_mM`);return a.alt=`${n}: ${t}`,a.loading=`lazy`,a.decoding=`async`,a.onload=()=>{i.textContent=`${n} · ${a.naturalWidth} × ${a.naturalHeight}`},a.onerror=()=>{r.replaceChildren(ra(e,t,`Can't show this image here.`))},a.src=e,r.append(a),{frame:r,meta:i}}function aa(e,t,n){let r=U(`span`,`_by`);if(r.textContent=n,!navigator.pdfViewerEnabled){let n=U(`div`,`_mL`);return n.append(ra(e,t,`This browser can't display PDFs inline.`)),{frame:n,meta:r}}let i=U(`iframe`,`_mO`);return i.src=e,i.title=`${n}: ${t}`,i.loading=`lazy`,{frame:i,meta:r}}function oa(e,t,n){let r=U(`div`,`_mL`),i=U(`span`,`_by`);i.textContent=n;let a=U(`video`,`_mM`);return a.controls=!0,a.playsInline=!0,a.preload=`metadata`,a.onloadedmetadata=()=>{i.textContent=`${n} · ${a.videoWidth} × ${a.videoHeight}`},a.onerror=()=>{r.replaceChildren(ra(e,t,`Can't play this video here.`))},a.src=e,r.append(a),{frame:r,meta:i}}function sa(e,t,n){let r=U(`div`),i=U(`span`,`_by`);i.textContent=n;let a=U(`audio`,`_mN`);return a.controls=!0,a.preload=`metadata`,a.onerror=()=>{r.replaceChildren(ra(e,t,`Can't play this here.`))},a.src=e,r.append(a),{frame:r,meta:i}}function ca(e){let t=U(`div`,`_mJ`);for(let n of e.sides){let r=U(`div`,`_mK`),{frame:i,meta:a}=e.kind===`pdf`?aa(n.src,e.name,n.label):e.kind===`video`?oa(n.src,e.name,n.label):e.kind===`audio`?sa(n.src,e.name,n.label):ia(n.src,e.name,n.label);r.append(a,i),t.append(r)}return t}function la(e){return++e.seq}function ua(e,t){return t===e.seq}function da(e,t){return e.tagKey===t?e.etag:null}function fa(e,t,n){e.stamp=t,n&&(e.etag=n.etag,e.tagKey=n.tagKey)}function pa(e,t){let n=!!e.focusAt&&t>=e.focusAt;return n&&(e.focusAt=0),n}function ma(e){e.done!==e.seq&&(e.focusAt=e.seq)}function ha(e,t){return t===e.seq&&(e.done=t,!0)}function ga(e){return e.stamp}function _a(e,t){e.anchor=t}function va(e){return e.anchor}function ya(e,t){e.anchor?e.picks.set(t,e.anchor):e.picks.delete(t),e.anchor=null}function ba(e,t){return e.picks.get(t)}function xa(e,t){e.jump=null,e.line=null,e.pos=t,e.anchor=t}function Sa(e,t){e.pos=t}function Ca(e,t){e.pos=null,e.jump=t}function wa(e){e.jump=null}function Ta(e,t){e.line=t}function Ea(e){return e.pos}function Da(e){return e.jump}function Oa(e){return e.line}function ka(e){return Object.values(e).join(`|`)}function Aa(e){let t=wi(ki(e));if(!t)return null;let n=document.createElementNS(`http://www.w3.org/2000/svg`,`svg`);return n.setAttribute(`class`,`_jH`),n.setAttribute(`width`,String(T.lg)),n.setAttribute(`height`,String(T.lg)),n.setAttribute(`viewBox`,t.viewBox),n.setAttribute(`aria-hidden`,`true`),n.innerHTML=t.body,n}function W(e,t){let n=document.createElement(e);return t&&(n.className=t),n}function ja(e,t){let n=W(`button`,e);return n.type=`button`,n.onclick=e=>{e.stopPropagation(),t()},n}function Ma(e,n){let r=W(`div`,`_jE${e.collapsed?` _jF`:``}`);r.title=e.label;let i=W(`span`,`_jG`);i.append(t(hn,T.sm)),i.title=`${e.collapsed?`Expand`:`Collapse`} (${Yr()?`⌥`:`Alt+`}click: every file)`;let a=W(`span`,`_bO`);a.dataset.status=e.status,a.textContent=e.status;let o=W(`span`,`_jI`),s=W(`bdi`);s.textContent=e.label,o.append(s);let c=Aa(e.label);if(r.append(i,a,...c?[c]:[],o),e.patchless){let i=ja(Pt,n.comment);i.append(t(vn,T.sm)),e.notes&&i.append(` ${e.notes}`),i.title=e.notes?`${e.notes} comment${e.notes>1?`s`:``} — add another`:`Comment on this file`,i.setAttribute(`aria-label`,`Comment on this file`),r.append(i)}else if(e.notes){let n=W(`span`,`_M`);n.append(t(vn,T.sm),` ${e.notes}`),r.append(n)}if(e.errors){let i=ja(`_jJ`,n.errors);i.title=`${e.errors} type ${e.errors===1?`error`:`errors`} on changed lines: go to the first`,i.append(t(Ln,T.sm),` ${e.errors}`),r.append(i)}if(e.additions||e.deletions){let t=W(`span`,`_jK`),n=W(`span`,`_jL`);n.textContent=`+${e.additions||0}`;let i=W(`span`,`_jM`);i.textContent=`−${e.deletions||0}`,t.append(n,i),r.append(t)}if(e.viewed){let i=ja(`${Mt}${e.viewed===`viewed`?` _jO`:e.viewed===`changed`?` _jP`:``}`,n.view);i.append(t(cr,T.md)),i.setAttribute(`aria-pressed`,String(e.viewed===`viewed`)),i.setAttribute(`aria-label`,`Viewed`),i.title=`${e.viewed===`viewed`?`Viewed: clear the mark`:e.viewed===`changed`?`Changed since viewed: mark it viewed again`:`Mark viewed (scrolling past it does too)`}${Zr(`toggleViewed`)}`,r.append(i)}let l=ja(Nt,n.open);return l.append(t(yn,T.md)),e.open?(l.title=e.open,l.setAttribute(`aria-label`,`Open in Files`)):(l.disabled=!0,l.title=`This change deletes the file: nothing to open in Files`,l.setAttribute(`aria-label`,`Deleted: not in Files`)),r.append(l),r.onclick=e=>n.fold(e.altKey),r}var Na={all:!1,flip:[]};function Pa(e){let t=2166136261;for(let n=0;n<e.length;n++)t^=e.charCodeAt(n),t=Math.imul(t,16777619);return(t>>>0).toString(36)}var Fa=(e,t)=>Pa(t?`${e}\0viewed`:e),Ia=(e,t)=>e.all||t&&!e.open;function La(e){let t=yr(e);if(!t)return Na;try{let e=JSON.parse(t);return{all:e.all===!0,...e.open===!0&&{open:!0},flip:Array.isArray(e.flip)?e.flip.filter(e=>typeof e==`string`):[]}}catch{return Na}}function Ra(e,t){Fn(e,t.all||t.open||t.flip.length?JSON.stringify(t):null)}function za(e,t,n=!1){return Ia(e,n)!==e.flip.includes(Fa(t,n))}function Ba(e,t,n,r=!1){let i=Fa(t,r),a=Fa(t,!r),o=e.flip.filter(e=>e!==i&&e!==a);return n!==Ia(e,r)&&o.push(i),{all:e.all,...e.open&&{open:!0},flip:o.slice(-64)}}function Va(e,t=!1){return e?{all:!0,flip:[]}:t?{all:!1,open:!0,flip:[]}:{all:!1,flip:[]}}function Ha(e,t){return e.all===t.all&&!e.open==!t.open&&e.flip.length===t.flip.length&&e.flip.every((e,n)=>e===t.flip[n])}function Ua(e,t){if(!e.flip.length)return e;let n=new Set;for(let e of t)n.add(Fa(e,!1)).add(Fa(e,!0));let r=e.flip.filter(e=>n.has(e));return r.length===e.flip.length?e:{...e,flip:r}}var Wa=an,Ga=(e=>`/${e}&`)(qn);function Ka(e){Sn(e.a,Hn)}var qa=(e,t)=>Yn(e.a,t),Ja=(e,t)=>dn(e.a,t),Ya=an,Xa=(e=>`/${e}&`)(qn);function Za(e){Sn(e.a,nr)}var Qa=(e,t)=>Yn(e.a,t),$a=(e,t)=>dn(e.a,t),eo=an,to=(e=>`/${e}&`)(qn);function no(e){Sn(e.a,Mn)}var ro=(e,t)=>Yn(e.a,t),io=(e,t)=>dn(e.a,t),ao=40,oo;function so(e){return e.length>=200?null:[...new Set(e.map(e=>e.key))]}function co(e,t){let n=t.trim();if(!n)return[];if(oo&&oo.files===e&&oo.query===n)return oo.hits;let r=mo(e,n);return oo={files:e,query:n,hits:r},r}var lo=new WeakMap;function uo(e){let t=lo.get(e);if(!t){let n={additions:new Set,deletions:new Set};if(e.fileDiff){let n=Qi(e.fileDiff,`additions`),r=Qi(e.fileDiff,`deletions`),i=e=>{let t=[];for(let[n,r]of e)t[n-1]=r;return t},a=new Set;for(let t of e.fileDiff.hunks){let e=t.deletionStart;for(let n of t.hunkContent)if(n.type!==`context`)e+=n.deletions;else for(let t=0;t<n.lines;t++)a.add(e++)}t={visible:{additions:new Set(n.keys()),deletions:new Set(r.keys())},newLines:i(n),oldLines:i(r),context:a}}else t={visible:n,newLines:null,oldLines:null,context:new Set};lo.set(e,t)}return t}var fo=new Map;function po(e){let t=e.patch??``,n=fo.get(e.key);if(n&&n.patch===t)return n.lower;let r=t.toLowerCase();return fo.set(e.key,{patch:t,lower:r}),fo.size>4e3&&fo.delete(fo.keys().next().value),r}function mo(e,t){let n=/[A-Z]/.test(t),r=n?t:t.toLowerCase(),i=!/[^\x00-\x7f]/.test(r),a=[];for(let t of e){if(a.length>=200)break;let e=a.length;if(i&&!(n?t.patch??``:po(t)).includes(r)){ho(t.path,r,n)&&a.push({key:t.key,path:t.path,repo:t.repo,line:0,side:null,preview:t.path});continue}let{visible:o,newLines:s,oldLines:c,context:l}=uo(t);go(t,s,`additions`,r,n,null,a,o.additions),go(t,c,`deletions`,r,n,l,a,o.deletions),a.length===e&&ho(t.path,r,n)&&a.push({key:t.key,path:t.path,repo:t.repo,line:0,side:null,preview:t.path})}return a}function ho(e,t,n){let r=n?e:e.toLowerCase();if(!r.includes(t))return!1;let i=e.lastIndexOf(`/`),a=i>=0?e.slice(i+1):e,o=a.lastIndexOf(`.`);if(o<=0)return!0;let s=a.slice(o+1);if(!(n?s:s.toLowerCase()).includes(t))return!0;let c=e.length-s.length;for(let e=r.indexOf(t);e!==-1;e=r.indexOf(t,e+1))if(e<c)return!0;return!1}function go(e,t,n,r,i,a,o,s){if(!t||o.length>=200||!s.size)return;let c=0;for(let l=0;l<t.length;l++){if(o.length>=200||c>=ao)return;let u=l+1;if(!s.has(u)||a?.has(u))continue;let d=t[l];if(d==null)continue;let f=(i?d:d.toLowerCase()).indexOf(r);f<0||(c++,o.push({key:e.key,path:e.path,repo:e.repo,line:u,side:n,preview:_o(d,f,r.length)}))}}function _o(e,t,n){let r=Math.max(0,t-36),i=Math.min(e.length,t+n+36);return(r>0?`…`:``)+e.slice(r,i)+(i<e.length?`…`:``)}var vo=qr,yo=(e=>`0${e}&`)(Mr),bo=tn(15,e=>Fr(e.a,e.p)),xo=O(6,e=>bo(e,e.e,e.f)),So=z(4,xo),Co=z(5,xo),wo=tn(17),To=O(9,e=>wo(e,e.h,e.i)),Eo=z(7,To),Do=z(8,To),Oo=(e,t)=>Uo(e,t?.length),ko=O(20,e=>Oo(e,co(e.k,e.t))),Ao=O(31,e=>Pr(e.a,Xo(e)),2),jo=N(19,e=>{ko(e),Ao(e)}),Mo=O(27,e=>Wr(e.a,e.y?`${e.a0+1}/${e.y}`:`0/0`)),No=z(26,e=>{Mo(e),Ao(e)}),Po=O(25,e=>No(e,e.y?Math.min(e.v,e.y-1):-1)),Fo=D(`r7`,e=>{{let t=e.a2;if(t!==null){let n=setTimeout(()=>{Bo(e,null),e.a3(t,0)},80);Yt(e,0).onabort=()=>clearTimeout(n)}}}),Io=O(30,e=>{Qt(e,0),Fo(e)}),Lo=z(29,e=>{Io(e),Ao(e)}),Ro=O(22,e=>Lo(e,Zo(e))),zo=N(21,e=>{Po(e),Ro(e)}),Bo=N(28,Io),Vo=D(`r6`,e=>Bt(e,{onDestroy:function(){Fe(``,null)}}));function Ho(e){Ht(e,0,Go),Kr(e.a),Nr(e.a,`Find in review`),Ur(e.a,$o(e)),zr(e.a,Qo(e)),jo(e,``),zo(e,0),Bo(e,null),Vo(e)}var Uo=z(24,e=>{Vr(e.a,!!e.y),Po(e),Mo(e)}),Wo=z(10,e=>{Gr(e.a,es(e)),ko(e),Ro(e)}),Go=Kt(`r5`,z(32,e=>Gt(e,e.a6))),Ko=(e,t)=>jr(e.a,t),qo=(e,t)=>Ir(e.a,t),Jo=(e,t)=>Br(e.a,t),Yo=(e,t)=>Lr(e.a,t?`keybar`:`row`),Xo=e=>function(t){Bo(e,null),e.a3(e.t,(e.a0<0?0:e.a0)+t)},Zo=e=>(t,n)=>{let r=co(e.k,t);if(!r.length){zo(e,0),Fe(t,null,[]),wo(e,{query:t,hit:null});return}zo(e,(n%r.length+r.length)%r.length);let i=r[e.v];Fe(t,i,so(r)??void 0),wo(e,{query:t,hit:i})},Qo=e=>function(){Bo(e,null),jo(e,``),Fe(``,null),wo(e,{query:``,hit:null})},$o=e=>t=>{bo(e,t)},es=e=>function(t){jo(e,t),zo(e,0);let n=co(e.k,t);Fe(t,n[0]??null,so(n)??void 0),Bo(e,t)};P.r3=Xo,P.r0=Zo,P.r4=Qo,P.r1=$o,P.r2=es;var ts=`<!><!><!>`,ns=O(3,e=>R(e.a,`title`,`This view is ${a(e._._.u)} (${e._._.t}); checked out is ${a(e._._.z)} (${e._._.a1(e._._.a0)})`),4),rs=L(37,ns,e=>e._._,`S17`),is=e=>{rs(e),as(e),os(e),ss(e),cs(e),I(e.a,`_mS`),Ni(e.b),Mi(e.b,12),Pi(e.b)},as=L(38,ns,e=>e._._,`S18`),os=L(43,e=>{A(e.c,a(e._._.z,7)),ns(e)},e=>e._._,`S19`),ss=L(44,ns,e=>e._._,`S20`),cs=L(45,ns,e=>e._._,`S21`),ls=O(2,e=>R(e.a,`title`,`GitHub compares #${e._._.r} with ${e._._.a1(e._._.x)}; the stack puts it on ${e._._.a1(e._._.n)}. Restack the branch, or change the PR's base.`),3),us=L(32,ls,e=>e._._,`S8`),ds=e=>{us(e),fs(e),ps(e),ms(e),I(e.a,[`_mS`,`_mT`]),Rn(e.b),ir(e.b,12),$n(e.b)},fs=L(35,ls,e=>e._._,`S9`),ps=L(41,ls,e=>e._._,`S10`),ms=L(45,ls,e=>e._._,`S11`),hs=L(31,e=>A(e.c,a(e._._.m,7)),e=>e._._,`S7`),gs=e=>{hs(e),I(e.a,`_mS`),no(e.b),ro(e.b,12),io(e.b)},_s=O(2,e=>R(e.a,`title`,`${e._._.l.title} · ${ui(e._._.l)}: ${e._._.l.headRefName} ${e._._.u} vs ${e._._.v} ${e._._.w}`),3),vs=L(30,e=>{I(e.a,[Rt[ui(e._._.l)],`_mR`]),_s(e)},e=>e._._,`S1`),ys=e=>{vs(e),bs(e),xs(e),Ss(e),Cs(e),ws(e)},bs=L(35,e=>A(e.b,e._._.r),e=>e._._,`S2`),xs=L(36,e=>R(e.a,`href`,`${e._._.s}/files`),e=>e._._,`S3`),Ss=L(38,_s,e=>e._._,`S4`),Cs=L(39,_s,e=>e._._,`S5`),ws=L(40,_s,e=>e._._,`S6`),Ts=L(29,e=>R(e.a,`disabled`,e._._.i),e=>e._._,`S13`),Es=D(`S12`,e=>F(e.a,`click`,function(){e._._.j()})),Ds=e=>{Ts(e),ks(e),As(e),js(e),I(e.a,[`_mS`,`_mT`,`_mU`]),ci(e.b),si(e.b,12),li(e.b),Es(e)},Os=O(2,e=>R(e.a,`title`,`Behind GitHub: origin/${e._._.t} is ${a(e._._.u,7)}, GitHub has ${a(e._._.y,7)}. Reload.`),2),ks=L(37,Os,e=>e._._,`S14`),As=L(38,Os,e=>e._._,`S15`),js=L(42,Os,e=>e._._,`S16`),Ms=k(5,(e=>`<span>${e} </span>`)(ji),(e=>` D/${e}& l`)(Ai),is),Ns=j(0,0,e=>Ms(e,+!e._.h)),Ps=e=>{Ns._(e),zs._(e),Vs._(e),Hs._(e),Ws._(e),Gs._(e),I(e.a,`_mQ`)},Fs=k(1,`<a target=_blank rel=noopener>#<!></a>`,` Db%`,ys),Is=O(7,e=>R(e.a,`data-pr`,e._.l?`${e._.q}/${e._.l.number}`:void 0)),Ls=k(3,(e=>`<span role=img aria-label="Base differs from the stack">${e}</span>`)(Xn),(e=>` D/${e}&l`)(lr),ds),Rs=O(6,e=>Ls(e,e._.n&&e._.l?0:1)),zs=j(0,0,e=>{Fs(e,+!e._.l),Is(e),Rs(e)}),Bs=k(2,(e=>`<span title="One commit against its parent">${e} </span>`)(eo),(e=>` D/${e}& l`)(to),gs),Vs=j(0,0,e=>Bs(e,+!e._.m)),Hs=j(0,0,Rs),Us=k(4,(e=>`<button type=button aria-label="Behind GitHub: reload">${e}</button>`)(oi),(e=>` D/${e}&l`)(ai),Ds),Ws=j(0,0,e=>Us(e,+!e._.o)),Gs=j(0,0,Is),Ks=(e,t)=>{Xs(e,t?.pr),rc(e,t?.rev),ac(e,t?.baseMismatch),oc(e,t?.githubDrift),sc(e,t?.worktree),cc(e,t?.head),lc(e,t?.base),uc(e,t?.baseSha),dc(e,t?.localHead),fc(e,t?.branch)},qs=k(0,`<div><!><!><!><!><!></div>`,` D%b%b%b%b%`,Ps),Js=O(15,e=>qs(e,e.l||e.m||e.n||e.o||e.h?0:1),4),Ys=B(vs),Xs=z(11,e=>{Zs(e,e.l?.number),Qs(e,e.l?.url),$s(e,e.l?.headRefName),ec(e,e.l?.baseRefName),tc(e,e.l?.headRefOid),Js(e),zs(e),Ys(e)}),Zs=z(17,B(bs,fs)),Qs=z(18,B(xs)),$s=z(19,B(ks,rs)),ec=z(23,B(ps)),tc=z(24,B(js)),nc=B(hs),rc=z(12,e=>{Js(e),Vs(e),nc(e)}),ic=B(us),ac=z(13,e=>{Js(e),Hs(e),ic(e)}),oc=z(14,e=>{Js(e),Ws(e)}),sc=z(16,Gs),cc=z(20,B(As,Ss,as)),lc=z(21,B(Cs)),uc=z(22,B(ws)),dc=z(25,B(os)),fc=z(26,B(ss)),pc=Ks,mc=z(27,B(ms,cs)),hc=O(6,e=>mc(e,xc(e))),gc=z(4,hc),_c=z(5,hc),vc=z(7,e=>{Js(e),Ns(e)}),yc=z(8,B(Ts)),bc=z(9),xc=e=>t=>Or(t,e.e,e.f);P.S0=xc;function Sc(e){let t=new Map,n=new Set;for(let r of e){let e=r.compare?.topic||r.compare?.head,i=(e?`${r.label} · ${e}`:r.label).replaceAll(`/`,`∕`),a=i;for(let e=2;n.has(a);e++)a=`${i} (${e})`;n.add(a),t.set(r.id,a)}return t}var Cc=e=>`${e}/`;function wc(e){let t=new Set;for(let n of e){let e=n.indexOf(`/`);for(;e>=0;)t.add(n.slice(0,e+1)),e=n.indexOf(`/`,e+1)}return[...t]}var Tc=new Intl.Collator(void 0,{numeric:!0,sensitivity:`base`});function Ec(e){return(t,n)=>{let r=Math.min(t.segments.length,n.segments.length);for(let i=0;i<r;i++){let r=t.segments[i],a=n.segments[i];if(r===a)continue;if(i===0)return(e.get(r)??2**53-1)-(e.get(a)??2**53-1)||(r<a?-1:1);let o=i<t.segments.length-1||t.isDirectory;return o===(i<n.segments.length-1||n.isDirectory)?Tc.compare(r,a)||(r<a?-1:1):o?-1:1}return t.segments.length===n.segments.length?t.isDirectory===n.isDirectory?0:t.isDirectory?-1:1:t.segments.length-n.segments.length}}var Dc=e=>`"${e.replaceAll(`\\`,`\\\\`).replaceAll(`"`,`\\"`)}"`;function Oc(e,t){let n=(e,t=``)=>`[data-item-path=${Dc(Cc(e))}]${t},[data-file-tree-sticky-path=${Dc(Cc(e))}]${t}`,r=[];for(let i of e)r.push(`${n(i.root)}{background:${i.lit?t.lit:t.band};font-weight:${t.weight}}`),i.unpushed&&r.push(`${n(i.root,` [data-item-section="content"]`)}{color:${t.dim}}`);return r.join(`
4
+ `)}function kc(e){return e.length?`:is(${e.map(e=>`[data-item-path=${Dc(e)}]`).join(`,`)}) :is([data-item-section="content"],[data-item-section="icon"],[data-item-section="git"]){opacity:.5}`:``}var Ac=`<!><!><!>`,jc=L(9,e=>I(e.a,[`_o7`,{_o9:e._._.d}]),e=>e._._,`R2`),Mc=e=>{jc(e),Nc(e)},Nc=L(12,e=>A(e.b,e._._.h),e=>e._._,`R3`),Pc=L(9,e=>I(e.a,[`_o8`,{_o9:e._._.d}]),e=>e._._,`R0`),Fc=e=>{Pc(e),Ic(e)},Ic=L(11,e=>A(e.b,e._._.g),e=>e._._,`R1`),Lc=j(0,0,e=>R(e.a,`title`,e._.f)),Rc=e=>{Lc._(e),Vc._(e),Hc._(e),Uc._(e),I(e.a,`_o6`)},zc=k(1,`<span> </span>`,` D `,Fc,`<span> </span>`,` D `,Mc),Bc=O(3,e=>zc(e,e._.g?0:e._.h?1:2)),Vc=j(0,0,Bc),Hc=j(0,0,Bc),Uc=j(0,0,e=>A(e.c,e._.i?`${Zt(` `)}vs ${Zt(e._.i)}`:``)),Wc=k(0,`<span><!><!></span>`,` D%b%`,Rc),Gc=(e,t)=>{qc(e,t?.title),Yc(e,t?.topic),Zc(e,t?.head),Qc(e,t?.base),Wc(e,+!t)},Kc=z(3,B(Pc,jc)),qc=z(5,Lc),Jc=B(Ic),Yc=z(6,e=>{Vc(e),Jc(e)}),Xc=B(Nc),Zc=z(7,e=>{Hc(e),Xc(e)}),Qc=z(8,Uc),$c=`<!><!><!>`,el=D(`m0`,e=>F(e.a,`click`,function(){e._._.f?.()})),tl=e=>{I(e.a,`_pc`),R(e.a,`title`,`${e.M}: open it in Files`),I(e.b,`_pd`),A(e.c,e.M),I(e.d,`_pe`),Ct(e.e),Pe(e.e,12),Tt(e.e),el(e)},nl=(e,t)=>R(e.a,`href`,t),rl=(e,t)=>A(e.f,t),il=M(2,(e=>`<a><span><bdi> </bdi></span><span>${e} </span></a>`)(he),(e=>` D E m D/${e}& m`)(o),tl,(e,t)=>{nl(e,t[0]?.href),rl(e,t[0]?.count)}),al=j(0,0,e=>il(e,[e._.d,`label`])),ol=k(0,`<div role=group aria-label="Comments on other files"><div>Comments on other files</div><!></div>`,` D b%`,e=>{al._(e),I(e.a,`_pa`),I(e.b,`_pb`)}),sl=(e,t)=>ol(e,+!t),cl=z(3,e=>{sl(e,e.d?.length),al(e)}),ll=z(5),ul=`<!><!><!>`,dl=j(5,1,e=>A(e.b,e._.u)),fl=e=>{dl._(e),I(e.a,`_pl`)},pl=j(5,0,e=>I(e.a,[`_pj`,{_pk:!!e._.s}])),ml=e=>{pl._(e),hl._(e)},hl=j(5,0,e=>A(e.b,e._.u)),gl=O(22,e=>R(e.a,`title`,`Unfold ${e.n}${e.u?` ${e.u}`:``} (${Ti(e.p,`file`)})`),2),_l=k(5,`<span> </span>`,` D `,ml,`<span> </span>`,` D `,fl),vl=O(21,e=>_l(e,e.k?0:e.u?1:2)),yl=z(20,e=>{gl(e),vl(e),hl(e),dl(e)}),bl=O(12,e=>yl(e,e.k||e.l||``)),xl=z(10,e=>{bl(e),vl(e)}),Sl=z(11,bl),Cl=D(`B0`,e=>F(e.a,`click`,function(){e._._.f(e.M)})),wl=e=>{I(e.a,[`_M`,`_pg`]),I(e.b,`_ph`),Xr(e.c),Qr(e.c,12),ii(e.c),I(e.d,`_pi`),Cl(e)},Tl=z(13,e=>{A(e.e,e.n),gl(e)}),El=z(15,gl),Dl=(e,t)=>v(e.g,t),Ol=(e,t)=>{xl(e,t[0]?.compare?.topic),Sl(e,t[0]?.compare?.head),Tl(e,t[0]?.label),El(e,t[0]?.files?.length),kl(e,t[0]?.state?.unpushed),Dl(e,t[0]?.state?.edits)},kl=z(18,pl),Al=M(0,((e,t)=>`<button type=button aria-expanded=false><span aria-hidden=true>${e}</span><span> </span><!>${t}</button>`)(ri,b),((e,t)=>` D D/${e}&l D l%b/${t}&l`)($r,`b%c`),wl,Ol),jl=j(0,0,e=>Al(e,[e._.d,`id`])),Ml=k(0,`<div role=group aria-label="Folded sections"></div>`,` `,e=>{jl._(e),I(e.a,`_pf`)}),Nl=(e,t)=>Ml(e,+!t),Pl=z(3,e=>{Nl(e,e.d?.length),jl(e)}),Fl=z(5),Il=((e,t)=>`<div><div title="Drag to resize"></div><div><!><!><div data-tree-all></div></div>${e}${t}</div>`)($c,ul),Ll=((e,t)=>` D b D%b%b l/${e}&/${t}&l`)(`b%c`,`b%c`),Rl={A:`added`,D:`deleted`,M:`modified`,R:`renamed`},zl={open:E.ok,draft:E.dim,merged:E.merged,closed:E.closed},Bl=j(5,0,e=>I(e.a,Rt[ui(e._.o)])),Vl=e=>{Bl._(e),Hl._(e)},Hl=j(5,0,e=>A(e.b,e._.p)),Ul=O(6,e=>R(e.a,`hidden`,e._.aj!==e.M||!e.f)),Wl=zt(4,45,`M`,Ul),Gl=e=>{Wl._(e),I(e.a,`_cW`),R(e.a,`data-tree`,e.M)},Kl=z(5,Ul),ql=(e,t)=>Kl(e,t[0]?.files?.length),Jl=O(20,e=>I(e.a,[`_cT`,{_cS:e.t,_cH:!!e.k}])),Yl=z(19,e=>{R(e.a,`aria-current`,e.t?`true`:void 0),Jl(e)}),Xl=O(18,e=>Yl(e,e.r===e._._.r)),Zl=L(64,Xl,e=>e._._,`V4`),Ql=D(`V3`,e=>F(e.a,`click`,function(){e._._._._.r?.(e.M)})),$l=e=>{Zl(e),I(e.b,`_cU`),I(e.d,`_cV`),Ql(e)},eu=z(17,e=>{A(e.c,e.r+1),Xl(e)}),tu=z(10,Jl),nu=O(12,e=>R(e.a,`title`,[e.l,Le(e.j)].filter(Boolean).join(`
5
+ `))),ru=z(9,e=>{tu(e,e.j?.unpushed),ou(e,e.j?.pr),su(e,e.j?.edits),nu(e)}),iu=z(11,e=>{A(e.e,e.l),nu(e)}),au=k(5,`<span>#<!></span>`,` Db%`,Vl),ou=z(14,e=>{lu(e,e.o?.number),au(e,+!e.o),Bl(e)}),su=(e,t)=>v(e.g,t),cu=(e,t)=>{ru(e,t[0]?.state),iu(e,t[0]?.name),eu(e,t[1])},lu=z(15,Hl),uu=M(0,(e=>`<button type=button><span> </span><span> </span><!>${e}</button>`)(b),(e=>` D D l D l%b/${e}&l`)(`b%c`),$l,cu),du=L(61,e=>uu(e,[e._._.n,`id`]),e=>e._._,`V6`),fu=e=>{du(e),mu._(e),I(e.a,`_cR`)},pu=D(`V5`,e=>{{let t=e.a,n=t.children[e._.r];n&&n.offsetTop<t.scrollTop?t.scrollTop=n.offsetTop:n&&n.offsetTop+n.offsetHeight>t.scrollTop+t.clientHeight&&(t.scrollTop=n.offsetTop+n.offsetHeight-t.clientHeight)}}),mu=j(14,0,pu),hu=k(14,`<div></div>`,` `,fu),gu=L(51,e=>{R(e.c,`aria-expanded`,e._._.a2?`true`:`false`),R(e.c,`title`,e._._.a2?`Hide the layers`:`Every layer`),ii(e.d,[`_cN`,{_cM:e._._.a2}]),hu(e,+!e._._.a2)},e=>e._._,`V8`),_u=D(`V7`,e=>{F(e.c,`click`,function(){ad(e._._,!e._._.a2),pr(e._._.a2)}),F(e.h,`click`,function(){e.t&&e._._.r?.(e.t?.id)}),F(e.m,`click`,function(){e.u&&e._._.r?.(e.u?.id)})}),vu=e=>{gu(e),Tu(e),Eu._(e),Ou._(e),ku._(e),I(e.a,`_cJ`),I(e.b,`_cK`),I(e.c,`_cL`),Xr(e.d),Qr(e.d,12),Tr(e.e),Rr(e.e,12),br(e.e),I(e.f,`_cO`),I(e.h,[Ot,`_cP`]),u(e.i),_e(e.i,12),xt(e.i),I(e.j,`_cQ`),I(e.m,[Ot,`_cP`]),Xr(e.n),Qr(e.n,12),ii(e.n),_u(e)},yu=z(19,e=>{R(e.h,`disabled`,!e.t),R(e.h,`title`,e.t?`Layer below: ${e.t?.name}`:`The bottom layer`)}),bu=z(20,e=>{R(e.m,`disabled`,!e.u),R(e.m,`title`,e.u?`Layer above: ${e.u?.name}`:`The top layer`)}),xu=O(18,e=>{yu(e,e._.n[e.r-1]),bu(e,e._.n[e.r+1])}),Su=B(Zl),Cu=z(17,e=>{A(e.k,e.r+1),xu(e),mu(e),Su(e)}),wu=O(15,e=>Cu(e,e._.n.findIndex(t=>t.id===e._._.aj))),Tu=L(60,wu,e=>e._._,`V9`),Eu=j(7,0,e=>{wu(e),xu(e)}),Du=O(16,e=>R(e.a,`aria-label`,`${e._.o} stack: ${e._.p} layers`)),Ou=j(7,0,e=>{A(e.g,e._.o),Du(e)}),ku=j(7,0,e=>{A(e.l,e._.p),Du(e)}),Au=en(1),ju=O(2,e=>Au(e,e._._.p,()=>({id:e._._.aj}))),Mu=L(49,ju,e=>e._._,`V1`),Nu=e=>{Mu(e),Pu(e),I(e.a,`_cI`)},Pu=L(60,ju,e=>e._._,`V2`),Fu=k(6,`<div><!></div>`,` D%`,Nu),Iu=j(3,0,e=>Fu(e,+!e._.p)),Lu=e=>{Iu._(e),Vu._(e),Wu._(e),Ku._(e),qu._(e),Ju._(e),Yu._(e),Xu._(e),Zu._(e),Qu._(e),$u._(e),I(e.a,`_cE`),I(e.b,`_cF`)},Ru=k(7,((e,t,n,r)=>`<div role=group><div><button type=button>${e}${t}<span> </span></button><button type=button aria-label="Layer below">${n}</button><span><!> of <!></span><button type=button aria-label="Layer above">${r}</button></div><!></div>`)(ri,Er,c,ri),((e,t,n,r)=>` D D D/${e}&/${t}& D m D/${n}&l D%c%l D/${r}&m%l`)($r,Dr,ue,$r),vu),zu=(e,t)=>{td(e,t?.layers),rd(e,t?.name),Ru(e,+!t)},Bu=O(8,e=>zu(e,e._.q?.layers.some(t=>t.id===e._.aj)?e._.q:void 0)),Vu=j(3,0,Bu),Hu=O(10,e=>R(e.b,`title`,`${e._.ac}: ${H(e._.ae)} ${e._.ae===1?`file`:`files`}, +${H(e._.af)} −${H(e._.ag)}${e.j?` · ${e.j}`:``}`),4),Uu=z(9,Hu),Wu=j(3,0,e=>Uu(e,e._.aa?Le(e._.aa):void 0)),Gu=(e,t)=>{I(e.c,[`_cG`,{_cH:t}]),Kc(e.e,t)},Ku=j(3,0,e=>Gu(e,!!e._.ab)),qu=j(3,0,e=>{A(e.d,e._.ac),Hu(e)}),Ju=j(3,0,Hu),Yu=j(3,0,Hu),Xu=j(3,0,Hu),Zu=j(3,0,e=>Gc(e.e,e._.ah)),Qu=j(3,0,e=>v(e.f,e._.ai)),$u=j(3,0,Bu),ed=B(du),td=z(13,e=>{nd(e,e.n?.length),Eu(e),ed(e)}),nd=z(15,ku),rd=z(14,Ou),id=N(27,e=>I(e.b,[`_cY`,{_cX:e.a1}])),ad=N(28,B(gu)),od=z(48),sd=D(`V11`,e=>{ad(e,on()),sr(`stack-list`,()=>{ad(e,on())},Yt(e,0)),F(e.b,`pointerdown`,function(t){kr(e.am,t,e.b)&&id(e,!0)}),F(e.b,`pointermove`,function(t){Sr(e.am,t,e.a)}),F(e.b,`pointerup`,function(t){Ar(e.am,t,e.a)&&id(e,!1)}),F(e.b,`pointercancel`,function(t){Ar(e.am,t,e.a)&&id(e,!1)})});function cd(e){Qt(e,0),I(e.c,`_cD`),I(e.f,`_cW`),ll(e.g),Fl(e.h,Jd(e)),id(e,!1),ad(e,!1),od(e,{id:-1,w:0}),sd(e)}var ld=(e,t)=>Pl(e.h,t),ud=O(34,e=>ld(e,e.a6?[]:e.a3.filter(t=>e.n.has(t.id))),2),dd=z(29,e=>{gd(e,e.a3?.length),_d(e,e.a3?.[0]),ud(e)}),fd=k(3,((e,t)=>`<div><div><span> </span>${e}${t}</div><!><!></div>`)(Ac,b),((e,t)=>` D D D l/${e}&/${t}&l%b%l`)(`b%c`,`b%c`),Lu),pd=(e,t)=>{Cd(e,t?.state),Ed(e,t?.label),Dd(e,t?.files?.length),Od(e,t?.additions),kd(e,t?.deletions),Ad(e,t?.compare),Md(e,t?.id),fd(e,+!t)},md=O(33,e=>pd(e,e.a6?e.a5:null)),hd=z(32,e=>{R(e.f,`hidden`,e.a6),md(e),ud(e)}),gd=(e,t)=>hd(e,t===1),_d=z(31,md),vd=O(12,e=>dd(e,e.k?e.l.filter(t=>t.id===e.k):e.l)),yd=z(10,vd),bd=M(4,`<div></div>`,` `,Gl,ql),xd=D(`V10`,e=>Bt(e,{sections:e.l,loneId:e.aj??null,folded:e.n,active:e.u??null,localDiffers:e.v,commentCounts:e.w,viewStates:e.x,onMount:function(){let t=this,n=()=>t.sections,r=()=>t.viewStates,i=(e,t)=>{let n=e.getItem(t);return n?.isDirectory()?n:null},a=(e,t)=>t.map((t,n)=>({path:e[n],status:Rl[t.status]??`modified`})),o=e=>e.files.map(e=>`${e.path}:${e.status}`).join(`
6
+ `),s=()=>JSON.stringify([[...t.commentCounts].sort(),[...r()].filter(([,e])=>e===`changed`).sort(),n().map(e=>[e.id,e.files.length,e.total,e.additions,e.deletions,e.compare?.base,e.repo?.pr?.number,e.repo?.pr&&ui(e.repo.pr),e.repo?.pr?.title,e.repo?.baseMismatch,e.repo?.githubDrift,e.state&&Le(e.state)]),[...t.localDiffers??[]]]),c=t=>e.a.querySelector(`[data-tree="${CSS.escape(t)}"]`),l=`<path d="${vn}" stroke="var(--dim)"/>`,u=`<symbol id="work-comment" viewBox="0 0 24 24" fill="none" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">${l}</symbol><symbol id="work-comment-new" viewBox="0 0 24 24" fill="none" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">${l}<circle cx="19.5" cy="4.5" r="4" fill="var(--accent-text)" stroke="none"/></symbol>`,d=e=>{let n=t.commentCounts,i=n.has(e),a=r().get(e)===`changed`;if(!i&&!a)return null;let o=n.get(e)??0,s=[a&&`Changed since viewed`,i&&`${H(o)} comment${o===1?``:`s`}`].filter(Boolean).join(` · `);return i?{icon:{name:a?`work-comment-new`:`work-comment`,width:12,height:12,viewBox:`0 0 24 24`},title:s}:{text:`●`,parts:[{text:`●`,color:`var(--accent-text)`}],title:s}},f=new WeakMap,p=(e,t)=>{let n=e?.getFileTreeContainer()?.shadowRoot;if(!e||!n)return;let r=f.get(e);r?.text!==t&&(r||(r={css:new CSSStyleSheet,text:``},f.set(e,r),n.adoptedStyleSheets=[...n.adoptedStyleSheets,r.css]),r.text=t,r.css.replaceSync(t))},m=(e,t)=>kc(e.files.filter(e=>r().get(e.key)===`viewed`).map(e=>t(e.path))),h=new WeakMap,ee=(e,t)=>{let n=Oi(t);h.get(e)!==n&&(h.set(e,n),e.setIcons(Di(u,t)))},te=(t,n)=>{let r=new Re({paths:[],initialExpansion:`open`,density:.85,icons:Di(u,n.paths??[]),search:!1,onSelectionChange(n){if(!n.length)return;let i=n.length===1&&!r.getItem(n[0])?.isDirectory()?n[0]:null;queueMicrotask(()=>{for(let e of r.getSelectedPaths())r.getItem(e)?.deselect();let n=i&&t(i);n&&e.y(n)})},...n});return h.set(r,Oi(n.paths??[])),r},g=new Map,ne=e=>{let t=e.files.map(e=>e.path),n=g.get(e.id);if(!n){let n=c(e.id);if(!n)return;let r=te(t=>`${e.id}/${t}`,{paths:t,gitStatus:a(t,e.files),flattenEmptyDirectories:!0,renderRowDecoration:({row:t})=>t.kind===`file`?d(`${e.id}/${t.path}`):null});r.render({containerWrapper:n}),g.set(e.id,{tree:r,paths:t,status:o(e)}),p(r,m(e,e=>e));return}if(t.join(`
7
+ `)!==n.paths.join(`
8
+ `)){try{n.tree.batch(qe(n.paths,t))}catch{n.tree.resetPaths(t)}n.paths=t,ee(n.tree,t)}let r=o(e);r!==n.status&&(n.status=r,n.tree.setGitStatus(a(t,e.files))),p(n.tree,m(e,e=>e))},re=new Map,_=new Map,ie=new Map,ae=new Map,v=new Set,y={tree:null},oe=e=>{let t=e.indexOf(`/`),n=ie.get(t<0?e:e.slice(0,t));return n?{id:n,rest:t<0?``:e.slice(t+1)}:null},se=n=>{let r=n.repo,i=!!t.localDiffers?.has(n.id),a=[r?.baseMismatch&&r.pr&&`GitHub compares #${r.pr.number} with ${r.pr.baseRefName}; the stack puts it on ${Or(r.baseMismatch,e.z,e.a0)}`,r?.githubDrift&&`Behind GitHub: reload to see its latest push`,i&&`Its branch is checked out at another commit`].filter(Boolean),o=n.files.length,s=[n.compare?.base&&{text:`vs ${n.compare.base}\u2002`,color:E.dim},r?.pr&&{text:`#${r.pr.number}\u2002`,color:zl[ui(r.pr)]},a.length&&{text:`⚠ `,color:E.warnStrong},r?.edits&&{text:`✎ `,color:E.dim},{text:H(o),color:E.dim}].filter(Boolean),c=n.state?Le(n.state):null;return{text:s.map(e=>e.text).join(``),parts:s,title:[`${_.get(n.id)?.root??n.label}: ${H(o)}${o===n.total?``:` of ${H(n.total)}`} ${n.total===1?`file`:`files`}, +${H(n.additions)} −${H(n.deletions)}`,r?.pr&&`#${r.pr.number} ${r.pr.title}`,c,...a,`Collapse it to fold it out of the review`].filter(Boolean).join(`
9
+ `)}},ce=()=>{let e=Oc(n().filter(e=>_.has(e.id)).map(e=>({root:_.get(e.id).root,unpushed:!!e.state?.unpushed,lit:e.id===t.active})),{band:E.raised,lit:`color-mix(in srgb, ${E.accent} 6%, ${E.raised})`,dim:E.dim,weight:`600`}),r=n().filter(e=>_.has(e.id)).map(e=>m(e,t=>`${_.get(e.id).root}/${t}`));p(y.tree,[e,...r].filter(Boolean).join(`
10
+ `))},le=()=>{let t=y.tree;if(t)for(let[n,r]of _){if(v.has(n))continue;let a=i(t,Cc(r.root));a&&!a.isExpanded()&&(v.add(n),queueMicrotask(()=>e.t(n)))}},ue=()=>{if(!y.tree){let t=e.a.querySelector(`[data-tree-all]`);if(!t)return;y.tree=te(e=>{let t=oe(e);return t?.rest?`${t.id}/${t.rest}`:null},{sort:Ec(re),flattenEmptyDirectories:!1,stickyFolders:!0,renderRowDecoration:({row:e})=>{let t=oe(e.path);if(!t)return null;if(e.kind===`file`)return d(`${t.id}/${t.rest}`);if(t.rest)return null;let r=n().find(e=>e.id===t.id);return r?se(r):null}}),y.tree.render({containerWrapper:t}),y.tree.subscribe(le)}let r=y.tree,s=t.folded,c=n(),l=Sc(c),u=c.filter(e=>!s.has(e.id)),f=u.filter(e=>_.get(e.id)?.root===l.get(e.id)).map(e=>e.id),p=f.join(`
11
+ `)!==[..._.keys()].filter(e=>f.includes(e)).join(`
12
+ `),m=[],h=[],g=[],ne=[];for(let[e,t]of[..._])(p||!f.includes(e))&&(ae.set(e,wc(t.paths.map(e=>e.slice(t.root.length+1))).filter(e=>i(r,`${t.root}/${e}`)?.isExpanded()===!1)),m.push({type:`remove`,path:Cc(t.root),recursive:!0}),g.push(...t.paths),ie.delete(t.root),_.delete(e),v.delete(e));re.clear(),u.forEach((e,t)=>re.set(l.get(e.id),t));for(let e of u){let t=l.get(e.id),n=e.files.length?e.files.map(e=>`${t}/${e.path}`):[Cc(t)],r=_.get(e.id);if(!r){for(let e of n)m.push({type:`add`,path:e});h.push(...a(n,e.files)),_.set(e.id,{root:t,paths:n,status:o(e)}),ie.set(t,e.id),ne.push({id:e.id,root:t});continue}n.join(`
13
+ `)!==r.paths.join(`
14
+ `)&&(m.push(...qe(r.paths,n)),r.paths=n);let i=o(e);i!==r.status&&(r.status=i,h.push(...a(n,e.files))),v.delete(e.id)}if(m.length){try{r.batch(m)}catch{r.resetPaths([..._.values()].flatMap(e=>e.paths))}ee(r,[..._.values()].flatMap(e=>e.paths))}(h.length||g.length)&&r.applyGitStatusPatch({set:h,remove:g});for(let{id:e,root:t}of ne){for(let n of ae.get(e)??[])i(r,`${t}/${n}`)?.collapse();ae.delete(e)}for(let[e,t]of _){let n=i(r,Cc(t.root));!v.has(e)&&n&&!n.isExpanded()&&n.expand()}ce()},de=matchMedia(jt),fe={on:de.matches},pe={sig:``},me=()=>{if(!fe.on)return;let e=t.loneId;if(e){let t=n().find(t=>t.id===e);t&&ne(t)}else ue();let r=s();if(r!==pe.sig){pe.sig=r;for(let e of g.values())e.tree.setComposition(e.tree.getComposition());y.tree?.setComposition(y.tree.getComposition())}},b=new AbortController;return de.addEventListener(`change`,()=>{de.matches&&!fe.on&&(fe.on=!0,me())},{signal:b.signal}),me(),{gate:fe,abort:b,loneTrees:g,all:y,sync:me}},onUpdate:function(){if(!this.gate.on)return;let e=new Set(this.sections.map(e=>e.id));for(let[t,n]of this.loneTrees)e.has(t)||(n.tree.cleanUp(),this.loneTrees.delete(t));this.sync()},onDestroy:function(){this.abort.abort();for(let e of this.loneTrees.values())e.tree.cleanUp();this.all.tree?.cleanUp()}})),G=O(46,xd,10),Sd=z(11,e=>{bd(e,[e.l,`id`]),vd(e),G(e)}),Cd=z(36,e=>{wd(e,e.aa?.unpushed),Td(e,e.aa?.edits),Wu(e)}),wd=z(37,Ku),Td=z(44,Qu),Ed=z(38,qu),Dd=z(40,Ju),Od=z(41,Yu),kd=z(42,Xu),Ad=z(43,Zu),jd=B(Pu,Tu),Md=z(45,e=>{G(e),$u(e),jd(e),Wl(e)}),Nd=z(13,e=>{ud(e),G(e)}),Pd=(e,t)=>I(e.a,[`_cC`,{_cB:t===!1}]),Fd=(e,t)=>cl(e.g,t||[]),Id=z(19,G),Ld=z(20,G),Rd=z(21,G),zd=z(22,G),Bd=z(23,G),Vd=z(24,G),Hd=z(25,G),Ud=z(26,G),Wd=B(Mu),Gd=z(15,e=>{Iu(e),Wd(e)}),Kd=z(16,Vu),qd=z(17),Jd=e=>function(t){e.t(t)};P.V0=Jd;var Yd=yi,Xd=(e=>`/${e}&`)(` b`);function Zd(e){let t=[],n=new Map;for(let r of e.files){let e=r.label.slice(r.label.indexOf(`/`)+1),i=e.lastIndexOf(`/`),a=i<0?``:e.slice(0,i),o=i<0?e:e.slice(i+1),s=n.get(a);s||(n.set(a,s={dir:a,files:[]}),t.push(s)),s.files.push({file:r,name:o})}return t}var Qd=e=>I(e.a,`_om`),$d=e=>{Ct(e.a),Pe(e.a,12),Tt(e.a,`_op`)},ef=e=>I(e.a,[`_ba`,`_on`]),tf=e=>{I(e.a,It),R(e.a,`title`,e._.M),A(e.b,e._.M)},nf=j(1,1,e=>A(e.c,e._.l)),rf=e=>{nf._(e),af._(e),of._(e),sf._(e),I(e.a,`_n_`)},af=j(1,1,e=>Gc(e.d,e._.m)),of=j(1,1,e=>v(e.e,e._.n)),sf=j(1,1,e=>{I(e.b,[`_od`,{_oe:e._.p}]),Kc(e.d,e._.p)}),cf=L(43,e=>A(e.b,e._._.l),e=>e._._,`q7`),lf=e=>{cf(e),uf(e),df(e)},uf=L(44,e=>Gc(e.c,e._._.m),e=>e._._,`q8`),df=L(47,e=>{I(e.a,[`_od`,{_oe:e._._.p}]),Kc(e.c,e._._.p)},e=>e._._,`q9`),ff=L(44,e=>Gc(e.b,e._._.m),e=>e._._,`q5`),pf=e=>{ff(e),mf(e),I(e.a,`_od`)},mf=L(47,e=>Kc(e.b,e._._.p),e=>e._._,`q6`),hf=k(6,he,(e=>`/${e}&`)(o),$d),gf=L(34,e=>hf(e,+!e._._._._._.v.has(e.M)),e=>e._._._._._,`q14`),_f=D(`q13`,e=>F(e.a,`click`,function(){xp(e._._._._._,!1)})),vf=e=>{gf(e),bf(e),xf(e),I(e.b,`_bO`),I(e.d,`_ok`),_f(e)},yf=k(5,`<span title="Changed since viewed"></span>`,` `,ef),bf=L(35,e=>{I(e.a,[`_oi`,`_3`,{_oo:e._._._._._.w.get(e.M)===`viewed`}]),yf(e,e._._._._._.w.get(e.M)===`changed`?0:1)},e=>e._._._._._,`q15`),xf=L(40,e=>R(e.a,`href`,e._._._._._.a2(e.M)),e=>e._._._._._,`q16`),Sf=(e,t)=>{R(e.b,`data-status`,t),A(e.c,t)},Cf=(e,t)=>A(e.e,t),wf=(e,t)=>{Sf(e,(t?.[0]).file?.status),Cf(e,(t?.[0]).name)},Tf=k(1,`<div><bdi><!>/</bdi></div>`,` E%`,tf),Ef=e=>{I(e.a,`_oh`),Tf(e,+!e.M)},Df=M(2,`<a><span> </span><span><bdi> </bdi></span><!><!></a>`,` D D l E m%b%`,vf,wf),Of=(e,t)=>Df(e,[t,e=>e.file.key]),kf=(e,t)=>Of(e,(t?.[0]).files),Af=en(1),jf=L(31,e=>Af(e,e._._._._.r,()=>({id:e._.M})),e=>e._._._._,`q12`),Mf=e=>{jf(e),I(e.a,`_og`)},Nf=k(3,(e=>`<span>${e}</span>`)(Ac),(e=>` D/${e}&l`)(`b%c`),pf,(e=>`<span> </span>${e}<!>`)(Ac),(e=>` D l/${e}&b`)(`b%c`),lf),Pf=(e,t)=>{I(e.a,[`_n_`,`_oa`,{_ob:t}]),Nf(e,+!t)},Ff=L(37,e=>Pf(e,e._._._._.z.has(e._.M)),e=>e._._._._,`q11`),If=D(`q10`,e=>F(e.a,`click`,function(){e._._._._.q(e._.M)})),Lf=e=>{Ff(e),Rf._(e),zf._(e),Bf._(e),I(e.b,`_oc`),Xr(e.c),Qr(e.c,12),ii(e.c),I(e.f,`_of`),If(e)},Rf=j(1,0,e=>R(e.a,`title`,`Fold ${e._.l}`)),zf=j(1,0,e=>v(e.e,e._.n)),Bf=j(1,0,e=>A(e.g,e._.o)),Vf=k(2,`<div><!></div>`,` D%`,Mf),Hf=L(31,e=>Vf(e,+!e._._._.r),e=>e._._._,`q17`),Uf=e=>{Hf(e),Gf(e),I(e.a,`_n9`)},Wf=k(1,((e,t)=>`<button type=button aria-expanded=true><span aria-hidden=true>${e}</span><!>${t}<span> </span></button>`)(ri,b),((e,t)=>` D D/${e}&l%b/${t}& D m`)($r,`b%c`),Lf,((e,t)=>`<div><span> </span>${e}${t}</div>`)(Ac,b),((e,t)=>` D D l/${e}&/${t}&l`)(`b%c`,`b%c`),rf),Gf=L(36,e=>Wf(e,+!e._._._.x),e=>e._._._,`q18`),Kf=z(14,Bf),qf=(e,t)=>Kf(e,H(t)),Jf=B(mf,df),Yf=z(15,e=>{Jf(e),sf(e)}),Xf=(e,t)=>Yf(e,!!t),Zf=M(3,`<div><!><!></div>`,` D%b%`,Ef,kf),Qf=(e,t)=>{qf(e,t?.files?.length),Xf(e,t?.state?.unpushed),ep(e,t?.state?.edits),np(e,t?.label),ip(e,t?.compare),Zf(e,[Zd(t),`dir`])},$f=(e,t)=>Qf(e,t[0]),ep=z(13,e=>{zf(e),of(e)}),tp=B(cf),np=z(11,e=>{Rf(e),tp(e),nf(e)}),rp=B(ff,uf),ip=z(12,e=>{rp(e),af(e)}),ap=en(1),op=L(30,e=>ap(e,e._._._.p),e=>e._._._,`q4`),sp=k(5,`<div><!></div>`,` D%`,e=>{op(e),I(e.a,`_ol`)}),cp=L(30,e=>sp(e,+!e._._.p),e=>e._._,`q20`),lp=D(`q19`,e=>F(e.d,`click`,function(){xp(e._._,!1)})),up=e=>{cp(e),dp(e),fp(e),mp(e),gp(e),I(e.a,`_n7`),I(e.b,`_n5`),I(e.c,`_4`),I(e.d,[kt,`_n4`]),fr(e.e),ln(e.e,16),Tn(e.e),I(e.g,`_n8`),ll(e.j,Xp(e)),Fl(e.k,Yp(e)),lp(e)},dp=L(32,e=>cl(e.j,e._._.s||[]),e=>e._._,`q21`),fp=L(38,e=>Pl(e.k,e._._.a0),e=>e._._,`q22`),pp=M(7,`<div><!><!><!></div>`,` D%b%b%`,Uf,$f),mp=L(39,e=>pp(e,[e._._.a1,`id`]),e=>e._._,`q23`),hp=k(8,`<p>No files match.</p>`,` `,Qd),gp=L(41,e=>hp(e,+!!e._._.a3),e=>e._._,`q24`),_p=k(0,((e,t,n)=>`<div><strong>File tree</strong><span></span><button type=button title=Close aria-label=Close>${e}</button></div><!><div><!><!></div>${t}${n}<!>`)(En,$c,ul),((e,t,n)=>` D b b D/${e}&m%b D%b%l/${t}&/${n}&b`)(fn,`b%c`,`b%c`),up),vp=L(33,e=>_p(e,+!e._.t),0,`q25`),yp=Wt(`q26`,`<!><!><!>`,`b%`,vp),bp=B(vp),xp=tn(19,e=>{gi(e.a,e.t),bp(e)}),Sp=O(5,e=>xp(e,e.d,e.e)),Cp=z(3,Sp),wp=z(4,Sp),Tp=z(21,B(gf)),Ep=(e,t)=>Tp(e,t||new Set),Dp=z(22,B(bf)),Op=(e,t)=>Dp(e,t||new Map),kp=z(25,B(Ff)),Ap=z(26,B(fp)),jp=z(27,B(mp)),Mp=O(24,e=>{kp(e,(()=>{let t=new Set,n=new Set;for(let r of e.i){if(e.x&&e.k.has(r.id))continue;let i=r.compare?.topic||r.compare?.head;t.has(r.label)&&i&&n.add(r.id),t.add(r.label)}return n})()),Ap(e,e.x?e.i.filter(t=>e.k.has(t.id)):[]),jp(e,e.x?e.i.filter(t=>!e.k.has(t.id)):e.i)},2),Np=B(Gf),Pp=z(23,e=>{Mp(e),Np(e)}),Fp=(e,t)=>Pp(e,t>1),Ip=z(29,B(gp)),Lp=z(8,e=>{Fp(e,e.i?.length),Ip(e,e.i.reduce((e,t)=>e+t.files.length,0)),Mp(e)}),Rp=z(10,Mp),zp=z(28,B(xf)),Bp=O(14,e=>zp(e,Zp(e)),2),Vp=z(11,Bp),Hp=z(12,Bp),Up=z(13,Bp);function Wp(e){mi(e.a),Si(e.a,yp(e)),pi(e.a,`File tree`),di(e.a,`_n6`),Ci(e.a,Qp(e)),xi(e.a,!0),hi(e.a),vi(e.a),fi(e.a),_i(e.a),bi(e.a,{})}var Gp=z(15,B(cp,op)),Kp=z(16),qp=z(17,B(Hf,jf)),Jp=z(18,B(dp)),Yp=e=>function(t){e._._.q(t)},Xp=e=>function(){xp(e._._,!1)},Zp=e=>t=>Jr({workspaceId:e.l,view:`diff`,scope:e.m??null,rev:e.n??null,file:t}),Qp=e=>t=>{xp(e,t)};P.q3=Yp,P.q2=Xp,P.q0=Zp,P.q1=Qp;var $p=`b%c`,em=`<!><!><!>`,tm=((e,t,n,r,i,a,o)=>`<div><div><div><div><span data-progress aria-hidden=true></span><!><div>${e}</div><div><!><span><button aria-label=Compare>${t}</button><select aria-label=Compare tabindex=-1><!><!></select></span> <div>${n}</div><!></div><!><span>${r}</span></div><div><!><!><!></div></div><div><div data-diff-main></div><!></div></div>${i}${a}${o}</div>`)(at,eo,vo,Ae,Il,$e,Yd),nm=((e,t,n,r,i,a,o)=>` D D D D b%b D/${e}&l D%b D D/${t}&l D%b%mb D0${n}&l%l%b D/${r}&m D%b%b%m D b%m/${i}&/${a}&/${o}&l`)(pt,to,yo,yt,Ll,_t,Xd),rm=new Set,im=4e3,am=new Set([`ArrowDown`,`ArrowUp`,`PageDown`,`PageUp`,` `,`Home`,`End`]),om=900,sm={committed:`Committed`,working:`Working tree`,dirty:`Uncommitted`};function cm(e){return e.slice(0,e.indexOf(`/`))}var lm=e=>{Qh._(e.a,e._)},um=(e,t)=>eg(e.a,t),dm=Wt(`W83`,(e=>`<!>${e}<!>`)(em),(e=>`b/${e}&b`)($p),lm,(e,t)=>um(e,(t?.[0]).id)),fm=e=>{Qh._(e.a,e._)},pm=(e,t)=>eg(e.a,t),mm=Wt(`W73`,(e=>`<!>${e}<!>`)(em),(e=>`b/${e}&b`)($p),fm,(e,t)=>pm(e,(t?.[0]).id)),hm=Jt(0,`<div><div></div><div></div></div>`,` D b `,e=>{I(e.a,`_jy`),I(e.b,[`_jx`,`_jz`]),I(e.c,[`_jx`,`_jA`])}),gm=e=>{I(e.a,[`_jv`,`_jw`]),hm(e,[2,0,1])},_m=Wt(`W64`,`Committed changes can't be shown.`),vm=e=>{dr(e.a),Un(e.a,_m(e)),Gn(e.a,`warn`),Wn(e.a,`inline`),Bn(e.a),Zn(e.a),Nn(e.a),tr(e.a,{})},ym=O(5,e=>In(e.a,`${e.d}: base ${e.e} not found`)),bm=z(3,ym),xm=z(4,ym),Sm=(e,t)=>{bm(e,t[0]?.worktree),xm(e,t[0]?.base)},Cm=e=>I(e.a,[`_hT`,`_jn`,`_jo`]),wm=e=>R(e.a,`value`,`rev:${e.M}`),Tm=(e,t)=>A(e.b,t),Em=(e,t)=>Tm(e,t[0]?.label),Dm=e=>R(e.a,`value`,e.M),Om=(e,t)=>A(e.b,t),km=(e,t)=>Om(e,t[1]),Am=e=>{Za(e.a),Qa(e.a,14),$a(e.a)},jm=e=>{Ka(e.a),qa(e.a,14),Ja(e.a)},Mm=O(3,e=>A(e.b,et(e._.e4.get(e._.eb).repo.edits))),Nm=j(26,2,Mm),Pm=D(`W65`,e=>F(e.c,`click`,function(){e._.fa(`working`)})),Fm=e=>{Nm._(e),Im._(e),I(e.a,`_dQ`),I(e.c,`_I`),Pm(e)},Im=j(26,2,Mm),Lm=M(0,`<option> </option>`,` D `,wm,Em),Rm=j(15,0,e=>Lm(e,[e._.dv,`sha`])),zm=Rm,Bm=j(20,0,e=>ce(e.a,e._.do)),Vm=e=>{Bm._(e),Hm._(e),Um._(e),Wm._(e),de(e.a),Ze(e.a,[`_hT`,`_jn`])},Hm=j(20,0,e=>oe(e.a,e._.e5)),Um=j(20,0,e=>n(e.a,e._.eb)),Wm=j(20,0,e=>Ye(e.a,e._.er)),Gm=O(2,e=>A(e.b,e._.cw.length?e._.c6?`This commit is not in any of these repos.`:e._.cw.some(e=>e.unborn)?`No commits yet.`:e._.c1===`dirty`?`Nothing uncommitted.`:e._.cw.some(e=>e.pr)?`No file changes on these PRs.`:`No changes vs base.`:`This workspace has no repos to review.`),2),Km=j(26,0,Gm),qm=e=>{Km._(e),Jm._(e),Ym._(e),I(e.a,`_dQ`)},Jm=j(26,0,Gm),Ym=j(26,0,Gm),Xm=D(`W58`,e=>F(e.a,`click`,function(){e._.f3(e._.c1)})),Zm=e=>{I(e.a,At),ci(e.b),si(e.b,12),li(e.b),Xm(e)},Qm=L(282,e=>m(e.a,e._.br),0,`W74`),$m=t=>{Qm(t),eh(t),th(t),nh(t),rh(t),ih(t),ah(t),oh(t),sh(t),ch(t),e(t.a)},eh=L(283,e=>ie(e.a,e._.bt)),th=L(284,e=>ct(e.a,e._.bu),0,`W75`),nh=L(285,e=>re(e.a,e._.bv)),rh=L(299,e=>Oe(e.a,e._.gr),0,`W76`),ih=L(300,e=>we(e.a,e._.gs),0,`W77`),ah=L(301,e=>Ee(e.a,e._.gt),0,`W78`),oh=L(302,e=>pe(e.a,e._.gu),0,`W79`),sh=L(303,e=>ye(e.a,e._.gv),0,`W80`),ch=L(304,e=>Ce(e.a,e._.gw),0,`W81`),lh=Wt(`W82`,Ve,(e=>`/${e}&`)(gt),$m),uh=O(3,e=>A(e.b,e._.bu&&!e._.br?`Every file here is viewed.`:`Nothing here matches: ${e.c} in the other sections.`),2),dh=j(26,3,uh),fh=e=>{dh._(e),ph._(e),hh._(e),I(e.a,`_dQ`)},ph=j(26,3,uh),mh=z(2,uh),hh=j(26,3,e=>mh(e,e._.do===1?`1 file does`:`${H(e._.do)} files do`)),gh=O(2,e=>A(e.b,e._.bu&&!e._.br?`Every file is viewed.`:`No files match "${e._.br}".`)),_h=j(26,1,gh),vh=e=>{_h._(e),yh._(e),I(e.a,`_dQ`)},yh=j(26,1,gh),bh=L(280,e=>A(e.a,e._._.bl),e=>e._._,`W62`),xh=Wt(`W63`,` `,` `,bh),Sh=e=>{dr(e.a),Un(e.a,xh(e)),Nn(e.a,Kb(e)),Bn(e.a),Zn(e.a),Gn(e.a),Wn(e.a),In(e.a),tr(e.a,{})},Ch=j(19,0,e=>R(e.a,`title`,`Find in review${Zr(`find`,e._.b9)}`)),wh=D(`W61`,e=>F(e.a,`click`,function(){e._.gn()})),Th=e=>{Ch._(e),Eh._(e),I(e.a,Ft),rr(e.b),Qn(e.b,14),or(e.b),wh(e)},Eh=j(19,0,e=>R(e.a,`hidden`,e._.cb)),Dh=O(4,e=>R(e.b,`title`,e.d+Zr(e._.g8?`expandAllFiles`:`collapseAllFiles`,e._.b9)),2),Oh=j(9,0,Dh),kh=D(`W59`,e=>F(e.b,`click`,function(){e._.g7(!e._.g8)})),Ah=e=>{Oh._(e),Mh._(e),Nh._(e),Ph._(e),Fh._(e),Rh._(e),zh._(e),i(e.a),I(e.b,Lt),kh(e)},jh=O(2,e=>Dt(e.a,{...e._.ga,filter:e._.br,filterChange:e._.bt,hideViewed:e._.bu,hideViewedChange:e._.bv,sheet:qb(e)}),4),Mh=j(9,0,jh),Nh=j(9,0,jh),Ph=j(9,0,jh),Fh=j(9,0,jh),Ih=z(3,e=>{R(e.b,`aria-label`,e.d),Dh(e)}),Lh=k(1,Wa,(e=>`/${e}&`)(Ga),jm,Ya,(e=>`/${e}&`)(Xa),Am),Rh=j(9,0,e=>{Ih(e,e._.g8?`Expand every file`:`Collapse every file`),Lh(e,+!e._.g8),Dh(e)}),zh=j(9,0,jh),Bh=L(277,e=>gc(e.a,e._._.ar||``),e=>e._._,`W67`),Vh=e=>{Bh(e),Hh(e),Uh(e),Gh(e),Kh._(e),qh._(e),bc(e.a,Jb(e))},Hh=L(278,e=>_c(e.a,e._._.as||``),e=>e._._,`W68`),Uh=L(281,e=>yc(e.a,e._._.bm),e=>e._._,`W69`),Wh=O(1,e=>vc(e.a,e._._.dt.has(e._.d))),Gh=L(291,Wh,e=>e._._,`W70`),Kh=j(0,0,Wh),qh=j(0,0,e=>pc(e.a,e._.g)),Jh=k(0,(e=>`<!>${e}<!>`)(ts),(e=>`b/${e}&b`)(`b%c`),Vh),Yh=(e,t)=>{$h(e,t?.repo),Jh(e,+!t)},Xh=O(4,e=>Yh(e,e._.e4.get(e.d))),Zh=L(293,Xh,0,`W72`),Qh=$t(Zh),$h=z(6,qh),eg=z(3,e=>{Xh(e),Kh(e)}),tg=D(`W66`,e=>F(e.b,`click`,function(){Oy(e._,new Set),bn(e._.a9)})),ng=e=>{I(e.a,`_dQ`),I(e.b,`_I`),tg(e)},rg=Ut(`W56`,16),ig=Ut(`W57`,268),ag=N(71,e=>{Oh(e),Ch(e)}),og=B(Gh),sg=z(163,e=>{Rd(e.a4,e.dt),og(e)}),cg=k(26,`<p> </p>`,` D `,qm,`<p> </p>`,` D `,vh,`<div><span>No commits yet: <!>.</span><button>Show uncommitted</button></div>`,` Eb%l `,Fm,`<p> </p>`,` D `,fh,`<div><span>Every section is folded.</span><button>Unfold all</button></div>`,` Db `,ng),lg=O(228,e=>cg(e,e.ba&&!e.d3?0:e.ba&&!e.do?1:e.ba&&e.c1===`committed`&&!e.c6&&e.e4.get(e.eb||``)?.repo.edits&&!e.fl?2:e.ba&&e.eb&&!e.fl?3:e.ba&&!e.fl?4:5),7),ug=B(Zh),dg=z(174,e=>{lg(e),ug(e),Nm(e)}),fg=z(252,e=>{jb(e,e.ga?.total),Mb(e,e.ga?.shown),Nb(e,e.ga?.onDone),Pb(e,e.ga?.viewed),Fb(e,e.ga?.additions),Ib(e,e.ga?.deletions),zh(e)}),pg=O(236,e=>fg(e,(()=>{let t=0,n=0;for(let r of e.ej)t+=r.additions,n+=r.deletions;return{shown:e.ft,total:e.fp?.length,viewed:e.d8?e.fp.filter(t=>e.da.get(t.key)===`viewed`).length:void 0,additions:t,deletions:n}})()),4),mg=z(189,e=>{Lp(e.a6,e.ej),_b(e,e.ej?.[0]?.id),pg(e)}),hg=O(183,e=>mg(e,e.eb?e.e2.filter(t=>t.id===e.eb):e.e2)),gg=z(172,e=>{Sd(e.a4,e.e2),hb(e,e.e2?.length),dg(e,new Map(e.e2.map(e=>[e.id,e]))),hg(e)}),_g=(e,t)=>Kd(e.a4,t),vg=O(184,e=>_g(e,(()=>{let t=e.eb&&e.e5.find(t=>t.id===e.eb),n=t&&t.repo.stack?.bottom;if(!t||!n)return null;let r=e=>e.compare?.topic||e.compare?.head||e.repo.worktree,i=e.e5.filter(e=>e.repo.worktree===t.repo.worktree&&e.repo.stack?.bottom===n).map(e=>({id:e.id,name:r(e),state:e.repo}));return i.length<2?null:{name:i.at(-1).name,layers:i}})())),yg=D(`W89`,e=>{e.aj&&window.addEventListener(`keydown`,t=>{let n=V(t,`prevSection`)?-1:+!!V(t,`nextSection`);if(n&&e.e5?.length>1){t.preventDefault();let r=[null,...e.e5.map(e=>e.id)],i=r.indexOf(e.eb);e.er(r[(i+n+r.length)%r.length]);return}let r=V(t,`nextFile`)?1:V(t,`prevFile`)?-1:0;if(r){t.preventDefault(),e.g9(r);return}if(V(t,`foldFile`)){let n=e.cq?.atTop()?.key??e.fo;n&&(t.preventDefault(),e.cq?.holdAnchor(),e.g2(n,!e.fv.has(n)));return}if(V(t,`toggleViewed`)){let n=e.cq?.atTop()?.key??e.fo;n&&e.d8&&(t.preventDefault(),e.cq?.holdAnchor(),e.g4(n));return}let i=V(t,`collapseAllFiles`)?!0:!V(t,`expandAllFiles`)&&null;if(i!==null){if(ni(t))return;t.preventDefault(),e.g7(i);return}if(V(t,`openInFiles`)){let n=e.cq?.pointerKey()??va(e.cs)?.key??e.fr;n&&(t.preventDefault(),t.stopPropagation(),e.gh(n));return}if(V(t,`goToFile`)){t.preventDefault(),t.stopPropagation(),e.dj();return}V(t,`find`)&&(t.target instanceof HTMLTextAreaElement||(t.preventDefault(),e.gn()))},{capture:!0,signal:Yt(e,2)})}),K=O(266,e=>{Qt(e,2),yg(e)},16),bg=z(175,e=>{gb(e,e.e5?.length),vg(e),K(e),Hm(e)}),xg=(e,t)=>{gg(e,t.filter(e=>e.files.length||!e.total&&(e.repo.pr||e.repo.edits))),bg(e,t.filter(e=>vt(e.repo)))},Sg=O(170,e=>xg(e,e.cz.map(t=>{let n=e.dm.filter(e=>e.repo===t.id),r=0,i=0;for(let e of n)r+=e.additions||0,i+=e.deletions||0;return{...Ue(t,e.ar||``,e.as||``,e.dz),label:t.worktree,state:t,files:n,additions:r,deletions:i,total:t.files.length}})),4),Cg=z(169,Sg),wg=M(25,_r,(e=>`/${e}&`)(hr),vm,Sm),Tg=D(`W84`,e=>Bt(e,{active:e.aj,pageActive:e.b6??e.aj,load:e.f3,shownFiles:e.fh,commentsByFile:e.dp,draft:e.bh,sessions:e.b5,collapsedFiles:e.fv,repos:e.ba,markRead:e.g5,foldRead:e.g6,onMount:function(){let t=new AbortController,n=()=>e.b5||[],i=new Map,a=(t,n)=>le(e.a2,t,n),o=new WeakMap,s=async(t,n,r)=>{if(!r)return``;let i=new URLSearchParams({worktree:t,path:n,rev:r});return(await kn(`/api/workspaces/${e.a9}/diff/contents?${i}`)).contents},c={viewer:null},l={key:null,top:null},u={key:null,off:0},f=new Map,m,h={draft:!0},ee,te=e=>{let t=f.get(e.id);return(!t||t.comment.text!==e.text)&&(t={comment:e}),f.set(e.id,t),t},g=e=>(m!==e&&(m=e,h={draft:!0},ee=void 0),h),ne=(e,t,n)=>{let r=[];for(let e of t)r.push({side:e.side===`file`?`additions`:e.side,lineNumber:e.line_end,metadata:te(e)});return n&&n.key===e&&r.push({side:n.side===`deletions`?`deletions`:`additions`,lineNumber:n.end,metadata:g(n)}),r},re=(e,t,n,r)=>{let i=r?[r]:[];for(let e of t)i.push({lineNumber:0,metadata:te(e)});return n&&n.key===e&&i.push({lineNumber:0,metadata:g(n)}),i.length?i:void 0},_=(e,t,n)=>e.map(e=>`${e.id}:${e.text}`).join(`,`)+(t&&t.key===n?`|d${t.side}${t.start}-${t.end}`:``),ie=new Map,ae=new WeakMap,v=(e,t=``)=>t===`worktree`&&e.repo.includes(`@`)?e.repo:e.worktree,oe=(t,n,r,i)=>{let a=new URLSearchParams({worktree:t,path:n,rev:r});return i&&a.set(`v`,i),`/api/workspaces/${e.a9}/diff/blob?${a}`},ce=(e,t)=>{let n=e.binary?st(e.path)?.kind:void 0;if(!n||!t)return;let r={worktree:p(e.repo),repo:e.repo},i=e.status===`A`,a=e.status===`D`,o=[];if(!i&&t.oldRev&&o.push({label:a?`Deleted`:`Before`,src:oe(v(r,t.oldRev),e.oldPath||e.path,t.oldRev)}),!a&&t.newRev&&o.push({label:i?`Added`:`After`,src:oe(v(r,t.newRev),e.path,t.newRev,e.hash)}),!o.length)return;let s=o.map(e=>e.src).join(` `),c=ie.get(e.key);return(!c||c.sig!==s)&&(c={sig:s,meta:{preview:{kind:n,name:e.path,sides:o}}},ie.set(e.key,c)),{lineNumber:0,metadata:c.meta}},ue=t=>{Ov(e,{key:t,side:`additions`,start:0,end:0})},de=(t,n)=>{if(!t)return;let r=t.endSide!=null&&t.endSide!==t.side;Ov(e,{key:n,side:t.side||`additions`,start:Math.min(t.start,r?t.start:t.end),end:Math.max(t.start,r?t.start:t.end)})},pe=(e,t,n)=>!!w.recs.get(e)?.fileDiff?.hunks.some(e=>n===`additions`?t>=e.additionStart&&t<e.additionStart+e.additionCount:t>=e.deletionStart&&t<e.deletionStart+e.deletionCount),b=t=>{let n=e.d6(t.itemId),r=n&&(e.ba||[]).find(e=>e.id===n.repo);if(!n||!r||n.binary)return null;let i=t.side===`deletions`,a=i?r.oldRev:r.newRev;return a?{worktree:p(n.repo),path:i&&n.oldPath||n.path,rev:a}:null},x=Ii(),he=(t,n)=>{let r=n.side||`additions`;if(t.same&&pe(n.itemId,t.line,r))return{key:n.itemId,side:r};let i=`${t.worktree}/${t.path}`,a=e.d1.find(n=>n.label===i&&(e.ba||[]).find(e=>e.id===n.repo)?.newRev===`worktree`&&pe(n.key,t.line,`additions`));return a?{key:a.key,side:`additions`}:null},_e=De({workspaceId:()=>e.a9,source:b,problems:(e,t,n,r)=>e.side===`deletions`?[]:lt(x.byKey.get(e.itemId),t,n,r),open:(t,n)=>{e.eq();let r=he(t,n);if(!r){e.b2?.(`${t.worktree}/${t.path}`,t.line);return}if(r.key===n.itemId){Me(r.key,t.line,r.side);return}e.eu(r.key),setTimeout(()=>Me(r.key,t.line,r.side),0)},inView:(e,t)=>!!he(e,t)}),ye={theme:me,themeType:Jn(),onTokenEnter:_e.onTokenEnter,onTokenLeave:_e.onTokenLeave,onTokenClick:_e.onTokenClick,diffStyle:On()===`auto`?un()?`unified`:`split`:On(),stickyHeaders:!0,itemMetrics:{diffHeaderHeight:44},enableLineSelection:!0,layout:{paddingTop:0,paddingBottom:24,gap:12},unsafeCSS:` @media (pointer: coarse) { pre[data-diff] { touch-action: pan-x pan-y; } }`+je+Se,async loadDiffFiles(t){let n=o.get(t),r=(e.ba||[]).find(e=>e.id===n?.repo);if(!n||!r)throw Error(`unknown file`);let[i,a]=await Promise.all([s(v(n,r.oldRev),t.prevName||n.path,r.oldRev),s(v(n,r.newRev),n.path,r.newRev)]);if(i==null||a==null)throw $(e,`Expand failed: ${n.path} is too large or unreadable`),Error(`diff contents unavailable`);if(!$i(t,`deletions`,i)||!$i(t,`additions`,a))throw $(e,`${n.path} changed since the diff was taken; reloading it`),e.f3(e.c1),Error(`diff contents out of date`);return{oldFile:{name:t.prevName||t.name,contents:i},newFile:{name:t.name,contents:a}}},renderCustomHeader(t,n){let r=n.item,i=e.d6(r.id),a={label:i?.label??r.id,status:i?.status||(r.type===`diff`?r.fileDiff.type[0].toUpperCase():`M`),collapsed:!!r.collapsed,viewed:e.d8&&i?.fp?e.da.get(r.id)??`unviewed`:null,notes:i&&e.dp.get(i.label)?.length||0,errors:x.byKey.get(r.id)?.length??0,additions:i?.additions,deletions:i?.deletions,patchless:r.type===`file`,open:i?.status===`D`?null:`Open in Files${Zr(`openInFiles`,ei())}`},o=ka(a),s=Ce.get(r.id);if(s?.sig===o)return s.el;let u=Ma(a,{fold:t=>{let n=!e.fv.has(r.id);if(t){e.g7(n);return}l.key=r.id,l.top=c.viewer?.getTopForItem(r.id)??null,e.g2(r.id,n)},comment:()=>{e.g2(r.id,!1),ue(r.id)},open:()=>e.gh(r.id),view:()=>{l.key=r.id,l.top=c.viewer?.getTopForItem(r.id)??null,e.g4(r.id)},errors:()=>{e.g2(r.id,!1),setTimeout(()=>{let e=x.byKey.get(r.id)?.[0];e&&Me(r.id,e.line,`additions`)},0)}});return Ce.set(r.id,{sig:o,el:u}),u},renderAnnotation(t,r){let o=t.metadata||{},s=r.item.id;if(o.preview){let e=ae.get(o);return e||ae.set(o,e=ca(o.preview)),e}if(o.draft)return ee??=se({sessions:n,reveal:a},{onSave:t=>e.gk(s,t),onSend:(t,n)=>e.gl(s,t,n),onCancel:()=>{Ov(e,null)}});let c=o.comment;if(!c)return;let l=r.item.type===`diff`?r.item.fileDiff:null,u=c.snippet!=null&&!!l&&y(ta(l,c.side===`file`?`additions`:c.side,c.line_start,c.line_end))!==y(c.snippet),f=`${c.id}:${+!!u}:${c.text}`,p=i.get(f);return p||(p=Xe(c,{sessions:n,reveal:a},{onDelete:t=>ve(e.f9,t),onEdit:(t,n)=>ge(e.f9,t,n),onSend:(t,n)=>d(e.f9,t,n),drifted:u}),i.set(f,p)),p},onLineSelectionEnd(e,t){t.item.type===`file`?ue(t.item.id):de(e,t.item.id)},onPostRender(e,t,n,r){let i=e;if(n===`unmount`){be.get(i)?.(),be.delete(i),xe.delete(i),Hi(x,i);return}xe.set(i,r.item.id),be.has(i)?bt(i):be.set(i,Et(i,r.item.id)),Vi(x,i,r.item.id)}},be=new Map,xe=new Map,Ce=new Map,S=new Be(ye,ke());c.viewer=S,S.setup(e.a2);let we=xn(e=>{ye.themeType=e,S.setOptions({...ye})});mr()&&na(()=>e.a2,t.signal);let Ee=()=>{let t=e.a2.clientWidth;if(!t)return;let n=On(),r=n===`auto`?t<om?`unified`:`split`:n;r!==ye.diffStyle&&(ye.diffStyle=r,S.setOptions({...ye}))},Oe=new ResizeObserver(Ee);Oe.observe(e.a2),t.signal.addEventListener(`abort`,()=>Oe.disconnect()),sr(`diff-layout`,Ee,t.signal);let Ae=t=>{w.recs.has(t)&&(wa(e.cs),S.scrollTo({type:`item`,id:t,align:`start`,behavior:`instant`}))},Me=(t,n,r)=>{if(!w.recs.has(t)||w.unlaid.has(t)){Ta(e.cs,{key:t,line:n,side:r});return}Ta(e.cs,null),S.scrollTo({type:`line`,id:t,lineNumber:n,side:r||`additions`,align:`center`,behavior:`instant`})},Ne=null,Pe=e=>{let t=e.closest(`[data-code]`);return t?.hasAttribute(`data-deletions`)?!1:t?.hasAttribute(`data-additions`)?!0:!(e.getAttribute(`data-line-type`)||``).includes(`deletion`)};e.a2.addEventListener(`pointermove`,e=>{Ne=null;let t=0;for(let n of e.composedPath()){if(!(n instanceof HTMLElement))continue;!t&&n.hasAttribute(`data-line`)&&Pe(n)&&(t=Number(n.getAttribute(`data-line`))||0);let e=xe.get(n);if(e){t&&(Ne={key:e,line:t});break}}},{passive:!0,signal:t.signal}),e.a2.addEventListener(`pointerleave`,()=>{Ne=null},{signal:t.signal});let Fe=e=>{let t=w.recs.get(e)?.fileDiff?.hunks[0];if(!t)return 0;let n=t.additionStart;for(let e of t.hunkContent){if(e.type===`change`)return n;n+=e.lines}return t.additionStart},Ie=(t,n=!0)=>{if(n&&Ne?.key===t)return Ne.line;let r=e.a2.getBoundingClientRect(),i=r.top+44,a=r.bottom;for(let[e,n]of xe){if(n!==t||!e.shadowRoot)continue;let r=0;for(let t of e.shadowRoot.querySelectorAll(`[data-code] [data-line]`)){if(!Pe(t))continue;let e=t.getBoundingClientRect();if(e.bottom<=i)continue;if(e.top>=a)break;let n=Number(t.getAttribute(`data-line`))||0;if(t.getAttribute(`data-line-type`)===`change-addition`)return n;r||=n}if(r)return r}return Fe(t)},Le=(e,t)=>{let n=0,r=1/0;for(let i of w.recs.get(e)?.fileDiff?.hunks??[]){if(!i.additionCount)continue;let e=Math.min(i.additionStart+i.additionCount-1,Math.max(i.additionStart,t));Math.abs(e-t)<r&&(r=Math.abs(e-t),n=e)}Me(e,n||t,`additions`)},Re=()=>{let e=S.getScrollTop(),t=null,n=-1;for(let r of S.getRenderedItems()){let i=S.getTopForItem(r.id);i==null||i>e+1||i<=n||(t=r.id,n=i)}return t?{key:t,off:Math.round(e-n)}:null},ze=()=>{let e=Re();u.key=e?.key??null,u.off=e?.off??0},Ve=()=>{let t=e.a2.getBoundingClientRect(),n=(t.top+44+t.bottom)/2,r=null;for(let[e,i]of xe)for(let a of e.shadowRoot?.querySelectorAll(`[data-code] [data-line]`)??[]){if(!Pe(a))continue;let e=a.getBoundingClientRect();if(e.bottom<=t.top||e.top>=t.bottom)continue;let o=Math.abs((e.top+e.bottom)/2-n),s=Number(a.getAttribute(`data-line`))||0;s&&(!r||o<r.dist)&&(r={key:i,line:s,dist:o})}return r},He={timer:0,sig:``},Ue=()=>{He.timer||=setTimeout(()=>{if(He.timer=0,!this.active)return;let t=Ve(),n=t?.key??Re()?.key,r=n?e.gf(n):null,i=r&&{...r,line:t?.line??Ie(n,!1)},a=i?`${i.key}|${i.line}|${i.section}`:``;a!==He.sig&&(He.sig=a,Vy(e,i))},200)};t.signal.addEventListener(`abort`,()=>clearTimeout(He.timer)),ry(e,{scrollToItem:Ae,scrollToLine:Me,lineIn:Ie,scrollNear:Le,pointerKey:()=>Ne?.key??null,atTop:Re,holdAnchor:ze});let We={timer:0},Ge=()=>{We.timer||=setTimeout(()=>{if(We.timer=0,!this.active||!w.loaded)return;let t=this.shownFiles||[],n=S.getRenderedItems()[0]?.id,r=Math.max(0,t.findIndex(e=>e.key===n)),i=t.slice(r,r+12).map(e=>b({itemId:e.key})).filter(e=>!!e);Te(e.a9,i)},1e3)},Ke={workspaceId:()=>e.a9,live:()=>!!this.active&&w.loaded,shown:()=>this.shownFiles||[],onScreen:()=>S.getRenderedItems().map(e=>e.id),source:e=>b({itemId:e}),redraw:e=>{let t=w.recs.get(e);t&&(t.item.version=(t.item.version??0)+1,S.updateItem(t.item))}},qe=()=>Ri(x,Ke),Je=()=>zi(x,Ke);sr(`lsp`,qe,t.signal),sr(`lsp-off`,Je,t.signal),Ei(Je,t.signal);let C={top:0,touched:0,moved:0,keys:new Set,timer:0},Ye=()=>{C.touched=performance.now()},Ze=e.a2,Qe={passive:!0,signal:t.signal};Ze.addEventListener(`wheel`,Ye,Qe),Ze.addEventListener(`touchmove`,Ye,Qe),Ze.addEventListener(`pointerdown`,e=>{e.target===Ze&&e.offsetX>=Ze.clientWidth&&Ye()},Qe),document.addEventListener(`keydown`,e=>{am.has(e.key)&&!ni(e)&&Ye()},Qe);let $e=()=>{if(C.timer=0,!C.keys.size)return;let e=[...C.keys];C.keys.clear(),this.markRead(e)};t.signal.addEventListener(`abort`,()=>clearTimeout(C.timer));let et=()=>{let e=S.getScrollTop(),t=C.top;C.top=e;let n=performance.now();if(n-C.touched>1e3&&n-C.moved>150)return;C.moved=n;let r=S.getHeight();if(!this.active||e<=t||e-t>r)return;let i=e+r>=S.getScrollHeight()-2;for(let n of S.getRenderedItems()){let r=S.getTopForItem(n.id);if(r==null)continue;let a=r+n.element.offsetHeight;(a>t&&a<=e||i&&a>e)&&C.keys.add(n.id)}C.keys.size&&(clearTimeout(C.timer),C.timer=setTimeout($e,500))},tt=0,w={abort:t,viewer:S,intel:_e,warmSoon:Ge,warmBox:We,filesAtSoon:Ue,askProblems:qe,probBox:x,unregTheme:we,unsubScroll:S.subscribeToScroll(t=>{_e.close(),Ge(),Ue(),!tt&&(tt=requestAnimationFrame(()=>{tt=0,et();let n=null;for(let r of S.getRenderedItems()){let i=S.getTopForItem(r.id);i==null||i>t+1||(!n||i>(S.getTopForItem(n.key)??-1))&&(n={scope:e.c1,key:r.id,off:Math.round(t-i)})}t>0&&_a(e.cs,n),this.active&&Hr(e.a9,{view:`diff`,pos:n,pick:e.eb});let r=n?.key??S.getRenderedItems()[0]?.id,i=r&&e.d6(r)?.repo;i&&Zv(e,i)}))}),hostUnregs:be,loaded:!1,wasActive:!1,wasOnPage:!1,lastNonce:e.b7||0,lastFileNonce:e.b8||0,lastBack:e.av??null,backWait:null,urlScope:e.aa??null,recs:new Map,unlaid:new Set,order:``,revealedDraft:null,hadDraft:!1,itemsFrom:[],sessionsKey:fe(n()),redrawSends:()=>{for(let e of i.values())r(e);ee&&r(ee)},start:()=>{this.active&&!w.loaded&&(w.loaded=!0,this.load())},pin:e=>{w.viewer.scrollTo({type:`item`,id:e.key,align:`start`,offset:-e.off,behavior:`instant`})},sync:()=>{let t=[this.shownFiles,this.commentsByFile,this.draft,this.collapsedFiles,this.repos];if(t.some((e,t)=>e!==w.itemsFrom[t])&&(w.itemsFrom=t,w.reconcile()),u.key){let{key:e,off:t}=u;u.key=null,w.recs.has(e)&&w.viewer.scrollTo({type:`item`,id:e,align:`start`,offset:this.collapsedFiles.has(e)?0:-t,behavior:`instant`})}if(l.key){let{key:e,top:t}=l;l.key=null,t!=null&&t<w.viewer.getScrollTop()&&w.viewer.scrollTo({type:`item`,id:e,align:`start`,behavior:`instant`})}let n=this.draft;n&&n!==w.revealedDraft&&w.recs.has(n.key)&&(w.revealedDraft=n,w.viewer.scrollTo(n.end?{type:`line`,id:n.key,lineNumber:n.end,side:n.side===`deletions`?`deletions`:`additions`,align:`nearest`,offset:180,behavior:`smooth-auto`}:{type:`item`,id:n.key,align:`nearest`,behavior:`smooth-auto`}));let r=Ea(e.cs);r&&w.recs.has(r.key)&&(Sa(e.cs,null),w.pin(r));let i=Da(e.cs);i&&w.recs.has(i)&&Ae(i)},reconcile:()=>{let n=[],r=new Set,i=!1;for(let t of this.shownFiles){r.add(t.key);let a=w.recs.get(t.key),s=a&&a.patch===t.patch&&a.status===t.status?a.fileDiff:Yi(t,t.key,e.co),c=this.commentsByFile.get(t.label)||[],l=s?void 0:ce(t,(this.repos||[]).find(e=>e.id===t.repo)),u=_(c,this.draft,t.key)+(l?`|p${ie.get(t.key).sig}`:``),d=s?void 0:re(t.key,c,this.draft,l),f=this.collapsedFiles.has(t.key);s&&o.set(s,{worktree:p(t.repo),path:t.path,repo:t.repo});let m={name:t.path,contents:l?` `:t.binary?`(binary file)`:t.tooLarge?`(file too large to display)`:`(file could not be read)`},h=a;!h||h.item.type===`diff`!=!!s?(h={item:s?{id:t.key,type:`diff`,fileDiff:s,annotations:ne(t.key,c,this.draft),collapsed:f,version:(h?.item.version??0)+1}:{id:t.key,type:`file`,file:m,annotations:d,collapsed:f,version:(h?.item.version??0)+1},fileDiff:s,annSig:u,collapsed:f,patch:t.patch,status:t.status},w.recs.set(t.key,h),w.unlaid.add(t.key),i=!0):(h.fileDiff!==s||h.annSig!==u||h.collapsed!==f)&&(h.item.type===`diff`&&s?(h.item.fileDiff=s,h.item.annotations=ne(t.key,c,this.draft)):h.item.type===`file`&&(h.item.file.contents!==m.contents&&(h.item.file=m),h.item.annotations=d),h.item.collapsed=f,h.item.version=(h.item.version??0)+1,h.fileDiff=s,h.annSig=u,h.collapsed=f,h.patch=t.patch,h.status=t.status,i||w.viewer.updateItem(h.item)),n.push(h.item)}for(let e of[...w.recs.keys()])r.has(e)||(w.recs.delete(e),Ce.delete(e));let a=n.map(e=>e.id).join(`
15
+ `);(i||a!==w.order)&&(w.order=a,w.viewer.setItems(n)),w.unlaid.size&&requestAnimationFrame(()=>{if(t.signal.aborted)return;w.unlaid.clear();let n=Oa(e.cs);n&&w.recs.has(n.key)&&Me(n.key,n.line,n.side)})}};w.wasActive=!!this.active,w.wasOnPage=!!this.pageActive,pn().addEventListener(`review.changed`,t=>{w.loaded&&t.data?.workspaceId===e.a9&&e.f7()},{signal:t.signal});let nt=()=>n().some(e=>e.state?.phase===`working`),rt=async(t=!1)=>{if(this.active&&w.loaded&&!e.bm&&ga(e.cp)&&document.visibilityState===`visible`&&(e.bo!==`agent`||t||!nt()))try{let{stamp:n}=await kn(`/api/workspaces/${e.a9}/diff/stamp`);if(!this.active||e.bm)return;if(n===ga(e.cp)){e.bo===`agent`&&Fv(e,null);return}e.bh||document.activeElement instanceof HTMLTextAreaElement?Fv(e,`comment`):!t&&nt()?Fv(e,`agent`):e.f3(e.c1)}catch{}},it=setInterval(rt,im);t.signal.addEventListener(`abort`,()=>clearInterval(it));let at={working:-1},ot;t.signal.addEventListener(`abort`,()=>clearTimeout(ot)),pn().addEventListener(`diff.changed`,t=>{if(!this.active||t.data?.workspaceId!==e.a9)return;clearTimeout(ot);let n=()=>{e.bm?ot=setTimeout(n,150):e.f3(e.c1)};ot=setTimeout(n,150)},{signal:t.signal});let ct;return t.signal.addEventListener(`abort`,()=>clearTimeout(ct)),pn().addEventListener(`status.changed`,t=>{if(!this.active||!w.loaded||e.bm)return;let n=t.data,r=n&&n[e.a9];if(!r)return;r.working<at.working&&rt(!0),at.working=r.working;let i=Gi(r),a=e.ba?Wi(e.ba):``;i&&a&&i!==a&&(clearTimeout(ct),ct=setTimeout(()=>{this.active&&!e.bm&&e.f3(e.c1,!0)},400))},{signal:t.signal}),window.addEventListener(`pagehide`,()=>{this.active&&w.loaded&&e.cv()},{signal:t.signal}),document.addEventListener(`visibilitychange`,()=>{document.visibilityState===`hidden`&&this.active&&w.loaded&&e.cv()},{signal:t.signal}),w.start(),w},onUpdate:function(){this.start(),this.active&&this.loaded&&!this.wasActive&&e.f3(e.c1),this.active&&!this.wasActive&&this.foldRead(),!this.pageActive&&this.loaded&&this.wasOnPage&&e.cv(),this.wasActive=!!this.active,this.wasOnPage=!!this.pageActive;let t=fe(this.sessions||[]);t!==this.sessionsKey&&(this.sessionsKey=t,this.redrawSends());let n=e.b7||0,r=!1;this.loaded&&e.aw&&n!==this.lastNonce&&(e.ez(e.aw),r=!0),this.lastNonce=n;let i=e.b8||0;this.loaded&&e.ax&&i!==this.lastFileNonce?(e.f1(e.ax),this.lastFileNonce=i,r=!0):this.loaded&&(this.lastFileNonce=i);let a=e.av??null;this.loaded&&a&&a!==this.lastBack&&(r=!0,a.pick===e.e8(this.repos||[])?(this.backWait=null,e.f0(a)):(this.backWait={pos:a.pos,from:e.eb,at:Date.now()},e.er(a.pick,!0))),this.loaded&&(this.lastBack=a);let o=this.backWait;o&&e.eb!==o.from&&(this.backWait=null,Date.now()-o.at<2e3&&xa(e.cs,o.pos));let s=e.aa??null;if(s!==this.urlScope){this.urlScope=s;let t=s??mn();t!==e.c1&&e.fa(t,!1,!!s)}e.ah!==void 0&&(e.ah??null)!==e.c6&&e.fb(e.ah??null),r&&ma(e.cp),!this.draft&&this.hadDraft&&this.viewer.clearSelectedLines(),this.hadDraft=!!this.draft,this.sync(),Bi(this.probBox,this.repos),this.active&&this.loaded&&(this.warmSoon(),this.askProblems(),this.filesAtSoon())},onDestroy:function(){this.loaded&&e.cv(),this.abort.abort(),this.warmBox.timer&&clearTimeout(this.warmBox.timer),Ui(this.probBox),this.intel.destroy(),this.unsubScroll(),this.unregTheme();for(let e of this.hostUnregs.values())e();this.viewer.cleanUp();let t=window;t.__INSTANCE===this.viewer&&(delete t.__INSTANCE,delete t.__TOGGLE)}},1)),q=O(264,Tg,50),Eg=z(246,e=>{K(e),q(e)}),J=O(243,e=>Eg(e,Yb(e)),9),Dg=z(247,q),Y=O(239,e=>Dg(e,Xb(e)),8),Og=z(259,e=>{K(e),q(e)}),kg=O(258,e=>Og(e,Zb(e)),6),Ag=z(257,e=>{kg(e),q(e)}),jg=O(141,e=>Ag(e,Qb(e)),2),Mg=z(262,q),Ng=z(263,q),Pg=O(261,e=>{Mg(e,$b(e)),Ng(e,ex(e))},3),Fg=z(140,e=>{J(e),Y(e),jg(e),Pg(e),q(e)}),Ig=z(139,e=>Fg(e,tx(e))),Lg=(e,t)=>Wo(e.r,t),Rg=O(186,e=>Lg(e,(e.eb?e.dm.filter(t=>t.repo===e.eb):e.dm).map(t=>({...t,fileDiff:Yi(t,t.key,e.co)}))),2),zg=O(220,e=>qt(e,`n`,e.c6?`rev:${e.c6}`:e.c1,nx(e)),2),Bg=z(219,zg),Vg=O(218,e=>Bg(e,rx(e)),5),Hg=z(216,e=>{Vg(e),q(e)}),Ug=O(210,e=>Hg(e,ix(e)),2),Wg=z(217,e=>{Vg(e),q(e)}),Gg=O(211,e=>Wg(e,ax(e)),3),Kg=D(`W85`,e=>Bt(e,{onMount:function(){let t=new AbortController;return sr(`diff-focus:${e.a9}`,()=>{let t=An(e.a9);t&&t!==e.cj&&(t!==`*`&&e.ba&&!x(e.ba,t)&&(Qv(e,!0),e.aj&&e.f3(e.c1)),e.er(t===`*`?null:t,!1,!0))},t.signal),sr(`diff-collapsed:${e.a9}`,()=>{let t=La(e.a9);Ha(t,e.ch)||(e.cq?.holdAnchor(),wy(e,t))},t.signal),{abort:t}},onDestroy:function(){this.abort.abort()}})),X=O(212,Kg,8),qg=z(209,e=>{Ug(e),Gg(e),Vg(e),X(e),q(e)}),Z=O(208,e=>qg(e,ox(e)),18),Jg=z(205,e=>{Z(e),q(e)}),Yg=O(203,e=>Jg(e,sx(e)),2),Xg=z(207,e=>{Z(e),q(e)}),Zg=O(202,e=>Xg(e,cx(e)),2),Qg=O(201,e=>Vd(e.a4,lx(e))),$g=O(204,e=>Je(e.a5,ux(e)),3),e_=z(200,e=>{Yg(e),Zg(e),Qg(e),$g(e),q(e)}),Q=O(199,e=>e_(e,dx(e)),8),t_=z(206,e=>{Z(e),q(e)}),n_=O(198,e=>t_(e,fx(e)),3),r_=z(197,e=>{Q(e),Yg(e),n_(e),K(e),X(e),q(e),Wm(e)}),i_=O(180,e=>r_(e,px(e)),5),a_=(e,t)=>Ab(e,t?.length),o_=O(226,e=>a_(e,e.eb?e.fh:e.dm),2),s_=z(267,e=>Do(e.r,mx(e))),c_=O(245,e=>s_(e,hx(e)),4),l_=z(244,e=>{c_(e),K(e),q(e)}),u_=O(241,e=>l_(e,gx(e)),3),d_=z(250,Rh),f_=O(238,e=>d_(e,e.fh?.length>0&&e.fh.every(t=>e.fv.has(t.key)))),p_=z(237,e=>{u_(e),Y(e),f_(e),K(e),q(e)}),m_=O(225,e=>p_(e,new Set(e.fh.filter(t=>za(e.ch,t.key,e.dc(t.key))).map(e=>e.key))),2),h_=z(249,e=>{K(e),q(e)}),g_=O(242,e=>h_(e,_x(e)),3),__=z(251,K),v_=O(224,e=>__(e,vx(e))),y_=z(223,e=>{Db(e,e.fh?.length),Ob(e,e.fh?.[0]?.key),o_(e),m_(e),g_(e),f_(e),v_(e),q(e)}),b_=O(222,e=>y_(e,e.eb?e.dm.filter(t=>t.repo===e.eb):e.dm.filter(t=>!e.ff.has(t.repo))),2),x_=(e,t)=>{Id(e.a4,t),Kp(e.a6,t)},S_=O(157,e=>x_(e,yx(e)),3),C_=z(156,e=>{cb(e,e.dm?.length),Sg(e),Rg(e),i_(e),b_(e),o_(e),S_(e)}),w_=O(147,e=>C_(e,(()=>{let t=Ge(e.br);return e.d1.filter(n=>t(n.label)&&(!e.bu||!e.dc(n.key)))})()),3),T_=z(146,e=>{w_(e),Q(e),m_(e),u_(e),g_(e)}),E_=O(145,e=>T_(e,bx(e))),D_=z(144,e=>{Bd(e.a4,e.da),Op(e.a6,e.da),E_(e),J(e),Y(e),pg(e),q(e)}),O_=O(143,e=>D_(e,(()=>{let t=new Map;if(!e.d8)return t;for(let n of e.d1){let r=e.by.get(n.key),i=r===void 0?n.viewed:r===null?void 0:r===n.fp?`viewed`:`changed`;i&&t.set(n.key,i)}return t})()),2),k_=(e,t)=>{Fd(e.a4,t),Jp(e.a6,t)},A_=O(136,e=>k_(e,(()=>{let t=new Set(e.d1.map(e=>e.label)),n=new Map;for(let r of e.bc){let e=`${p(r.worktree)}/${r.path}`;if(t.has(e))continue;let i=n.get(e);i?(i.count++,r.line_start&&(!i.line||r.line_start<i.line)&&(i.line=r.line_start)):n.set(e,{count:1,line:r.line_start})}return[...n].sort(([e],[t])=>e.localeCompare(t)).map(([t,n])=>({label:t,count:n.count,href:wr`${{search:{file:t,line:n.line||void 0}}}/w/${e.a9}/files`}))})()),2),j_=(e,t)=>Ep(e.a6,t),M_=(e,t)=>{zd(e.a4,t),j_(e,new Set(t.keys()))},N_=O(160,e=>M_(e,new Map(e.d1.flatMap(t=>{let n=e.dp.get(t.label)?.length;return n?[[t.key,n]]:[]})))),P_=z(231,e=>{kb(e,e.fp?.[0]?.key),pg(e)}),F_=O(182,e=>P_(e,e.eb?e.d1.filter(t=>t.repo===e.eb):e.d1)),I_=O(151,e=>ut(e.a5,e.df&&{label:`Other files and folders, in Files`,items:(()=>{let t=new Set(e.d1.map(e=>e.label));return[...e.df.filter(e=>!t.has(e)),...w(e.df)].map(e=>({key:e,path:e}))})()})),L_=z(135,e=>{mt(e.a5,e.d1.map(e=>({key:e.key,path:e.label,hint:e.repo.match(/@(.*)$/)?.[1]??e.repo.match(/#.*$/)?.[0]}))),ab(e,e.d1?.length),Ig(e,new Map(e.d1.map(e=>[e.key,e]))),O_(e),A_(e),w_(e),N_(e),F_(e),I_(e),q(e)}),R_=O(255,e=>R(e.l,`title`,`Compare: ${e.dy}\n${e.gc}`)),z_=z(254,R_),B_=O(134,e=>z_(e,e.cz.filter(e=>e.files.length||e.pr).map(t=>{let n=Cr(t.pr?.baseRefName||t.base,t.pr?.headRefName||t.headRef||t.branch,e.ar||``,e.as||``);return`${t.worktree}: ${n.title}`}).join(`
16
+ `)),2),V_=z(133,e=>{L_(e,e.cz.flatMap(e=>e.files.map(t=>({...t,repo:e.id,key:`${e.id}/${t.path}`,label:`${e.worktree}/${t.path}`})))),Sg(e),B_(e)}),H_=z(168,R_),U_=O(166,e=>H_(e,e.c6?e.dv.find(t=>t.sha===e.c6)?.label??a(e.c6,7):sm[e.c1]),2),W_=z(165,e=>{ub(e,e.dv?.length),U_(e),Rm(e)}),G_=O(131,e=>{V_(e,e.c6?e.cw.filter(e=>e.rev):e.cw),W_(e,(()=>{let t=new Set,n=[];for(let r of e.cw)for(let e of r.commits||[])t.has(e.sha)||(t.add(e.sha),n.push({sha:e.sha,label:`${r.worktree} · ${a(e.sha,7)} ${e.subject}`}));return e.c6&&!t.has(e.c6)&&n.unshift({sha:e.c6,label:a(e.c6,7)}),n})())}),K_=z(196,e=>{kg(e),Qg(e),$g(e),q(e)}),q_=O(195,e=>K_(e,xx(e))),J_=z(194,q_),Y_=O(187,e=>J_(e,Sx(e)),3),X_=z(221,e=>{Nd(e.a4,e.ff),Rp(e.a6,e.ff),b_(e),c_(e)}),Z_=O(185,e=>X_(e,!e.eb&&e.e3>1?e.cn:rm),2),Q_=z(181,e=>{yd(e.a4,e.eb),vg(e),hg(e),Rg(e),Y_(e),Z_(e),b_(e),F_(e),o_(e),K(e),lg(e),q(e),Um(e),Im(e)}),$_=O(179,e=>Q_(e,e.e8(e.cw))),ev=z(260,Pg),tv=z(256,e=>ev(e,Cx(e))),nv=O(132,e=>tv(e,wx(e))),rv=z(130,e=>{sg(e,new Set(e.cw.filter(e=>!!e.pr&&!!e.localHead&&e.branch===e.pr.headRefName&&e.localHead!==e.head).map(e=>e.id))),Cg(e,ze(e.cw)),wg(e,[e.cw.filter(e=>e.baseMissing),`id`]),G_(e),$_(e),J(e),Y(e),nv(e),Ym(e)}),iv=z(129,q),av=O(127,e=>iv(e,Tx(e)),2),ov=k(9,(e=>`${e}<button type=button></button>`)(xe),(e=>`/${e}& b`)(ee),Ah),sv=k(19,(e=>`<button type=button aria-label="Find in review">${e}</button>`)(Kn),(e=>` D/${e}&l`)(Pn),Th),cv=(e,t)=>{ov(e,+!t),sv(e,+!t)},lv=O(138,e=>cv(e,!e.ba||e.d3>0)),uv=D(`W90`,e=>{if(e.ba&&!e.c6&&!e.cl&&e.cj&&e.cj!==`*`&&!e.ba.some(t=>t.id===e.cj)){let t=x(e.ba,e.cj)??`*`;Dy(e,t),ar(e.a9,t)}}),dv=O(120,uv,4),fv=z(215,e=>{ot(e.w,Dx(e)),tt(e.w,Ex(e)),Pg(e),q(e)}),pv=O(214,e=>fv(e,{workspaceId:e.a9,seq:e.be,list:Nx(e),set:Mx(e),sections:jx(e),reload:Ax(e),handed:kx(e),fail:Ox(e)}),5),mv=O(88,e=>I(e.e,[`_hX`,{_hY:e.bm&&!!e.ba,_hZ:!!e.bo&&!e.bm}]),2),hv=k(20,f,(e=>`/${e}&`)(g),Vm,`<div aria-hidden=true></div>`,` `,Cm),gv=O(177,e=>hv(e,e.e6>1?0:!e.ba&&An(e.a9)!=null?1:2),2),_v=k(29,`<div aria-hidden=true></div>`,` `,gm),vv=O(85,e=>_v(e,!e.ba&&e.bm?0:1)),yv=D(`W87`,e=>{if(e.ba){let t=new Set(e.ba.map(e=>e.id));for(let n of _n(e.a9))t.has(n)||zn(e.a9,n,!1)}}),bv=O(73,yv),xv=N(72,e=>{rv(e,e.ba||[]),av(e),lv(e),dv(e),i_(e),Q(e),Yg(e),n_(e),Z(e),pv(e),jg(e),mv(e),gv(e),lg(e),vv(e),bv(e),X(e),q(e)}),Sv=z(159,e=>{N_(e),q(e)}),Cv=N(74,e=>{gy(e,e.bc?.length),Sv(e,(()=>{let t=new Map;for(let n of e.bc){let e=`${p(n.worktree)}/${n.path}`;t.set(e,[...t.get(e)||[],n])}return t})()),A_(e),pv(e)}),wv=z(78,Z),Tv=z(213,e=>{pv(e),q(e)}),Ev=O(77,e=>Tv(e,Fx(e))),Dv=z(76,e=>{wv(e,Px(e)),Z(e),Ev(e),pv(e)}),Ov=N(79,e=>{_y(e,e.bh?.key),vy(e,e.bh?.side),yy(e,e.bh?.start),Pg(e),q(e)}),kv=k(24,_r,(e=>`/${e}&`)(hr),Sh),Av=B(bh),$=N(83,e=>{kv(e,+!e.bl),Av(e)}),jv=k(5,(e=>`<button type=button title="Files changed while an agent works: the diff updates when it finishes, or now">${e} Refresh</button>`)(oi),(e=>` D/${e}&l`)(ai),Zm),Mv=O(87,e=>{R(e.e,`title`,e.bo&&!e.bm?e.bo===`comment`?`Files changed since this diff was taken: it updates once you finish your comment`:`Files changed since this diff was taken: it updates when the agent finishes`:void 0),jv(e,e.bo===`agent`&&!e.bm?0:1)}),Nv=B(Uh),Pv=N(84,e=>{R(e.l,`disabled`,e.bm),R(e.n,`disabled`,e.bm),mv(e),Mv(e),vv(e),q(e),Nv(e)}),Fv=N(86,e=>{mv(e),Mv(e),q(e)}),Iv=z(91),Lv=B(th),Rv=N(92,e=>{w_(e),Ph(e),yh(e),ph(e),Lv(e)}),zv=z(93),Bv=N(94,e=>{jy(e,e.bw?.size),E_(e),J(e),Y(e)}),Vv=N(96,e=>{My(e,e.by?.size),O_(e),J(e),Y(e)}),Hv=z(98,e=>{Z(e),J(e),Y(e)}),Uv=D(`W92`,e=>{!e.aj&&e.c9&&Gv(e,!1)}),Wv=O(108,Uv),Gv=N(107,e=>{Cp(e.a6,e.c9),Wv(e)}),Kv=D(`W86`,e=>_(e.gx,rg(e),!!e.cb,e.cd,ig(e))),qv=O(276,Kv,2),Jv=N(111,e=>{Yo(e.r,e.cd),qv(e)}),Yv=N(114,e=>qo(e.r,e.cg)),Xv=O(192,e=>Ld(e.a4,e.ci??e.el)),Zv=N(116,Xv),Qv=N(119,dv),$v=z(122,e=>{Rg(e),Z(e),nv(e),q(e)}),ey=z(123,e=>{Z(e),q(e)}),ty=z(248,q),ny=O(125,e=>ty(e,Rx(e))),ry=N(124,e=>{Y_(e),Q(e),Zg(e),ny(e),g_(e),v_(e),kg(e),c_(e),K(e),$g(e),X(e)}),iy=z(128,Z),ay=z(126,e=>{iy(e,zx(e)),av(e),Y_(e),i_(e),Q(e),n_(e),S_(e),c_(e),K(e),q(e)}),oy=N(148,e=>Me(e.a5,e.de)),sy=D(`W91`,e=>{(e.aq??0)!==e.di&&(ob(e,e.aq??0),e.dj())}),cy=O(154,sy,2),ly=z(153,e=>{cy(e),K(e)}),uy=O(150,e=>ly(e,Bx(e))),dy=N(149,e=>{uy(e),I_(e)}),fy=Vt(14,`<option> </option>`,` D `,Dm,km),py=z(275,qv),my=D(`W93`,e=>{ag(e,ei()),ti(()=>{ag(e,ei())},Yt(e,0));{let t=matchMedia(gr);t.addEventListener(`change`,()=>{Jv(e,t.matches)},{signal:Yt(e,1)})}ke(),F(e.l,`click`,function(){let t=e.n;typeof t.showPicker==`function`?t.showPicker():t.focus()}),Xt(e,`n`)});function hy(e){Qt(e,0),Qt(e,1),I(e.a,`_ji`),I(e.b,`_jl`),I(e.c,`_jT`),I(e.d,`_hR`),I(e.g,`_js`),Ne(e.h),C(e.h,`changes`),I(e.i,[`_jk`,`_jS`]),I(e.k,`_jt`),no(e.m),ro(e.m,14),io(e.m),I(e.n,`__`),Ht(e,17,Bb),Ho(e.r),Co(e.r,Wx(e)),Eo(e.r),Jo(e.r),I(e.v,[`_hU`,`_jm`]),We(e.w),I(e.x,`_jB`),I(e.a1,`_jC`),I(e.a2,`_jD`),cd(e.a4),Gd(e.a4,nn({content:mm(e)})),qd(e.a4,Ux(e)),Ie(e.a5),it(e.a5,Hx(e)),ft(e.a5),nt(e.a5),Wp(e.a6),Gp(e.a6,nn({content:lh(e)})),qp(e.a6,nn({content:dm(e)})),wp(e.a6,Vx(e)),Gt(e,ig(e)),ag(e,0),xv(e,null),Cv(e,[]),Dv(e,{issued:0,applied:0}),Ov(e,null),$(e,null),Pv(e,!1),Fv(e,null),Iv(e,Ix(e)),Rv(e,!1),zv(e,Lx(e)),Bv(e,new Set),Vv(e,new Map),Hv(e,{issued:0,applied:0}),Gv(e,!1),Jv(e,un()),Yv(e,``),Zv(e,null),Qv(e,!1),$v(e,qi()),ey(e,{seq:0,done:0,focusAt:1,etag:null,tagKey:``,stamp:null}),ry(e,null),ay(e,{anchor:null,picks:new Map,pos:null,jump:null,line:null}),oy(e,!1),dy(e,null),fy(e,[sm]),py(e,{home:null,raf:0,open:!1,docked:!1,lost:null}),my(e)}var gy=z(75,e=>He(e.w,e.bd)),_y=z(80,kg),vy=z(81,kg),yy=z(82,kg),by=D(`W88`,e=>{e.br!==cn(e.a9)&&er(e.a9,e.br)}),xy=O(90,by),Sy=B(Qm),Cy=N(89,e=>{w_(e),xy(e),Mh(e),_h(e),dh(e),Sy(e)}),wy=N(115,e=>{Q(e),Z(e),m_(e),u_(e),J(e),X(e)}),Ty=z(178,e=>{$_(e),i_(e),Q(e),n_(e),q(e)}),Ey=O(118,e=>Ty(e,Gx(e))),Dy=N(117,e=>{Ey(e),dv(e),X(e)}),Oy=N(121,e=>{Q(e),Z_(e),S_(e),c_(e)}),ky=z(240,e=>{u_(e),J(e),g_(e)}),Ay=z(35,e=>{Vp(e.a6,e.a9),Cy(e,cn(e.a9)),wy(e,La(e.a9)),Dy(e,An(e.a9)),Oy(e,new Set(_n(e.a9))),ky(e,Kx(e)),av(e),uy(e),A_(e),dv(e),i_(e),Q(e),Z(e),Ev(e),pv(e),J(e),Y(e),S_(e),gv(e),xy(e),bv(e),X(e),q(e)}),jy=z(95,ny),My=z(97,Z),Ny=z(142,e=>{O_(e),J(e),Y(e),pg(e),K(e),q(e)}),Py=O(105,e=>Ny(e,!e.c6&&e.c1!==`dirty`)),Fy=N(99,e=>{Hp(e.a6,e.c1),Py(e),U_(e),Y_(e),i_(e),Z(e),Ug(e),Gg(e),Vg(e),zg(e),lg(e),X(e),q(e),Km(e)}),Iy=z(36,e=>{Fy(e,e.aa??mn()),q(e)}),Ly=tn(100),Ry=O(39,e=>Ly(e,e.ab,e.ac)),zy=z(37,Ry),By=z(38,Ry),Vy=tn(102),Hy=O(42,e=>Vy(e,e.ae,e.af)),Uy=z(40,Hy),Wy=z(41,Hy),Gy=N(104,e=>{I(e.l,[Lt,{_jj:!!e.c6}]),Up(e.a6,e.c6),G_(e),Py(e),U_(e),Ey(e),dv(e),Z(e),Gg(e),Vg(e),zg(e),lg(e),q(e),Jm(e)}),Ky=z(43,e=>{Gy(e,e.ah??null),q(e)}),qy=(e,t)=>Pd(e.a4,t),Jy=(e,t)=>qy(e,t??!0),Yy=z(45,e=>{Wv(e),K(e),X(e),q(e)}),Xy=tn(109,e=>{I(e.q,[`_jr`,{_jq:!e.cb}]),So(e.r,e.cb),qv(e),Eh(e)}),Zy=O(48,e=>Xy(e,e.ak,e.al)),Qy=z(46,Zy),$y=z(47,Zy),eb=z(265,K),tb=tn(112,e=>{Ko(e.r,e.ce),eb(e,qx(e))}),nb=O(51,e=>tb(e,e.an,e.ao)),rb=z(49,nb),ib=z(50,nb),ab=z(137,e=>{lv(e),lg(e)}),ob=N(152,cy),sb=z(52,e=>{ob(e,e.aq??0),cy(e)}),cb=z(158,e=>{lg(e),hh(e),Bm(e)}),lb=k(15,`<optgroup label=Commits></optgroup>`,` `,zm),ub=(e,t)=>lb(e,+!t),db=B(Bh),fb=z(53,e=>{Hd(e.a4,e.ar||``),Sg(e),B_(e),jg(e),db(e)}),pb=B(Hh),mb=z(54,e=>{Ud(e.a4,e.as||``),Sg(e),B_(e),pb(e)}),hb=z(173,Z_),gb=z(176,gv),_b=z(191,Xv),vb=z(55,q_),yb=z(56,Zg),bb=z(57,e=>{Z(e),q(e)}),xb=z(58,e=>{Z(e),q(e)}),Sb=z(59,e=>{Z(e),q(e)}),Cb=z(60,Z),wb=z(61,pv),Tb=z(62,Ug),Eb=z(63,e=>{Gg(e),Vg(e)}),Db=z(227,lg),Ob=z(230,K),kb=z(233,K),Ab=z(235,pg),jb=z(269,B(rh)),Mb=z(270,B(ih)),Nb=z(271,B(ah)),Pb=z(272,B(oh)),Fb=z(273,B(sh)),Ib=z(274,B(ch)),Lb=z(64,e=>{kg(e),$g(e),q(e)}),Rb=(e,t)=>rt(e.h,t),zb=(e,t)=>dt(e.h,t),Bb=Kt(`W60`,z(268)),Vb=z(67,e=>{Ke(e.w,e.b5),q(e)}),Hb=z(68,q),Ub=z(69,q),Wb=z(70,q),Gb=(e,t)=>{Ay(e,t.workspaceId),Iy(e,t.scope),zy(e,t.file),By(e,t.fileChange),Uy(e,t.filesAt),Wy(e,t.filesAtChange),Ky(e,t.rev),Jy(e,t.treeOpen),Yy(e,t.active),Qy(e,t.findOpen),$y(e,t.findOpenChange),rb(e,t.findTick),ib(e,t.findTickChange),sb(e,t.goNonce),fb(e,t.workspaceBranch),mb(e,t.workspaceName),vb(e,t.onJump),yb(e,t.focusLine),bb(e,t.back),xb(e,t.focusPr),Sb(e,t.focusFile),Cb(e,t.onLoaded),wb(e,t.onSent),Tb(e,t.onScopeChange),Eb(e,t.onRevChange),Lb(e,t.onOpenFile),Rb(e,t.changesHref),zb(e,t.filesHref),Vb(e,t.sessions),Hb(e,t.pageActive),Ub(e,t.focusNonce),Wb(e,t.focusFileNonce)},Kb=e=>function(){$(e._,null)},qb=e=>function(){Gv(e._,!0)},Jb=e=>()=>e._._.f3(e._._.c1,!0),Yb=e=>async t=>{let n=e.d6(t),r=e.cw.find(e=>e.id===n?.repo);if(!e.d8||!n?.fp||!r)return;let i=e.da.get(t)!==`viewed`,a=i?n.fp:null,o=e.by.get(t);if(vr(e.c0),Vv(e,new Map(e.by).set(t,a)),e.bw.has(t)){let n=new Set(e.bw);n.delete(t),Bv(e,n)}e.fy(Ba(e.ch,t,i,i));try{await Qe(e.a9,[{worktree:r.worktree,branch:ne(r),path:n.path,fp:a}])}catch(r){let i=new Map(e.by);o===void 0?i.delete(t):i.set(t,o),Vv(e,i),$(e,`Marking ${n.path} failed: ${Dn(r)}`)}finally{vr(e.c0)}},Xb=e=>async t=>{if(!e.d8)return;let n=t.map(t=>e.d6(t)).filter(t=>!!t?.fp&&e.da.get(t.key)!==`viewed`&&!e.fv.has(t.key)),r=new Map(e.cw.map(e=>[e.id,e])),i=n.filter(e=>r.has(e.repo));if(!i.length)return;let a=new Map(i.map(t=>[t.key,e.by.get(t.key)]));vr(e.c0);let o=new Map(e.by);for(let e of i)o.set(e.key,e.fp);Vv(e,o),Bv(e,new Set([...e.bw,...i.map(e=>e.key)]));try{await Qe(e.a9,i.map(e=>{let t=r.get(e.repo);return{worktree:t.worktree,branch:ne(t),path:e.path,fp:e.fp}}))}catch(t){let n=new Map(e.by);for(let[e,t]of a)t===void 0?n.delete(e):n.set(e,t);Vv(e,n),$(e,`Marking ${i.length===1?i[0].path:`${i.length} files`} viewed failed: ${Dn(t)}`)}finally{vr(e.c0)}},Zb=e=>t=>{let n=e.gf(t);if(!n)return;let r=e.bi===t&&e.bj===`additions`?e.bk:0;e.eq(),e.b2?.(n.key,r||e.cq?.lineIn(t)||0,n.section)},Qb=e=>t=>{let n=e.d6(t),r=(e.ba||[]).find(e=>e.id===n?.repo);if(!n||!r||n.status===`D`)return null;let i=e.ar||``,a=r.pr?.headRefName??r.headRef??r.branch,o=i&&a.startsWith(`${i}-`)?a.slice(i.length+1):``;return{key:`${o?`${r.worktree}@${o}`:r.worktree}/${n.path}`,section:r.id}},$b=e=>async(t,n)=>{let r=e.bh,i=e.d6(t);Ov(e,null),r&&i&&!await wt(e.f9,e.gi(i,r,n))&&!e.bh&&Ov(e,r)},ex=e=>(t,n,r)=>{let i=e.bh,a=e.d6(t);return!i||!a||!n.trim()?Promise.resolve(!1):l(e.f9,e.gi(a,i,n),r)},tx=e=>t=>e.d5.get(t),nx=e=>function(t){e.fd(t)},rx=e=>t=>{if(t.startsWith(`rev:`)){e.fb(t.slice(4));return}let n=t;if(e.c6&&(Gy(e,null),e.b1?.(null),n===e.c1)){e.f3(e.c1);return}e.fa(n)},ix=e=>(t,n=!0,r=!0)=>{t!==e.c1&&(Fy(e,t),n&&Vn(t),r&&e.b0?.(t),e.f3(t))},ax=e=>t=>{t!==e.c6&&(Gy(e,t),e.b1?.(t),e.f3(e.c1))},ox=e=>async(t=e.c1,n=!1)=>{let r=la(e.cp),i=sn(e.be),a=sn(e.c0);Pv(e,!0),Fv(e,null),$(e,null);try{let o=new URLSearchParams;t!==`committed`&&o.set(`scope`,t),n&&o.set(`refresh`,`1`),e.c6&&o.set(`rev`,e.c6);let s=`${t}|${e.c6??``}`,c=`/api/workspaces/${e.a9}/diff?${o}`,l=window.__workDiff;l&&delete window.__workDiff;let u=await gn(c,e.ba?da(e.cp,s):null,l&&l.url===c&&!n?l.res:void 0);if(!ua(e.cp,r))return;if(Qv(e,!1),fa(e.cp,u.headers.get(`x-diff-stamp`),u.unchanged?null:{etag:u.etag,tagKey:s}),!u.unchanged){let t=u.data,n=t.sections;if(Ji(e.co,new Set(n.flatMap(e=>e.files.map(t=>`${e.id}/${t.path}`)))),xv(e,n),!e.c6){let t=Ua(e.ch,n.flatMap(e=>e.files.map(t=>`${e.id}/${t.path}`)));t!==e.ch&&(wy(e,t),Ra(e.a9,t))}wn(e.c0,a)&&e.bz&&Vv(e,new Map),wn(e.be,i)&&e.bg(t.comments||[])}let d=pa(e.cp,r),f=d?e.av:null;if(f)e.f0(f);else if(d&&e.aw&&e.ez(e.aw),d&&e.ax)e.f1(e.ax);else if(!e.ax&&!e.aw&&!n&&r===1){let n=jn(e.a9);n&&n.scope===t&&e.cu(n)}}catch(t){if(!ua(e.cp,r))return;$(e,`Loading diff failed: ${Dn(t)}`)}finally{ha(e.cp,r)&&(Pv(e,!1),e.ay?.())}},sx=e=>t=>{let n=e.ba||[],r=n.find(e=>e.pr&&`${e.worktree}/${e.pr.number}`===t);if(!r)return;n.length>1&&e.er(r.id,!0);let i=r.files[0];i&&e.eu(`${r.id}/${i.path}`)},cx=e=>t=>{e.eu(t);let n=e.au;n&&setTimeout(()=>e.cq?.scrollNear(t,n),0)},lx=e=>function(t){e.eq(),e.eu(t)},ux=e=>function(t,n,r){if(e.eq(),r){e.b2?.(t,n);return}e.eu(t),n&&setTimeout(()=>e.cq?.scrollToLine(t,n,`additions`),0)},dx=e=>t=>{let n=cm(t),r=e.e8(e.ba||[]);if(r&&n!==r&&e.er(n,!0),e.cn.has(n)){let t=new Set(e.cn);t.delete(n),Oy(e,t),zn(e.a9,n,!1)}let i=e.dc(t);if(za(e.ch,t,i)){let n=Ba(e.ch,t,!1,i);wy(e,n),Ra(e.a9,n)}Ca(e.cs,t),Ta(e.cs,null),Ly(e,t),e.cq?.scrollToItem(t)},fx=e=>t=>{t.pick!==e.e8(e.ba||[])&&e.er(t.pick,!0),xa(e.cs,t.pos)},px=e=>(t,n=!1,r=!1)=>{let i=e.e8(e.ba||[])??`*`,a=t??`*`;if(i===a||(ya(e.cs,i),Dy(e,a),r||ar(e.a9,a),Zv(e,t),n))return;Ly(e,null);let o=e.dm.filter(e=>!t||e.repo===t),s=ba(e.cs,a),c=s&&o.some(e=>e.key===s.key)&&s,l=o[0];xa(e.cs,c||(l?{scope:e.c1,key:l.key,off:0}:null))},mx=e=>function(t){e.gp(t)},hx=e=>t=>{if(!t.hit){Ta(e.cs,null);return}let n=t.hit;if(e.ff.has(n.repo)){let t=new Set(e.cn);t.delete(n.repo),Oy(e,t)}e.g2(n.key,!1),setTimeout(()=>{n.line<1?e.cq?.scrollToItem(n.key):e.cq?.scrollToLine(n.key,n.line,n.side)},0)},gx=e=>(t,n)=>{e.fv.has(t)!==n&&e.fy(Ba(e.ch,t,n,e.dc(t)))},_x=e=>t=>{e.cq?.holdAnchor(),e.fy(Va(t,e.fh.some(t=>e.dc(t.key))))},vx=e=>t=>{let n=e.cq?.atTop(),r=n?e.fh.findIndex(e=>e.key===n.key):-1,i=t<0&&n&&n.off>2?r:r+t,a=e.fh[i];a&&e.cq?.scrollToItem(a.key)},yx=e=>t=>{let n=new Set(e.cn),r=!n.delete(t);r&&n.add(t);let i=e.dm.filter(e=>!n.has(e.repo)),a=i.findIndex(e=>e.repo===t),o=e.dm.findIndex(e=>e.repo===t),s=r?e.dm.slice(Math.max(o,0)).find(e=>!n.has(e.repo))??i[i.length-1]:i[a];Oy(e,n),zn(e.a9,t,r),Zv(e,t),s&&Ca(e.cs,s.key)},bx=e=>t=>e.da.get(t)===`viewed`&&!e.bw.has(t),xx=e=>()=>{e.at?.(e.eo())},Sx=e=>()=>{let t=e.cq?.atTop();return{view:`diff`,pos:t?{scope:e.c1,key:t.key,off:t.off}:va(e.cs),pick:e.eb}},Cx=e=>(t,n,r)=>({worktree:p(t.repo),path:t.path,side:n.side,line_start:n.start,line_end:n.end,text:r.trim(),...e.ge(t,n)}),wx=e=>(t,n)=>{let r=e.cw.find(e=>e.id===t.repo),i=Yi(t,t.key,e.co),a=n.side===`deletions`?`deletions`:`additions`;return{head:r?.head,snippet:i?ta(i,a,n.start,n.end):void 0}},Tx=e=>()=>{e.ba&&ur(e.a9,va(e.cs))},Ex=e=>t=>s(e.f9,{session:t}),Dx=e=>()=>s(e.f9,{clipboard:!0}),Ox=e=>t=>{$(e,t)},kx=e=>t=>{`session`in t&&e.az?.(t.session),Ov(e,null)},Ax=e=>()=>void e.f7(),jx=e=>()=>e.ba,Mx=e=>t=>{Cv(e,t)},Nx=e=>()=>e.bc,Px=e=>t=>{vr(e.be),Cv(e,t)},Fx=e=>async()=>{try{let t=await St(e.a9,e.be);t&&Cv(e,t)}catch{}},Ix=e=>t=>{Cy(e,t)},Lx=e=>t=>{Rv(e,t)},Rx=e=>()=>{e.bx&&(e.cq?.holdAnchor(),Bv(e,new Set))},zx=e=>t=>{Sa(e.cs,t)},Bx=e=>async()=>{oy(e,!0);try{dy(e,(await kn(`/api/workspaces/${e.a9}/files`)).flatMap(e=>e.files.map(t=>`${e.worktree}/${t}`)))}catch{dy(e,e.df??[])}},Vx=e=>t=>{Gv(e,t)},Hx=e=>t=>{oy(e,t)},Ux=e=>function(t){e.er(t)},Wx=e=>t=>{Xy(e,t)},Gx=e=>t=>{let n=(e.c6?t.filter(e=>e.rev):t).filter(vt);if(n.length<2||e.cj===`*`)return null;if(e.cj)return x(n,e.cj);let r=e=>!e.headRef&&(!e.pr||e.pr.headRefName===e.branch);return(n.find(e=>e.files.length&&r(e))??n.find(e=>e.files.length)??n[0]).id},Kx=e=>t=>{wy(e,t),Ra(e.a9,t)},qx=e=>()=>{Yv(e,xr()),Xy(e,!0),tb(e,+e.ce+1),ig(e)()};P.W49=Kb,P.W43=qb,P.W50=Jb,P.W29=Yb,P.W30=Xb,P.W37=Zb,P.W36=Qb,P.W39=$b,P.W40=ex,P.W5=tx,P.W44=nx,P.W26=rx,P.W24=ix,P.W25=ax,P.W16=ox,P.W13=sx,P.W15=cx,P.W52=lx,P.W54=ux,P.W12=dx,P.W14=fx,P.W11=px,P.W46=mx,P.W42=hx,P.W28=gx,P.W32=_x,P.W33=vx,P.W34=yx,P.W6=bx,P.W10=xx,P.W9=Sx,P.W38=Cx,P.W35=wx,P.W4=Tx,P.W48=Ex,P.W47=Dx,P.W23=Ox,P.W22=kx,P.W21=Ax,P.W20=jx,P.W19=Mx,P.W18=Nx,P.W0=Px,P.W17=Fx,P.W1=Ix,P.W2=Lx,P.W31=Rx,P.W3=zx,P.W7=Bx,P.W55=Vx,P.W53=Hx,P.W51=Ux,P.W45=Wx,P.W8=Gx,P.W27=Kx,P.W41=qx;var Jx=Cn(`W`,tm,nm,hy,Gb);export{Gb as $input,Yy as $input_active,bb as $input_back,Rb as $input_changesHref,zy as $input_file,By as $input_fileChange,Uy as $input_filesAt,Wy as $input_filesAtChange,zb as $input_filesHref,Qy as $input_findOpen,$y as $input_findOpenChange,rb as $input_findTick,ib as $input_findTickChange,Sb as $input_focusFile,Wb as $input_focusFileNonce,yb as $input_focusLine,Ub as $input_focusNonce,xb as $input_focusPr,sb as $input_goNonce,vb as $input_onJump,Cb as $input_onLoaded,Lb as $input_onOpenFile,Eb as $input_onRevChange,Tb as $input_onScopeChange,wb as $input_onSent,Hb as $input_pageActive,Ky as $input_rev,Iy as $input_scope,Vb as $input_sessions,Jy as $input_treeOpen,fb as $input_workspaceBranch,Ay as $input_workspaceId,mb as $input_workspaceName,hy as $setup,tm as $template,nm as $walks,Jx as default};
@@ -1 +1 @@
1
- import{nn as e}from"./_DYhs8iJg.js";var t=e({default:()=>n}),n=[Object.freeze(JSON.parse(`{"displayName":"Shell","name":"shellscript","patterns":[{"include":"#initial_context"}],"repository":{"alias_statement":{"begin":"[\\\\t ]*+(alias)[\\\\t ]*+((?:((?<!\\\\w)-\\\\w+)\\\\b[\\\\t ]*+)*)[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))","beginCaptures":{"1":{"name":"storage.type.alias.shell"},"2":{"patterns":[{"match":"(?<!\\\\w)-\\\\w+\\\\b","name":"string.unquoted.argument.shell constant.other.option.shell"}]},"3":{"name":"string.unquoted.argument.shell constant.other.option.shell"},"4":{"name":"variable.other.assignment.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"variable.other.assignment.shell"},"7":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"8":{"name":"punctuation.definition.array.access.shell"},"9":{"name":"keyword.operator.assignment.shell"},"10":{"name":"keyword.operator.assignment.compound.shell"},"11":{"name":"keyword.operator.assignment.compound.shell"}},"end":"(?=[\\\\t ]|$)|(?:(?:(?:(;)|(&&))|(\\\\|\\\\|))|(&))","endCaptures":{"1":{"name":"punctuation.terminator.statement.semicolon.shell"},"2":{"name":"punctuation.separator.statement.and.shell"},"3":{"name":"punctuation.separator.statement.or.shell"},"4":{"name":"punctuation.separator.statement.background.shell"}},"name":"meta.expression.assignment.alias.shell","patterns":[{"include":"#normal_context"}]},"argument":{"begin":"[\\\\t ]++(?![\\\\n#\\\\&(\\\\[|]|$|;)","beginCaptures":{},"end":"(?=[\\\\t \\\\&;|]|$|[\\\\n)\`])","endCaptures":{},"name":"meta.argument.shell","patterns":[{"include":"#argument_context"},{"include":"#line_continuation"}]},"argument_context":{"patterns":[{"captures":{"1":{"name":"string.unquoted.argument.shell","patterns":[{"match":"\\\\*","name":"variable.language.special.wildcard.shell"},{"include":"#variable"},{"include":"#numeric_literal"},{"captures":{"1":{"name":"constant.language.$1.shell"}},"match":"(?<!\\\\w)\\\\b(true|false)\\\\b(?!\\\\w)"}]}},"match":"[\\\\t ]*+([^\\\\t\\\\n \\"$\\\\&-);<>\\\\\\\\\`|]+(?!>))"},{"include":"#normal_context"}]},"arithmetic_double":{"patterns":[{"begin":"\\\\(\\\\(","beginCaptures":{"0":{"name":"punctuation.section.arithmetic.double.shell"}},"end":"\\\\)\\\\s*\\\\)","endCaptures":{"0":{"name":"punctuation.section.arithmetic.double.shell"}},"name":"meta.arithmetic.shell","patterns":[{"include":"#math"},{"include":"#string"}]}]},"arithmetic_no_dollar":{"patterns":[{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.section.arithmetic.single.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.section.arithmetic.single.shell"}},"name":"meta.arithmetic.shell","patterns":[{"include":"#math"},{"include":"#string"}]}]},"array_access_inline":{"captures":{"1":{"name":"punctuation.section.array.shell"},"2":{"patterns":[{"include":"#special_expansion"},{"include":"#string"},{"include":"#variable"}]},"3":{"name":"punctuation.section.array.shell"}},"match":"(\\\\[)([^]\\\\[]+)(])"},"array_value":{"begin":"[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))[\\\\t ]*+(\\\\()","beginCaptures":{"1":{"name":"variable.other.assignment.shell"},"2":{"name":"punctuation.definition.array.access.shell"},"3":{"name":"variable.other.assignment.shell"},"4":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"keyword.operator.assignment.shell"},"7":{"name":"keyword.operator.assignment.compound.shell"},"8":{"name":"keyword.operator.assignment.compound.shell"},"9":{"name":"punctuation.definition.array.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.array.shell"}},"patterns":[{"include":"#comment"},{"captures":{"1":{"name":"variable.other.assignment.array.shell entity.other.attribute-name.shell"},"2":{"name":"keyword.operator.assignment.shell punctuation.definition.assignment.shell"}},"match":"((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(=)"},{"captures":{"1":{"name":"punctuation.definition.bracket.named-array.shell"},"2":{"name":"string.unquoted.shell entity.other.attribute-name.bracket.shell"},"3":{"name":"punctuation.definition.bracket.named-array.shell"},"4":{"name":"punctuation.definition.assignment.shell"}},"match":"(\\\\[)(.+?)(])(=)"},{"include":"#normal_context"},{"include":"#simple_unquoted"}]},"assignment_statement":{"patterns":[{"include":"#array_value"},{"include":"#modified_assignment_statement"},{"include":"#normal_assignment_statement"}]},"basic_command_name":{"captures":{"1":{"name":"storage.modifier.$1.shell"},"2":{"name":"entity.name.function.call.shell entity.name.command.shell","patterns":[{"match":"(?<!\\\\w)(?:continue|return|break)(?!\\\\w)","name":"keyword.control.$0.shell"},{"match":"(?<!\\\\w)(?:unfunction|continue|autoload|unsetopt|bindkey|builtin|getopts|command|declare|unalias|history|unlimit|typeset|suspend|source|printf|unhash|disown|ulimit|return|which|alias|break|false|print|shift|times|umask|unset|read|type|exec|eval|wait|echo|dirs|jobs|kill|hash|stat|exit|test|trap|true|let|set|pwd|cd|fg|bg|fc|[.:])(?!/)(?!\\\\w)(?!-)","name":"support.function.builtin.shell"},{"include":"#variable"}]}},"match":"(?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;])(?!nocorrect |nocorrect\\\\t|nocorrect$|readonly |readonly\\\\t|readonly$|function |function\\\\t|function$|foreach |foreach\\\\t|foreach$|coproc |coproc\\\\t|coproc$|logout |logout\\\\t|logout$|export |export\\\\t|export$|select |select\\\\t|select$|repeat |repeat\\\\t|repeat$|pushd |pushd\\\\t|pushd$|until |until\\\\t|until$|while |while\\\\t|while$|local |local\\\\t|local$|case |case\\\\t|case$|done |done\\\\t|done$|elif |elif\\\\t|elif$|else |else\\\\t|else$|esac |esac\\\\t|esac$|popd |popd\\\\t|popd$|then |then\\\\t|then$|time |time\\\\t|time$|for |for\\\\t|for$|end |end\\\\t|end$|fi |fi\\\\t|fi$|do |do\\\\t|do$|in |in\\\\t|in$|if |if\\\\t|if$)(?:((?<=^|[\\\\t \\\\&;])(?:readonly|declare|typeset|export|local)(?=[\\\\t \\\\&;]|$))|((?![\\"']|\\\\\\\\\\\\n?$)[^\\\\t\\\\n\\\\r !\\"'<>]+?))(?:(?=[\\\\t ])|(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\))","name":"meta.statement.command.name.basic.shell"},"block_comment":{"begin":"\\\\s*+(/\\\\*)","beginCaptures":{"1":{"name":"punctuation.definition.comment.begin.shell"}},"end":"\\\\*/","endCaptures":{"0":{"name":"punctuation.definition.comment.end.shell"}},"name":"comment.block.shell"},"boolean":{"match":"\\\\b(?:true|false)\\\\b","name":"constant.language.$0.shell"},"case_statement":{"begin":"\\\\b(case)\\\\b[\\\\t ]*+(.+?)[\\\\t ]*+\\\\b(in)\\\\b","beginCaptures":{"1":{"name":"keyword.control.case.shell"},"2":{"patterns":[{"include":"#initial_context"}]},"3":{"name":"keyword.control.in.shell"}},"end":"\\\\besac\\\\b","endCaptures":{"0":{"name":"keyword.control.esac.shell"}},"name":"meta.case.shell","patterns":[{"include":"#comment"},{"captures":{"1":{"name":"keyword.operator.pattern.case.default.shell"}},"match":"[\\\\t ]*+(\\\\* *\\\\))"},{"begin":"(?<!\\\\))(?![\\\\t ]*+(?:esac\\\\b|$))","beginCaptures":{},"end":"(?=\\\\besac\\\\b)|(\\\\))","endCaptures":{"1":{"name":"keyword.operator.pattern.case.shell"}},"name":"meta.case.entry.pattern.shell","patterns":[{"include":"#case_statement_context"}]},{"begin":"(?<=\\\\))","beginCaptures":{},"end":"(;;)|(?=\\\\besac\\\\b)","endCaptures":{"1":{"name":"punctuation.terminator.statement.case.shell"}},"name":"meta.case.entry.body.shell","patterns":[{"include":"#typical_statements"},{"include":"#initial_context"}]}]},"case_statement_context":{"patterns":[{"match":"\\\\*","name":"variable.language.special.quantifier.star.shell keyword.operator.quantifier.star.shell punctuation.definition.arbitrary-repetition.shell punctuation.definition.regex.arbitrary-repetition.shell"},{"match":"\\\\+","name":"variable.language.special.quantifier.plus.shell keyword.operator.quantifier.plus.shell punctuation.definition.arbitrary-repetition.shell punctuation.definition.regex.arbitrary-repetition.shell"},{"match":"\\\\?","name":"variable.language.special.quantifier.question.shell keyword.operator.quantifier.question.shell punctuation.definition.arbitrary-repetition.shell punctuation.definition.regex.arbitrary-repetition.shell"},{"match":"@","name":"variable.language.special.at.shell keyword.operator.at.shell punctuation.definition.regex.at.shell"},{"match":"\\\\|","name":"keyword.operator.orvariable.language.special.or.shell keyword.operator.alternation.ruby.shell punctuation.definition.regex.alternation.shell punctuation.separator.regex.alternation.shell"},{"match":"\\\\\\\\.","name":"constant.character.escape.shell"},{"match":"(?<=\\\\tin| in|[\\\\t ]|;;)\\\\(","name":"keyword.operator.pattern.case.shell"},{"begin":"(?<=\\\\S)(\\\\()","beginCaptures":{"1":{"name":"punctuation.definition.group.shell punctuation.definition.regex.group.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.definition.regex.group.shell"}},"name":"meta.parenthese.shell","patterns":[{"include":"#case_statement_context"}]},{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.character-class.shell"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.character-class.shell"}},"name":"string.regexp.character-class.shell","patterns":[{"match":"\\\\\\\\.","name":"constant.character.escape.shell"}]},{"include":"#string"},{"match":"[^\\\\t\\\\n )*?@\\\\[|]","name":"string.unquoted.pattern.shell string.regexp.unquoted.shell"}]},"command_name_range":{"begin":"\\\\G","beginCaptures":{},"end":"(?=[\\\\t \\\\&;|]|$|[\\\\n)\`])|(?=<)","endCaptures":{},"name":"meta.statement.command.name.shell","patterns":[{"match":"(?<!\\\\w)(?:continue|return|break)(?!\\\\w)","name":"entity.name.function.call.shell entity.name.command.shell keyword.control.$0.shell"},{"match":"(?<!\\\\w)(?:unfunction|continue|autoload|unsetopt|bindkey|builtin|getopts|command|declare|unalias|history|unlimit|typeset|suspend|source|printf|unhash|disown|ulimit|return|which|alias|break|false|print|shift|times|umask|unset|read|type|exec|eval|wait|echo|dirs|jobs|kill|hash|stat|exit|test|trap|true|let|set|pwd|cd|fg|bg|fc|[.:])(?!/)(?!\\\\w)(?!-)","name":"entity.name.function.call.shell entity.name.command.shell support.function.builtin.shell"},{"include":"#variable"},{"captures":{"1":{"name":"entity.name.function.call.shell entity.name.command.shell"}},"match":"(?<!\\\\w)(?<=\\\\G|[\\"')}])([^\\\\t\\\\n\\\\r \\"\\\\&');->\`{|]+)"},{"begin":"(?:\\\\G|(?<![\\\\t\\\\n #\\\\&;{|]))(\\\\$?)((\\")|('))","beginCaptures":{"1":{"name":"meta.statement.command.name.quoted.shell punctuation.definition.string.shell entity.name.function.call.shell entity.name.command.shell"},"2":{},"3":{"name":"meta.statement.command.name.quoted.shell string.quoted.double.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"},"4":{"name":"meta.statement.command.name.quoted.shell string.quoted.single.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"}},"end":"(?<!\\\\G)(?<=\\\\2)","endCaptures":{},"patterns":[{"include":"#continuation_of_single_quoted_command_name"},{"include":"#continuation_of_double_quoted_command_name"}]},{"include":"#line_continuation"},{"include":"#simple_unquoted"}]},"command_statement":{"begin":"[\\\\t ]*+(?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;])(?!nocorrect |nocorrect\\\\t|nocorrect$|readonly |readonly\\\\t|readonly$|function |function\\\\t|function$|foreach |foreach\\\\t|foreach$|coproc |coproc\\\\t|coproc$|logout |logout\\\\t|logout$|export |export\\\\t|export$|select |select\\\\t|select$|repeat |repeat\\\\t|repeat$|pushd |pushd\\\\t|pushd$|until |until\\\\t|until$|while |while\\\\t|while$|local |local\\\\t|local$|case |case\\\\t|case$|done |done\\\\t|done$|elif |elif\\\\t|elif$|else |else\\\\t|else$|esac |esac\\\\t|esac$|popd |popd\\\\t|popd$|then |then\\\\t|then$|time |time\\\\t|time$|for |for\\\\t|for$|end |end\\\\t|end$|fi |fi\\\\t|fi$|do |do\\\\t|do$|in |in\\\\t|in$|if |if\\\\t|if$)(?!\\\\\\\\\\\\n?$)","beginCaptures":{},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.command.shell","patterns":[{"include":"#command_name_range"},{"include":"#line_continuation"},{"include":"#option"},{"include":"#argument"},{"include":"#string"},{"include":"#heredoc"}]},"comment":{"captures":{"1":{"name":"comment.line.number-sign.shell meta.shebang.shell"},"2":{"name":"punctuation.definition.comment.shebang.shell"},"3":{"name":"comment.line.number-sign.shell"},"4":{"name":"punctuation.definition.comment.shell"}},"match":"(?:^|[\\\\t ]++)(?:((#!).*)|((#).*))"},"comments":{"patterns":[{"include":"#block_comment"},{"include":"#line_comment"}]},"compound-command":{"patterns":[{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"name":"meta.scope.logical-expression.shell","patterns":[{"include":"#logical-expression"},{"include":"#initial_context"}]},{"begin":"(?<=\\\\s|^)\\\\{(?=\\\\s|$)","beginCaptures":{"0":{"name":"punctuation.definition.group.shell"}},"end":"(?<=^|;)\\\\s*(})","endCaptures":{"1":{"name":"punctuation.definition.group.shell"}},"name":"meta.scope.group.shell","patterns":[{"include":"#initial_context"}]}]},"continuation_of_double_quoted_command_name":{"begin":"\\\\G(?<=\\")","beginCaptures":{},"contentName":"meta.statement.command.name.continuation string.quoted.double entity.name.function.call entity.name.command","end":"\\"","endCaptures":{"0":{"name":"string.quoted.double.shell punctuation.definition.string.end.shell entity.name.function.call.shell entity.name.command.shell"}},"patterns":[{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"include":"#variable"},{"include":"#interpolation"}]},"continuation_of_single_quoted_command_name":{"begin":"\\\\G(?<=')","beginCaptures":{},"contentName":"meta.statement.command.name.continuation string.quoted.single entity.name.function.call entity.name.command","end":"'","endCaptures":{"0":{"name":"string.quoted.single.shell punctuation.definition.string.end.shell entity.name.function.call.shell entity.name.command.shell"}}},"custom_command_names":{"patterns":[]},"custom_commands":{"patterns":[]},"double_quote_context":{"patterns":[{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"include":"#variable"},{"include":"#interpolation"}]},"double_quote_escape_char":{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},"floating_keyword":{"patterns":[{"match":"(?<=^|[\\\\t \\\\&;])(?:then|elif|else|done|end|do|if|fi)(?=[\\\\t \\\\&;]|$)","name":"keyword.control.$0.shell"}]},"for_statement":{"patterns":[{"begin":"\\\\b(for)\\\\b[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))[\\\\t ]*+\\\\b(in)\\\\b","beginCaptures":{"1":{"name":"keyword.control.for.shell"},"2":{"name":"variable.other.for.shell"},"3":{"name":"keyword.control.in.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.for.in.shell","patterns":[{"include":"#string"},{"include":"#simple_unquoted"},{"include":"#normal_context"}]},{"begin":"\\\\b(for)\\\\b","beginCaptures":{"1":{"name":"keyword.control.for.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.for.shell","patterns":[{"include":"#arithmetic_double"},{"include":"#normal_context"}]}]},"function_definition":{"applyEndPatternLast":1,"begin":"[\\\\t ]*+(?:\\\\b(function)\\\\b[\\\\t ]*+([^\\\\t\\\\n\\\\r \\"'()=]+)(?:(\\\\()[\\\\t ]*+(\\\\)))?|([^\\\\t\\\\n\\\\r \\"'()=]+)[\\\\t ]*+(\\\\()[\\\\t ]*+(\\\\)))","beginCaptures":{"1":{"name":"storage.type.function.shell"},"2":{"name":"entity.name.function.shell"},"3":{"name":"punctuation.definition.arguments.shell"},"4":{"name":"punctuation.definition.arguments.shell"},"5":{"name":"entity.name.function.shell"},"6":{"name":"punctuation.definition.arguments.shell"},"7":{"name":"punctuation.definition.arguments.shell"}},"end":"(?<=[)}])","endCaptures":{},"name":"meta.function.shell","patterns":[{"match":"\\\\G[\\\\t\\\\n ]"},{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"name":"meta.function.body.shell","patterns":[{"include":"#initial_context"}]},{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"name":"meta.function.body.shell","patterns":[{"include":"#initial_context"}]},{"include":"#initial_context"}]},"heredoc":{"patterns":[{"begin":"((?<!<)<<-)[\\\\t ]*+([\\"'])[\\\\t ]*+([^\\"']+?)(?=[\\"\\\\&';<\\\\s])(\\\\2)(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.quote.shell"},"3":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"4":{"name":"punctuation.definition.string.heredoc.quote.shell"},"5":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.quoted.heredoc.indent.$3","end":"^\\\\t*\\\\3(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.$0.shell"}},"patterns":[]},{"begin":"((?<!<)<<(?!<))[\\\\t ]*+([\\"'])[\\\\t ]*+([^\\"']+?)(?=[\\"\\\\&';<\\\\s])(\\\\2)(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.quote.shell"},"3":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"4":{"name":"punctuation.definition.string.heredoc.quote.shell"},"5":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.quoted.heredoc.no-indent.$3","end":"^\\\\3(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.delimiter.shell"}},"patterns":[]},{"begin":"((?<!<)<<-)[\\\\t ]*+([^\\\\t \\"']+)(?=[\\"\\\\&';<\\\\s])(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"3":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.unquoted.heredoc.indent.$2","end":"^\\\\t*\\\\2(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.delimiter.shell"}},"patterns":[{"include":"#double_quote_escape_char"},{"include":"#variable"},{"include":"#interpolation"}]},{"begin":"((?<!<)<<(?!<))[\\\\t ]*+([^\\\\t \\"']+)(?=[\\"\\\\&';<\\\\s])(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"3":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.unquoted.heredoc.no-indent.$2","end":"^\\\\2(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.delimiter.shell"}},"patterns":[{"include":"#double_quote_escape_char"},{"include":"#variable"},{"include":"#interpolation"}]}]},"herestring":{"patterns":[{"begin":"(<<<)\\\\s*(('))","beginCaptures":{"1":{"name":"keyword.operator.herestring.shell"},"2":{"name":"string.quoted.single.shell"},"3":{"name":"punctuation.definition.string.begin.shell"}},"contentName":"string.quoted.single.shell","end":"(')","endCaptures":{"0":{"name":"string.quoted.single.shell"},"1":{"name":"punctuation.definition.string.end.shell"}},"name":"meta.herestring.shell"},{"begin":"(<<<)\\\\s*((\\"))","beginCaptures":{"1":{"name":"keyword.operator.herestring.shell"},"2":{"name":"string.quoted.double.shell"},"3":{"name":"punctuation.definition.string.begin.shell"}},"contentName":"string.quoted.double.shell","end":"(\\")","endCaptures":{"0":{"name":"string.quoted.double.shell"},"1":{"name":"punctuation.definition.string.end.shell"}},"name":"meta.herestring.shell","patterns":[{"include":"#double_quote_context"}]},{"captures":{"1":{"name":"keyword.operator.herestring.shell"},"2":{"name":"string.unquoted.herestring.shell","patterns":[{"include":"#initial_context"}]}},"match":"(<<<)\\\\s*(([^)\\\\\\\\\\\\s]|\\\\\\\\.)+)","name":"meta.herestring.shell"}]},"initial_context":{"patterns":[{"include":"#comment"},{"include":"#pipeline"},{"include":"#normal_statement_seperator"},{"include":"#logical_expression_double"},{"include":"#logical_expression_single"},{"include":"#assignment_statement"},{"include":"#case_statement"},{"include":"#for_statement"},{"include":"#loop"},{"include":"#function_definition"},{"include":"#line_continuation"},{"include":"#arithmetic_double"},{"include":"#misc_ranges"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#redirection"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#alias_statement"},{"include":"#normal_statement"},{"include":"#string"},{"include":"#support"}]},"inline_comment":{"captures":{"1":{"name":"comment.block.shell punctuation.definition.comment.begin.shell"},"2":{"name":"comment.block.shell"},"3":{"patterns":[{"match":"\\\\*/","name":"comment.block.shell punctuation.definition.comment.end.shell"},{"match":"\\\\*","name":"comment.block.shell"}]}},"match":"(/\\\\*)((?:[^*]|\\\\*++[^/])*+(\\\\*++/))"},"interpolation":{"patterns":[{"include":"#arithmetic_dollar"},{"include":"#subshell_dollar"},{"begin":"\`","beginCaptures":{"0":{"name":"punctuation.definition.evaluation.backticks.shell"}},"end":"\`","endCaptures":{"0":{"name":"punctuation.definition.evaluation.backticks.shell"}},"name":"string.interpolated.backtick.shell","patterns":[{"match":"\\\\\\\\[$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"begin":"(?<=\\\\W)(?=#)(?!#\\\\{)","beginCaptures":{"1":{"name":"punctuation.whitespace.comment.leading.shell"}},"end":"(?!\\\\G)","patterns":[{"begin":"#","beginCaptures":{"0":{"name":"punctuation.definition.comment.shell"}},"end":"(?=\`)","name":"comment.line.number-sign.shell"}]},{"include":"#initial_context"}]}]},"keyword":{"patterns":[{"match":"(?<=^|[\\\\&;\\\\s])(then|else|elif|fi|for|in|do|done|select|continue|esac|while|until|return)(?=[\\\\&;\\\\s]|$)","name":"keyword.control.shell"},{"match":"(?<=^|[\\\\&;\\\\s])(?:export|declare|typeset|local|readonly)(?=[\\\\&;\\\\s]|$)","name":"storage.modifier.shell"}]},"line_comment":{"begin":"\\\\s*+(//)","beginCaptures":{"1":{"name":"punctuation.definition.comment.shell"}},"end":"(?<=\\\\n)(?<!\\\\\\\\\\\\n)","endCaptures":{},"name":"comment.line.double-slash.shell","patterns":[{"include":"#line_continuation_character"}]},"line_continuation":{"match":"\\\\\\\\(?=\\\\n)","name":"constant.character.escape.line-continuation.shell"},"logical-expression":{"patterns":[{"include":"#arithmetic_no_dollar"},{"match":"=[=~]?|!=?|[<>]|&&|\\\\|\\\\|","name":"keyword.operator.logical.shell"},{"match":"(?<!\\\\S)-(nt|ot|ef|eq|ne|l[et]|g[et]|[GLNOSa-hknopr-uwxz])\\\\b","name":"keyword.operator.logical.shell"}]},"logical_expression_context":{"patterns":[{"include":"#regex_comparison"},{"include":"#arithmetic_no_dollar"},{"include":"#logical-expression"},{"include":"#logical_expression_single"},{"include":"#logical_expression_double"},{"include":"#comment"},{"include":"#boolean"},{"include":"#redirect_number"},{"include":"#numeric_literal"},{"include":"#pipeline"},{"include":"#normal_statement_seperator"},{"include":"#string"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#support"}]},"logical_expression_double":{"begin":"\\\\[\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"end":"]]","endCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"name":"meta.scope.logical-expression.shell","patterns":[{"include":"#logical_expression_context"}]},"logical_expression_single":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"name":"meta.scope.logical-expression.shell","patterns":[{"include":"#logical_expression_context"}]},"loop":{"patterns":[{"begin":"(?<=^|[\\\\&;\\\\s])(for)\\\\s+(.+?)\\\\s+(in)(?=[\\\\&;\\\\s]|$)","beginCaptures":{"1":{"name":"keyword.control.shell"},"2":{"name":"variable.other.loop.shell","patterns":[{"include":"#string"}]},"3":{"name":"keyword.control.shell"}},"end":"(?<=^|[\\\\&;\\\\s])done(?=[\\\\&;\\\\s]|$|\\\\))","endCaptures":{"0":{"name":"keyword.control.shell"}},"name":"meta.scope.for-in-loop.shell","patterns":[{"include":"#initial_context"}]},{"begin":"(?<=^|[\\\\&;\\\\s])(while|until)(?=[\\\\&;\\\\s]|$)","beginCaptures":{"1":{"name":"keyword.control.shell"}},"end":"(?<=^|[\\\\&;\\\\s])done(?=[\\\\&;\\\\s]|$|\\\\))","endCaptures":{"0":{"name":"keyword.control.shell"}},"name":"meta.scope.while-loop.shell","patterns":[{"include":"#initial_context"}]},{"begin":"(?<=^|[\\\\&;\\\\s])(select)\\\\s+((?:[^\\\\\\\\\\\\s]|\\\\\\\\.)+)(?=[\\\\&;\\\\s]|$)","beginCaptures":{"1":{"name":"keyword.control.shell"},"2":{"name":"variable.other.loop.shell"}},"end":"(?<=^|[\\\\&;\\\\s])(done)(?=[\\\\&;\\\\s]|$|\\\\))","endCaptures":{"1":{"name":"keyword.control.shell"}},"name":"meta.scope.select-block.shell","patterns":[{"include":"#initial_context"}]},{"begin":"(?<=^|[\\\\&;\\\\s])if(?=[\\\\&;\\\\s]|$)","beginCaptures":{"0":{"name":"keyword.control.if.shell"}},"end":"(?<=^|[\\\\&;\\\\s])fi(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"keyword.control.fi.shell"}},"name":"meta.scope.if-block.shell","patterns":[{"include":"#initial_context"}]}]},"math":{"patterns":[{"include":"#variable"},{"match":"\\\\+{1,2}|-{1,2}|[!~]|\\\\*{1,2}|[%/]|<[<=]?|>[=>]?|==|!=|^|\\\\|{1,2}|&{1,2}|[,:=?]|[-%\\\\&*+/^|]=|<<=|>>=","name":"keyword.operator.arithmetic.shell"},{"match":"0[Xx]\\\\h+","name":"constant.numeric.hex.shell"},{"match":";","name":"punctuation.separator.semicolon.range"},{"match":"0\\\\d+","name":"constant.numeric.octal.shell"},{"match":"\\\\d{1,2}#[0-9@-Z_a-z]+","name":"constant.numeric.other.shell"},{"match":"\\\\d+","name":"constant.numeric.integer.shell"},{"match":"(?<!\\\\w)[0-9A-Z_a-z]+(?!\\\\w)","name":"variable.other.normal.shell"}]},"math_operators":{"patterns":[{"match":"\\\\+{1,2}|-{1,2}|[!~]|\\\\*{1,2}|[%/]|<[<=]?|>[=>]?|==|!=|^|\\\\|{1,2}|&{1,2}|[,:=?]|[-%\\\\&*+/^|]=|<<=|>>=","name":"keyword.operator.arithmetic.shell"},{"match":"0[Xx]\\\\h+","name":"constant.numeric.hex.shell"},{"match":"0\\\\d+","name":"constant.numeric.octal.shell"},{"match":"\\\\d{1,2}#[0-9@-Z_a-z]+","name":"constant.numeric.other.shell"},{"match":"\\\\d+","name":"constant.numeric.integer.shell"}]},"misc_ranges":{"patterns":[{"include":"#logical_expression_single"},{"include":"#logical_expression_double"},{"include":"#subshell_dollar"},{"begin":"(?<![^\\\\t ])(\\\\{)(?![$\\\\w])","beginCaptures":{"1":{"name":"punctuation.definition.group.shell"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.group.shell"}},"name":"meta.scope.group.shell","patterns":[{"include":"#initial_context"}]}]},"modified_assignment_statement":{"begin":"(?<=^|[\\\\t \\\\&;])(?:readonly|declare|typeset|export|local)(?=[\\\\t \\\\&;]|$)","beginCaptures":{"0":{"name":"storage.modifier.$0.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.shell meta.expression.assignment.modified.shell","patterns":[{"match":"(?<!\\\\w)-\\\\w+\\\\b","name":"string.unquoted.argument.shell constant.other.option.shell"},{"include":"#array_value"},{"captures":{"1":{"name":"variable.other.assignment.shell"},"2":{"name":"punctuation.definition.array.access.shell"},"3":{"name":"variable.other.assignment.shell"},"4":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"keyword.operator.assignment.shell"},"7":{"name":"keyword.operator.assignment.compound.shell"},"8":{"name":"keyword.operator.assignment.compound.shell"},"9":{"name":"constant.numeric.shell constant.numeric.hex.shell"},"10":{"name":"constant.numeric.shell constant.numeric.octal.shell"},"11":{"name":"constant.numeric.shell constant.numeric.other.shell"},"12":{"name":"constant.numeric.shell constant.numeric.decimal.shell"},"13":{"name":"constant.numeric.shell constant.numeric.version.shell"},"14":{"name":"constant.numeric.shell constant.numeric.integer.shell"}},"match":"((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))?(?:(?<=[\\\\t =]|^|[(\\\\[{])(?:(?:(?:(?:(?:(0[Xx]\\\\h+)|(0\\\\d+))|(\\\\d{1,2}#[0-9@-Z_a-z]+))|(-?\\\\d+\\\\.\\\\d+))|(-?\\\\d+(?:\\\\.\\\\d+)+))|(-?\\\\d+))(?=[\\\\t ]|$|[);}]))?"},{"include":"#normal_context"}]},"modifiers":{"match":"(?<=^|[\\\\t \\\\&;])(?:readonly|declare|typeset|export|local)(?=[\\\\t \\\\&;]|$)","name":"storage.modifier.$0.shell"},"normal_assignment_statement":{"begin":"[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))","beginCaptures":{"1":{"name":"variable.other.assignment.shell"},"2":{"name":"punctuation.definition.array.access.shell"},"3":{"name":"variable.other.assignment.shell"},"4":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"keyword.operator.assignment.shell"},"7":{"name":"keyword.operator.assignment.compound.shell"},"8":{"name":"keyword.operator.assignment.compound.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.expression.assignment.shell","patterns":[{"include":"#comment"},{"include":"#string"},{"include":"#normal_assignment_statement"},{"begin":"(?<=[\\\\t ])(?![\\\\t ]|\\\\w+=)","beginCaptures":{},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.command.env.shell","patterns":[{"include":"#command_name_range"},{"include":"#line_continuation"},{"include":"#option"},{"include":"#argument"},{"include":"#string"}]},{"include":"#simple_unquoted"},{"include":"#normal_context"}]},"normal_context":{"patterns":[{"include":"#comment"},{"include":"#pipeline"},{"include":"#normal_statement_seperator"},{"include":"#misc_ranges"},{"include":"#boolean"},{"include":"#redirect_number"},{"include":"#numeric_literal"},{"include":"#string"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#redirection"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#support"},{"include":"#parenthese"}]},"normal_statement":{"begin":"(?!^[\\\\t ]*+$)(?:(?<=(?:^until| until|\\\\tuntil|^while| while|\\\\twhile|^elif| elif|\\\\telif|^else| else|\\\\telse|^then| then|\\\\tthen|^do| do|\\\\tdo|^if| if|\\\\tif) )|(?<=^|[!\\\\&(;\`{|]))[\\\\t ]*+(?!nocorrect\\\\W|nocorrect\\\\$|function\\\\W|function\\\\$|foreach\\\\W|foreach\\\\$|repeat\\\\W|repeat\\\\$|logout\\\\W|logout\\\\$|coproc\\\\W|coproc\\\\$|select\\\\W|select\\\\$|while\\\\W|while\\\\$|pushd\\\\W|pushd\\\\$|until\\\\W|until\\\\$|case\\\\W|case\\\\$|done\\\\W|done\\\\$|elif\\\\W|elif\\\\$|else\\\\W|else\\\\$|esac\\\\W|esac\\\\$|popd\\\\W|popd\\\\$|then\\\\W|then\\\\$|time\\\\W|time\\\\$|for\\\\W|for\\\\$|end\\\\W|end\\\\$|fi\\\\W|fi\\\\$|do\\\\W|do\\\\$|in\\\\W|in\\\\$|if\\\\W|if\\\\$)","beginCaptures":{},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.shell","patterns":[{"include":"#typical_statements"}]},"normal_statement_seperator":{"captures":{"1":{"name":"punctuation.terminator.statement.semicolon.shell"},"2":{"name":"punctuation.separator.statement.and.shell"},"3":{"name":"punctuation.separator.statement.or.shell"},"4":{"name":"punctuation.separator.statement.background.shell"}},"match":"(?:(?:(;)|(&&))|(\\\\|\\\\|))|(&)"},"numeric_literal":{"captures":{"1":{"name":"constant.numeric.shell constant.numeric.hex.shell"},"2":{"name":"constant.numeric.shell constant.numeric.octal.shell"},"3":{"name":"constant.numeric.shell constant.numeric.other.shell"},"4":{"name":"constant.numeric.shell constant.numeric.decimal.shell"},"5":{"name":"constant.numeric.shell constant.numeric.version.shell"},"6":{"name":"constant.numeric.shell constant.numeric.integer.shell"}},"match":"(?<=[\\\\t =]|^|[(\\\\[{])(?:(?:(?:(?:(?:(0[Xx]\\\\h+)|(0\\\\d+))|(\\\\d{1,2}#[0-9@-Z_a-z]+))|(-?\\\\d+\\\\.\\\\d+))|(-?\\\\d+(?:\\\\.\\\\d+)+))|(-?\\\\d+))(?=[\\\\t ]|$|[);}])"},"option":{"begin":"[\\\\t ]++(-)((?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;]))","beginCaptures":{"1":{"name":"string.unquoted.argument.shell constant.other.option.dash.shell"},"2":{"name":"string.unquoted.argument.shell constant.other.option.shell"}},"contentName":"string.unquoted.argument constant.other.option","end":"(?=[\\\\t ])|(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"patterns":[{"include":"#option_context"}]},"option_context":{"patterns":[{"include":"#misc_ranges"},{"include":"#string"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#redirection"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#support"}]},"parenthese":{"patterns":[{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.section.parenthese.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.section.parenthese.shell"}},"name":"meta.parenthese.group.shell","patterns":[{"include":"#initial_context"}]}]},"pathname":{"patterns":[{"match":"(?<=[:=\\\\s]|^)~","name":"keyword.operator.tilde.shell"},{"match":"[*?]","name":"keyword.operator.glob.shell"},{"begin":"([!*+?@])(\\\\()","beginCaptures":{"1":{"name":"keyword.operator.extglob.shell"},"2":{"name":"punctuation.definition.extglob.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.extglob.shell"}},"name":"meta.structure.extglob.shell","patterns":[{"include":"#initial_context"}]}]},"pipeline":{"patterns":[{"match":"(?<=^|[\\\\&;\\\\s])(time)(?=[\\\\&;\\\\s]|$)","name":"keyword.other.shell"},{"match":"[!|]","name":"keyword.operator.pipe.shell"}]},"redirect_fix":{"captures":{"1":{"name":"keyword.operator.redirect.shell"},"2":{"name":"string.unquoted.argument.shell"}},"match":"(>>?)[\\\\t ]*+([^\\\\t\\\\n \\"$\\\\&-);<>\\\\\\\\\`|]+)"},"redirect_number":{"captures":{"1":{"name":"keyword.operator.redirect.stdout.shell"},"2":{"name":"keyword.operator.redirect.stderr.shell"},"3":{"name":"keyword.operator.redirect.$3.shell"}},"match":"(?<=[\\\\t ])(?:(1)|(2)|(\\\\d+))(?=>)"},"redirection":{"patterns":[{"begin":"[<>]\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.interpolated.process-substitution.shell","patterns":[{"include":"#initial_context"}]},{"match":"(?<![<>])(&>|\\\\d*>&\\\\d*|\\\\d*(>>|[<>])|\\\\d*<&|\\\\d*<>)(?![<>])","name":"keyword.operator.redirect.shell"}]},"regex_comparison":{"match":"=~","name":"keyword.operator.logical.regex.shell"},"regexp":{"patterns":[{"match":".+"}]},"simple_options":{"captures":{"0":{"patterns":[{"captures":{"1":{"name":"string.unquoted.argument.shell constant.other.option.dash.shell"},"2":{"name":"string.unquoted.argument.shell constant.other.option.shell"}},"match":"[\\\\t ]++(-)(\\\\w+)"}]}},"match":"(?:[\\\\t ]++-\\\\w+)*"},"simple_unquoted":{"match":"[^\\\\t\\\\n \\"$\\\\&-);<>\\\\\\\\\`|]","name":"string.unquoted.shell"},"special_expansion":{"match":"!|:[-=?]?|[*@]|##?|%%|[%/]","name":"keyword.operator.expansion.shell"},"start_of_command":{"match":"[\\\\t ]*+(?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;])(?!nocorrect |nocorrect\\\\t|nocorrect$|readonly |readonly\\\\t|readonly$|function |function\\\\t|function$|foreach |foreach\\\\t|foreach$|coproc |coproc\\\\t|coproc$|logout |logout\\\\t|logout$|export |export\\\\t|export$|select |select\\\\t|select$|repeat |repeat\\\\t|repeat$|pushd |pushd\\\\t|pushd$|until |until\\\\t|until$|while |while\\\\t|while$|local |local\\\\t|local$|case |case\\\\t|case$|done |done\\\\t|done$|elif |elif\\\\t|elif$|else |else\\\\t|else$|esac |esac\\\\t|esac$|popd |popd\\\\t|popd$|then |then\\\\t|then$|time |time\\\\t|time$|for |for\\\\t|for$|end |end\\\\t|end$|fi |fi\\\\t|fi$|do |do\\\\t|do$|in |in\\\\t|in$|if |if\\\\t|if$)(?!\\\\\\\\\\\\n?$)"},"string":{"patterns":[{"match":"\\\\\\\\.","name":"constant.character.escape.shell"},{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.quoted.single.shell"},{"begin":"\\\\$?\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.quoted.double.shell","patterns":[{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"include":"#variable"},{"include":"#interpolation"}]},{"begin":"\\\\$'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.quoted.single.dollar.shell","patterns":[{"match":"\\\\\\\\['\\\\\\\\abefnrtv]","name":"constant.character.escape.ansi-c.shell"},{"match":"\\\\\\\\[0-9]{3}\\"","name":"constant.character.escape.octal.shell"},{"match":"\\\\\\\\x\\\\h{2}\\"","name":"constant.character.escape.hex.shell"},{"match":"\\\\\\\\c.\\"","name":"constant.character.escape.control-char.shell"}]}]},"subshell_dollar":{"patterns":[{"begin":"\\\\$\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.subshell.single.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.subshell.single.shell"}},"name":"meta.scope.subshell","patterns":[{"include":"#parenthese"},{"include":"#initial_context"}]}]},"support":{"patterns":[{"match":"(?<=^|[\\\\&;\\\\s])[.:](?=[\\\\&;\\\\s]|$)","name":"support.function.builtin.shell"}]},"typical_statements":{"patterns":[{"include":"#assignment_statement"},{"include":"#case_statement"},{"include":"#for_statement"},{"include":"#while_statement"},{"include":"#function_definition"},{"include":"#command_statement"},{"include":"#line_continuation"},{"include":"#arithmetic_double"},{"include":"#normal_context"}]},"variable":{"patterns":[{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.parameter.positional.all.shell"},"2":{"name":"variable.parameter.positional.all.shell"}},"match":"(\\\\$)(@(?!\\\\w))"},{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.parameter.positional.shell"},"2":{"name":"variable.parameter.positional.shell"}},"match":"(\\\\$)([0-9](?!\\\\w))"},{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.language.special.shell"},"2":{"name":"variable.language.special.shell"}},"match":"(\\\\$)([-!#$*0?_](?!\\\\w))"},{"begin":"(\\\\$)(\\\\{)[\\\\t ]*+(?=\\\\d)","beginCaptures":{"1":{"name":"punctuation.definition.variable.shell variable.parameter.positional.shell"},"2":{"name":"punctuation.section.bracket.curly.variable.begin.shell punctuation.definition.variable.shell variable.parameter.positional.shell"}},"contentName":"meta.parameter-expansion","end":"}","endCaptures":{"0":{"name":"punctuation.section.bracket.curly.variable.end.shell punctuation.definition.variable.shell variable.parameter.positional.shell"}},"patterns":[{"include":"#special_expansion"},{"include":"#array_access_inline"},{"match":"[0-9]+","name":"variable.parameter.positional.shell"},{"match":"(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)","name":"variable.other.normal.shell"},{"include":"#variable"},{"include":"#string"}]},{"begin":"(\\\\$)(\\\\{)","beginCaptures":{"1":{"name":"punctuation.definition.variable.shell"},"2":{"name":"punctuation.section.bracket.curly.variable.begin.shell punctuation.definition.variable.shell"}},"contentName":"meta.parameter-expansion","end":"}","endCaptures":{"0":{"name":"punctuation.section.bracket.curly.variable.end.shell punctuation.definition.variable.shell"}},"patterns":[{"include":"#special_expansion"},{"include":"#array_access_inline"},{"match":"(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)","name":"variable.other.normal.shell"},{"include":"#variable"},{"include":"#string"}]},{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.other.normal.shell"},"2":{"name":"variable.other.normal.shell"}},"match":"(\\\\$)(\\\\w+(?!\\\\w))"}]},"while_statement":{"patterns":[{"begin":"\\\\b(while)\\\\b","beginCaptures":{"1":{"name":"keyword.control.while.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.while.shell","patterns":[{"include":"#line_continuation"},{"include":"#math_operators"},{"include":"#option"},{"include":"#simple_unquoted"},{"include":"#normal_context"},{"include":"#string"}]}]}},"scopeName":"source.shell","aliases":["bash","sh","shell","zsh"]}`))];export{t as n,n as t};
1
+ import{nn as e}from"./_DdVG8Rbg.js";var t=e({default:()=>n}),n=[Object.freeze(JSON.parse(`{"displayName":"Shell","name":"shellscript","patterns":[{"include":"#initial_context"}],"repository":{"alias_statement":{"begin":"[\\\\t ]*+(alias)[\\\\t ]*+((?:((?<!\\\\w)-\\\\w+)\\\\b[\\\\t ]*+)*)[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))","beginCaptures":{"1":{"name":"storage.type.alias.shell"},"2":{"patterns":[{"match":"(?<!\\\\w)-\\\\w+\\\\b","name":"string.unquoted.argument.shell constant.other.option.shell"}]},"3":{"name":"string.unquoted.argument.shell constant.other.option.shell"},"4":{"name":"variable.other.assignment.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"variable.other.assignment.shell"},"7":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"8":{"name":"punctuation.definition.array.access.shell"},"9":{"name":"keyword.operator.assignment.shell"},"10":{"name":"keyword.operator.assignment.compound.shell"},"11":{"name":"keyword.operator.assignment.compound.shell"}},"end":"(?=[\\\\t ]|$)|(?:(?:(?:(;)|(&&))|(\\\\|\\\\|))|(&))","endCaptures":{"1":{"name":"punctuation.terminator.statement.semicolon.shell"},"2":{"name":"punctuation.separator.statement.and.shell"},"3":{"name":"punctuation.separator.statement.or.shell"},"4":{"name":"punctuation.separator.statement.background.shell"}},"name":"meta.expression.assignment.alias.shell","patterns":[{"include":"#normal_context"}]},"argument":{"begin":"[\\\\t ]++(?![\\\\n#\\\\&(\\\\[|]|$|;)","beginCaptures":{},"end":"(?=[\\\\t \\\\&;|]|$|[\\\\n)\`])","endCaptures":{},"name":"meta.argument.shell","patterns":[{"include":"#argument_context"},{"include":"#line_continuation"}]},"argument_context":{"patterns":[{"captures":{"1":{"name":"string.unquoted.argument.shell","patterns":[{"match":"\\\\*","name":"variable.language.special.wildcard.shell"},{"include":"#variable"},{"include":"#numeric_literal"},{"captures":{"1":{"name":"constant.language.$1.shell"}},"match":"(?<!\\\\w)\\\\b(true|false)\\\\b(?!\\\\w)"}]}},"match":"[\\\\t ]*+([^\\\\t\\\\n \\"$\\\\&-);<>\\\\\\\\\`|]+(?!>))"},{"include":"#normal_context"}]},"arithmetic_double":{"patterns":[{"begin":"\\\\(\\\\(","beginCaptures":{"0":{"name":"punctuation.section.arithmetic.double.shell"}},"end":"\\\\)\\\\s*\\\\)","endCaptures":{"0":{"name":"punctuation.section.arithmetic.double.shell"}},"name":"meta.arithmetic.shell","patterns":[{"include":"#math"},{"include":"#string"}]}]},"arithmetic_no_dollar":{"patterns":[{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.section.arithmetic.single.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.section.arithmetic.single.shell"}},"name":"meta.arithmetic.shell","patterns":[{"include":"#math"},{"include":"#string"}]}]},"array_access_inline":{"captures":{"1":{"name":"punctuation.section.array.shell"},"2":{"patterns":[{"include":"#special_expansion"},{"include":"#string"},{"include":"#variable"}]},"3":{"name":"punctuation.section.array.shell"}},"match":"(\\\\[)([^]\\\\[]+)(])"},"array_value":{"begin":"[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))[\\\\t ]*+(\\\\()","beginCaptures":{"1":{"name":"variable.other.assignment.shell"},"2":{"name":"punctuation.definition.array.access.shell"},"3":{"name":"variable.other.assignment.shell"},"4":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"keyword.operator.assignment.shell"},"7":{"name":"keyword.operator.assignment.compound.shell"},"8":{"name":"keyword.operator.assignment.compound.shell"},"9":{"name":"punctuation.definition.array.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.array.shell"}},"patterns":[{"include":"#comment"},{"captures":{"1":{"name":"variable.other.assignment.array.shell entity.other.attribute-name.shell"},"2":{"name":"keyword.operator.assignment.shell punctuation.definition.assignment.shell"}},"match":"((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(=)"},{"captures":{"1":{"name":"punctuation.definition.bracket.named-array.shell"},"2":{"name":"string.unquoted.shell entity.other.attribute-name.bracket.shell"},"3":{"name":"punctuation.definition.bracket.named-array.shell"},"4":{"name":"punctuation.definition.assignment.shell"}},"match":"(\\\\[)(.+?)(])(=)"},{"include":"#normal_context"},{"include":"#simple_unquoted"}]},"assignment_statement":{"patterns":[{"include":"#array_value"},{"include":"#modified_assignment_statement"},{"include":"#normal_assignment_statement"}]},"basic_command_name":{"captures":{"1":{"name":"storage.modifier.$1.shell"},"2":{"name":"entity.name.function.call.shell entity.name.command.shell","patterns":[{"match":"(?<!\\\\w)(?:continue|return|break)(?!\\\\w)","name":"keyword.control.$0.shell"},{"match":"(?<!\\\\w)(?:unfunction|continue|autoload|unsetopt|bindkey|builtin|getopts|command|declare|unalias|history|unlimit|typeset|suspend|source|printf|unhash|disown|ulimit|return|which|alias|break|false|print|shift|times|umask|unset|read|type|exec|eval|wait|echo|dirs|jobs|kill|hash|stat|exit|test|trap|true|let|set|pwd|cd|fg|bg|fc|[.:])(?!/)(?!\\\\w)(?!-)","name":"support.function.builtin.shell"},{"include":"#variable"}]}},"match":"(?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;])(?!nocorrect |nocorrect\\\\t|nocorrect$|readonly |readonly\\\\t|readonly$|function |function\\\\t|function$|foreach |foreach\\\\t|foreach$|coproc |coproc\\\\t|coproc$|logout |logout\\\\t|logout$|export |export\\\\t|export$|select |select\\\\t|select$|repeat |repeat\\\\t|repeat$|pushd |pushd\\\\t|pushd$|until |until\\\\t|until$|while |while\\\\t|while$|local |local\\\\t|local$|case |case\\\\t|case$|done |done\\\\t|done$|elif |elif\\\\t|elif$|else |else\\\\t|else$|esac |esac\\\\t|esac$|popd |popd\\\\t|popd$|then |then\\\\t|then$|time |time\\\\t|time$|for |for\\\\t|for$|end |end\\\\t|end$|fi |fi\\\\t|fi$|do |do\\\\t|do$|in |in\\\\t|in$|if |if\\\\t|if$)(?:((?<=^|[\\\\t \\\\&;])(?:readonly|declare|typeset|export|local)(?=[\\\\t \\\\&;]|$))|((?![\\"']|\\\\\\\\\\\\n?$)[^\\\\t\\\\n\\\\r !\\"'<>]+?))(?:(?=[\\\\t ])|(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\))","name":"meta.statement.command.name.basic.shell"},"block_comment":{"begin":"\\\\s*+(/\\\\*)","beginCaptures":{"1":{"name":"punctuation.definition.comment.begin.shell"}},"end":"\\\\*/","endCaptures":{"0":{"name":"punctuation.definition.comment.end.shell"}},"name":"comment.block.shell"},"boolean":{"match":"\\\\b(?:true|false)\\\\b","name":"constant.language.$0.shell"},"case_statement":{"begin":"\\\\b(case)\\\\b[\\\\t ]*+(.+?)[\\\\t ]*+\\\\b(in)\\\\b","beginCaptures":{"1":{"name":"keyword.control.case.shell"},"2":{"patterns":[{"include":"#initial_context"}]},"3":{"name":"keyword.control.in.shell"}},"end":"\\\\besac\\\\b","endCaptures":{"0":{"name":"keyword.control.esac.shell"}},"name":"meta.case.shell","patterns":[{"include":"#comment"},{"captures":{"1":{"name":"keyword.operator.pattern.case.default.shell"}},"match":"[\\\\t ]*+(\\\\* *\\\\))"},{"begin":"(?<!\\\\))(?![\\\\t ]*+(?:esac\\\\b|$))","beginCaptures":{},"end":"(?=\\\\besac\\\\b)|(\\\\))","endCaptures":{"1":{"name":"keyword.operator.pattern.case.shell"}},"name":"meta.case.entry.pattern.shell","patterns":[{"include":"#case_statement_context"}]},{"begin":"(?<=\\\\))","beginCaptures":{},"end":"(;;)|(?=\\\\besac\\\\b)","endCaptures":{"1":{"name":"punctuation.terminator.statement.case.shell"}},"name":"meta.case.entry.body.shell","patterns":[{"include":"#typical_statements"},{"include":"#initial_context"}]}]},"case_statement_context":{"patterns":[{"match":"\\\\*","name":"variable.language.special.quantifier.star.shell keyword.operator.quantifier.star.shell punctuation.definition.arbitrary-repetition.shell punctuation.definition.regex.arbitrary-repetition.shell"},{"match":"\\\\+","name":"variable.language.special.quantifier.plus.shell keyword.operator.quantifier.plus.shell punctuation.definition.arbitrary-repetition.shell punctuation.definition.regex.arbitrary-repetition.shell"},{"match":"\\\\?","name":"variable.language.special.quantifier.question.shell keyword.operator.quantifier.question.shell punctuation.definition.arbitrary-repetition.shell punctuation.definition.regex.arbitrary-repetition.shell"},{"match":"@","name":"variable.language.special.at.shell keyword.operator.at.shell punctuation.definition.regex.at.shell"},{"match":"\\\\|","name":"keyword.operator.orvariable.language.special.or.shell keyword.operator.alternation.ruby.shell punctuation.definition.regex.alternation.shell punctuation.separator.regex.alternation.shell"},{"match":"\\\\\\\\.","name":"constant.character.escape.shell"},{"match":"(?<=\\\\tin| in|[\\\\t ]|;;)\\\\(","name":"keyword.operator.pattern.case.shell"},{"begin":"(?<=\\\\S)(\\\\()","beginCaptures":{"1":{"name":"punctuation.definition.group.shell punctuation.definition.regex.group.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.definition.regex.group.shell"}},"name":"meta.parenthese.shell","patterns":[{"include":"#case_statement_context"}]},{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.character-class.shell"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.character-class.shell"}},"name":"string.regexp.character-class.shell","patterns":[{"match":"\\\\\\\\.","name":"constant.character.escape.shell"}]},{"include":"#string"},{"match":"[^\\\\t\\\\n )*?@\\\\[|]","name":"string.unquoted.pattern.shell string.regexp.unquoted.shell"}]},"command_name_range":{"begin":"\\\\G","beginCaptures":{},"end":"(?=[\\\\t \\\\&;|]|$|[\\\\n)\`])|(?=<)","endCaptures":{},"name":"meta.statement.command.name.shell","patterns":[{"match":"(?<!\\\\w)(?:continue|return|break)(?!\\\\w)","name":"entity.name.function.call.shell entity.name.command.shell keyword.control.$0.shell"},{"match":"(?<!\\\\w)(?:unfunction|continue|autoload|unsetopt|bindkey|builtin|getopts|command|declare|unalias|history|unlimit|typeset|suspend|source|printf|unhash|disown|ulimit|return|which|alias|break|false|print|shift|times|umask|unset|read|type|exec|eval|wait|echo|dirs|jobs|kill|hash|stat|exit|test|trap|true|let|set|pwd|cd|fg|bg|fc|[.:])(?!/)(?!\\\\w)(?!-)","name":"entity.name.function.call.shell entity.name.command.shell support.function.builtin.shell"},{"include":"#variable"},{"captures":{"1":{"name":"entity.name.function.call.shell entity.name.command.shell"}},"match":"(?<!\\\\w)(?<=\\\\G|[\\"')}])([^\\\\t\\\\n\\\\r \\"\\\\&');->\`{|]+)"},{"begin":"(?:\\\\G|(?<![\\\\t\\\\n #\\\\&;{|]))(\\\\$?)((\\")|('))","beginCaptures":{"1":{"name":"meta.statement.command.name.quoted.shell punctuation.definition.string.shell entity.name.function.call.shell entity.name.command.shell"},"2":{},"3":{"name":"meta.statement.command.name.quoted.shell string.quoted.double.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"},"4":{"name":"meta.statement.command.name.quoted.shell string.quoted.single.shell punctuation.definition.string.begin.shell entity.name.function.call.shell entity.name.command.shell"}},"end":"(?<!\\\\G)(?<=\\\\2)","endCaptures":{},"patterns":[{"include":"#continuation_of_single_quoted_command_name"},{"include":"#continuation_of_double_quoted_command_name"}]},{"include":"#line_continuation"},{"include":"#simple_unquoted"}]},"command_statement":{"begin":"[\\\\t ]*+(?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;])(?!nocorrect |nocorrect\\\\t|nocorrect$|readonly |readonly\\\\t|readonly$|function |function\\\\t|function$|foreach |foreach\\\\t|foreach$|coproc |coproc\\\\t|coproc$|logout |logout\\\\t|logout$|export |export\\\\t|export$|select |select\\\\t|select$|repeat |repeat\\\\t|repeat$|pushd |pushd\\\\t|pushd$|until |until\\\\t|until$|while |while\\\\t|while$|local |local\\\\t|local$|case |case\\\\t|case$|done |done\\\\t|done$|elif |elif\\\\t|elif$|else |else\\\\t|else$|esac |esac\\\\t|esac$|popd |popd\\\\t|popd$|then |then\\\\t|then$|time |time\\\\t|time$|for |for\\\\t|for$|end |end\\\\t|end$|fi |fi\\\\t|fi$|do |do\\\\t|do$|in |in\\\\t|in$|if |if\\\\t|if$)(?!\\\\\\\\\\\\n?$)","beginCaptures":{},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.command.shell","patterns":[{"include":"#command_name_range"},{"include":"#line_continuation"},{"include":"#option"},{"include":"#argument"},{"include":"#string"},{"include":"#heredoc"}]},"comment":{"captures":{"1":{"name":"comment.line.number-sign.shell meta.shebang.shell"},"2":{"name":"punctuation.definition.comment.shebang.shell"},"3":{"name":"comment.line.number-sign.shell"},"4":{"name":"punctuation.definition.comment.shell"}},"match":"(?:^|[\\\\t ]++)(?:((#!).*)|((#).*))"},"comments":{"patterns":[{"include":"#block_comment"},{"include":"#line_comment"}]},"compound-command":{"patterns":[{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"name":"meta.scope.logical-expression.shell","patterns":[{"include":"#logical-expression"},{"include":"#initial_context"}]},{"begin":"(?<=\\\\s|^)\\\\{(?=\\\\s|$)","beginCaptures":{"0":{"name":"punctuation.definition.group.shell"}},"end":"(?<=^|;)\\\\s*(})","endCaptures":{"1":{"name":"punctuation.definition.group.shell"}},"name":"meta.scope.group.shell","patterns":[{"include":"#initial_context"}]}]},"continuation_of_double_quoted_command_name":{"begin":"\\\\G(?<=\\")","beginCaptures":{},"contentName":"meta.statement.command.name.continuation string.quoted.double entity.name.function.call entity.name.command","end":"\\"","endCaptures":{"0":{"name":"string.quoted.double.shell punctuation.definition.string.end.shell entity.name.function.call.shell entity.name.command.shell"}},"patterns":[{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"include":"#variable"},{"include":"#interpolation"}]},"continuation_of_single_quoted_command_name":{"begin":"\\\\G(?<=')","beginCaptures":{},"contentName":"meta.statement.command.name.continuation string.quoted.single entity.name.function.call entity.name.command","end":"'","endCaptures":{"0":{"name":"string.quoted.single.shell punctuation.definition.string.end.shell entity.name.function.call.shell entity.name.command.shell"}}},"custom_command_names":{"patterns":[]},"custom_commands":{"patterns":[]},"double_quote_context":{"patterns":[{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"include":"#variable"},{"include":"#interpolation"}]},"double_quote_escape_char":{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},"floating_keyword":{"patterns":[{"match":"(?<=^|[\\\\t \\\\&;])(?:then|elif|else|done|end|do|if|fi)(?=[\\\\t \\\\&;]|$)","name":"keyword.control.$0.shell"}]},"for_statement":{"patterns":[{"begin":"\\\\b(for)\\\\b[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))[\\\\t ]*+\\\\b(in)\\\\b","beginCaptures":{"1":{"name":"keyword.control.for.shell"},"2":{"name":"variable.other.for.shell"},"3":{"name":"keyword.control.in.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.for.in.shell","patterns":[{"include":"#string"},{"include":"#simple_unquoted"},{"include":"#normal_context"}]},{"begin":"\\\\b(for)\\\\b","beginCaptures":{"1":{"name":"keyword.control.for.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.for.shell","patterns":[{"include":"#arithmetic_double"},{"include":"#normal_context"}]}]},"function_definition":{"applyEndPatternLast":1,"begin":"[\\\\t ]*+(?:\\\\b(function)\\\\b[\\\\t ]*+([^\\\\t\\\\n\\\\r \\"'()=]+)(?:(\\\\()[\\\\t ]*+(\\\\)))?|([^\\\\t\\\\n\\\\r \\"'()=]+)[\\\\t ]*+(\\\\()[\\\\t ]*+(\\\\)))","beginCaptures":{"1":{"name":"storage.type.function.shell"},"2":{"name":"entity.name.function.shell"},"3":{"name":"punctuation.definition.arguments.shell"},"4":{"name":"punctuation.definition.arguments.shell"},"5":{"name":"entity.name.function.shell"},"6":{"name":"punctuation.definition.arguments.shell"},"7":{"name":"punctuation.definition.arguments.shell"}},"end":"(?<=[)}])","endCaptures":{},"name":"meta.function.shell","patterns":[{"match":"\\\\G[\\\\t\\\\n ]"},{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"name":"meta.function.body.shell","patterns":[{"include":"#initial_context"}]},{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.group.shell punctuation.section.function.definition.shell"}},"name":"meta.function.body.shell","patterns":[{"include":"#initial_context"}]},{"include":"#initial_context"}]},"heredoc":{"patterns":[{"begin":"((?<!<)<<-)[\\\\t ]*+([\\"'])[\\\\t ]*+([^\\"']+?)(?=[\\"\\\\&';<\\\\s])(\\\\2)(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.quote.shell"},"3":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"4":{"name":"punctuation.definition.string.heredoc.quote.shell"},"5":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.quoted.heredoc.indent.$3","end":"^\\\\t*\\\\3(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.$0.shell"}},"patterns":[]},{"begin":"((?<!<)<<(?!<))[\\\\t ]*+([\\"'])[\\\\t ]*+([^\\"']+?)(?=[\\"\\\\&';<\\\\s])(\\\\2)(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.quote.shell"},"3":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"4":{"name":"punctuation.definition.string.heredoc.quote.shell"},"5":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.quoted.heredoc.no-indent.$3","end":"^\\\\3(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.delimiter.shell"}},"patterns":[]},{"begin":"((?<!<)<<-)[\\\\t ]*+([^\\\\t \\"']+)(?=[\\"\\\\&';<\\\\s])(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"3":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.unquoted.heredoc.indent.$2","end":"^\\\\t*\\\\2(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.delimiter.shell"}},"patterns":[{"include":"#double_quote_escape_char"},{"include":"#variable"},{"include":"#interpolation"}]},{"begin":"((?<!<)<<(?!<))[\\\\t ]*+([^\\\\t \\"']+)(?=[\\"\\\\&';<\\\\s])(.*)","beginCaptures":{"1":{"name":"keyword.operator.heredoc.shell"},"2":{"name":"punctuation.definition.string.heredoc.delimiter.shell"},"3":{"patterns":[{"include":"#redirect_fix"},{"include":"#typical_statements"}]}},"contentName":"string.unquoted.heredoc.no-indent.$2","end":"^\\\\2(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"punctuation.definition.string.heredoc.delimiter.shell"}},"patterns":[{"include":"#double_quote_escape_char"},{"include":"#variable"},{"include":"#interpolation"}]}]},"herestring":{"patterns":[{"begin":"(<<<)\\\\s*(('))","beginCaptures":{"1":{"name":"keyword.operator.herestring.shell"},"2":{"name":"string.quoted.single.shell"},"3":{"name":"punctuation.definition.string.begin.shell"}},"contentName":"string.quoted.single.shell","end":"(')","endCaptures":{"0":{"name":"string.quoted.single.shell"},"1":{"name":"punctuation.definition.string.end.shell"}},"name":"meta.herestring.shell"},{"begin":"(<<<)\\\\s*((\\"))","beginCaptures":{"1":{"name":"keyword.operator.herestring.shell"},"2":{"name":"string.quoted.double.shell"},"3":{"name":"punctuation.definition.string.begin.shell"}},"contentName":"string.quoted.double.shell","end":"(\\")","endCaptures":{"0":{"name":"string.quoted.double.shell"},"1":{"name":"punctuation.definition.string.end.shell"}},"name":"meta.herestring.shell","patterns":[{"include":"#double_quote_context"}]},{"captures":{"1":{"name":"keyword.operator.herestring.shell"},"2":{"name":"string.unquoted.herestring.shell","patterns":[{"include":"#initial_context"}]}},"match":"(<<<)\\\\s*(([^)\\\\\\\\\\\\s]|\\\\\\\\.)+)","name":"meta.herestring.shell"}]},"initial_context":{"patterns":[{"include":"#comment"},{"include":"#pipeline"},{"include":"#normal_statement_seperator"},{"include":"#logical_expression_double"},{"include":"#logical_expression_single"},{"include":"#assignment_statement"},{"include":"#case_statement"},{"include":"#for_statement"},{"include":"#loop"},{"include":"#function_definition"},{"include":"#line_continuation"},{"include":"#arithmetic_double"},{"include":"#misc_ranges"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#redirection"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#alias_statement"},{"include":"#normal_statement"},{"include":"#string"},{"include":"#support"}]},"inline_comment":{"captures":{"1":{"name":"comment.block.shell punctuation.definition.comment.begin.shell"},"2":{"name":"comment.block.shell"},"3":{"patterns":[{"match":"\\\\*/","name":"comment.block.shell punctuation.definition.comment.end.shell"},{"match":"\\\\*","name":"comment.block.shell"}]}},"match":"(/\\\\*)((?:[^*]|\\\\*++[^/])*+(\\\\*++/))"},"interpolation":{"patterns":[{"include":"#arithmetic_dollar"},{"include":"#subshell_dollar"},{"begin":"\`","beginCaptures":{"0":{"name":"punctuation.definition.evaluation.backticks.shell"}},"end":"\`","endCaptures":{"0":{"name":"punctuation.definition.evaluation.backticks.shell"}},"name":"string.interpolated.backtick.shell","patterns":[{"match":"\\\\\\\\[$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"begin":"(?<=\\\\W)(?=#)(?!#\\\\{)","beginCaptures":{"1":{"name":"punctuation.whitespace.comment.leading.shell"}},"end":"(?!\\\\G)","patterns":[{"begin":"#","beginCaptures":{"0":{"name":"punctuation.definition.comment.shell"}},"end":"(?=\`)","name":"comment.line.number-sign.shell"}]},{"include":"#initial_context"}]}]},"keyword":{"patterns":[{"match":"(?<=^|[\\\\&;\\\\s])(then|else|elif|fi|for|in|do|done|select|continue|esac|while|until|return)(?=[\\\\&;\\\\s]|$)","name":"keyword.control.shell"},{"match":"(?<=^|[\\\\&;\\\\s])(?:export|declare|typeset|local|readonly)(?=[\\\\&;\\\\s]|$)","name":"storage.modifier.shell"}]},"line_comment":{"begin":"\\\\s*+(//)","beginCaptures":{"1":{"name":"punctuation.definition.comment.shell"}},"end":"(?<=\\\\n)(?<!\\\\\\\\\\\\n)","endCaptures":{},"name":"comment.line.double-slash.shell","patterns":[{"include":"#line_continuation_character"}]},"line_continuation":{"match":"\\\\\\\\(?=\\\\n)","name":"constant.character.escape.line-continuation.shell"},"logical-expression":{"patterns":[{"include":"#arithmetic_no_dollar"},{"match":"=[=~]?|!=?|[<>]|&&|\\\\|\\\\|","name":"keyword.operator.logical.shell"},{"match":"(?<!\\\\S)-(nt|ot|ef|eq|ne|l[et]|g[et]|[GLNOSa-hknopr-uwxz])\\\\b","name":"keyword.operator.logical.shell"}]},"logical_expression_context":{"patterns":[{"include":"#regex_comparison"},{"include":"#arithmetic_no_dollar"},{"include":"#logical-expression"},{"include":"#logical_expression_single"},{"include":"#logical_expression_double"},{"include":"#comment"},{"include":"#boolean"},{"include":"#redirect_number"},{"include":"#numeric_literal"},{"include":"#pipeline"},{"include":"#normal_statement_seperator"},{"include":"#string"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#support"}]},"logical_expression_double":{"begin":"\\\\[\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"end":"]]","endCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"name":"meta.scope.logical-expression.shell","patterns":[{"include":"#logical_expression_context"}]},"logical_expression_single":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.logical-expression.shell"}},"name":"meta.scope.logical-expression.shell","patterns":[{"include":"#logical_expression_context"}]},"loop":{"patterns":[{"begin":"(?<=^|[\\\\&;\\\\s])(for)\\\\s+(.+?)\\\\s+(in)(?=[\\\\&;\\\\s]|$)","beginCaptures":{"1":{"name":"keyword.control.shell"},"2":{"name":"variable.other.loop.shell","patterns":[{"include":"#string"}]},"3":{"name":"keyword.control.shell"}},"end":"(?<=^|[\\\\&;\\\\s])done(?=[\\\\&;\\\\s]|$|\\\\))","endCaptures":{"0":{"name":"keyword.control.shell"}},"name":"meta.scope.for-in-loop.shell","patterns":[{"include":"#initial_context"}]},{"begin":"(?<=^|[\\\\&;\\\\s])(while|until)(?=[\\\\&;\\\\s]|$)","beginCaptures":{"1":{"name":"keyword.control.shell"}},"end":"(?<=^|[\\\\&;\\\\s])done(?=[\\\\&;\\\\s]|$|\\\\))","endCaptures":{"0":{"name":"keyword.control.shell"}},"name":"meta.scope.while-loop.shell","patterns":[{"include":"#initial_context"}]},{"begin":"(?<=^|[\\\\&;\\\\s])(select)\\\\s+((?:[^\\\\\\\\\\\\s]|\\\\\\\\.)+)(?=[\\\\&;\\\\s]|$)","beginCaptures":{"1":{"name":"keyword.control.shell"},"2":{"name":"variable.other.loop.shell"}},"end":"(?<=^|[\\\\&;\\\\s])(done)(?=[\\\\&;\\\\s]|$|\\\\))","endCaptures":{"1":{"name":"keyword.control.shell"}},"name":"meta.scope.select-block.shell","patterns":[{"include":"#initial_context"}]},{"begin":"(?<=^|[\\\\&;\\\\s])if(?=[\\\\&;\\\\s]|$)","beginCaptures":{"0":{"name":"keyword.control.if.shell"}},"end":"(?<=^|[\\\\&;\\\\s])fi(?=[\\\\&;\\\\s]|$)","endCaptures":{"0":{"name":"keyword.control.fi.shell"}},"name":"meta.scope.if-block.shell","patterns":[{"include":"#initial_context"}]}]},"math":{"patterns":[{"include":"#variable"},{"match":"\\\\+{1,2}|-{1,2}|[!~]|\\\\*{1,2}|[%/]|<[<=]?|>[=>]?|==|!=|^|\\\\|{1,2}|&{1,2}|[,:=?]|[-%\\\\&*+/^|]=|<<=|>>=","name":"keyword.operator.arithmetic.shell"},{"match":"0[Xx]\\\\h+","name":"constant.numeric.hex.shell"},{"match":";","name":"punctuation.separator.semicolon.range"},{"match":"0\\\\d+","name":"constant.numeric.octal.shell"},{"match":"\\\\d{1,2}#[0-9@-Z_a-z]+","name":"constant.numeric.other.shell"},{"match":"\\\\d+","name":"constant.numeric.integer.shell"},{"match":"(?<!\\\\w)[0-9A-Z_a-z]+(?!\\\\w)","name":"variable.other.normal.shell"}]},"math_operators":{"patterns":[{"match":"\\\\+{1,2}|-{1,2}|[!~]|\\\\*{1,2}|[%/]|<[<=]?|>[=>]?|==|!=|^|\\\\|{1,2}|&{1,2}|[,:=?]|[-%\\\\&*+/^|]=|<<=|>>=","name":"keyword.operator.arithmetic.shell"},{"match":"0[Xx]\\\\h+","name":"constant.numeric.hex.shell"},{"match":"0\\\\d+","name":"constant.numeric.octal.shell"},{"match":"\\\\d{1,2}#[0-9@-Z_a-z]+","name":"constant.numeric.other.shell"},{"match":"\\\\d+","name":"constant.numeric.integer.shell"}]},"misc_ranges":{"patterns":[{"include":"#logical_expression_single"},{"include":"#logical_expression_double"},{"include":"#subshell_dollar"},{"begin":"(?<![^\\\\t ])(\\\\{)(?![$\\\\w])","beginCaptures":{"1":{"name":"punctuation.definition.group.shell"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.group.shell"}},"name":"meta.scope.group.shell","patterns":[{"include":"#initial_context"}]}]},"modified_assignment_statement":{"begin":"(?<=^|[\\\\t \\\\&;])(?:readonly|declare|typeset|export|local)(?=[\\\\t \\\\&;]|$)","beginCaptures":{"0":{"name":"storage.modifier.$0.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.shell meta.expression.assignment.modified.shell","patterns":[{"match":"(?<!\\\\w)-\\\\w+\\\\b","name":"string.unquoted.argument.shell constant.other.option.shell"},{"include":"#array_value"},{"captures":{"1":{"name":"variable.other.assignment.shell"},"2":{"name":"punctuation.definition.array.access.shell"},"3":{"name":"variable.other.assignment.shell"},"4":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"keyword.operator.assignment.shell"},"7":{"name":"keyword.operator.assignment.compound.shell"},"8":{"name":"keyword.operator.assignment.compound.shell"},"9":{"name":"constant.numeric.shell constant.numeric.hex.shell"},"10":{"name":"constant.numeric.shell constant.numeric.octal.shell"},"11":{"name":"constant.numeric.shell constant.numeric.other.shell"},"12":{"name":"constant.numeric.shell constant.numeric.decimal.shell"},"13":{"name":"constant.numeric.shell constant.numeric.version.shell"},"14":{"name":"constant.numeric.shell constant.numeric.integer.shell"}},"match":"((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))?(?:(?<=[\\\\t =]|^|[(\\\\[{])(?:(?:(?:(?:(?:(0[Xx]\\\\h+)|(0\\\\d+))|(\\\\d{1,2}#[0-9@-Z_a-z]+))|(-?\\\\d+\\\\.\\\\d+))|(-?\\\\d+(?:\\\\.\\\\d+)+))|(-?\\\\d+))(?=[\\\\t ]|$|[);}]))?"},{"include":"#normal_context"}]},"modifiers":{"match":"(?<=^|[\\\\t \\\\&;])(?:readonly|declare|typeset|export|local)(?=[\\\\t \\\\&;]|$)","name":"storage.modifier.$0.shell"},"normal_assignment_statement":{"begin":"[\\\\t ]*+((?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w))(?:(\\\\[)((?:(?:\\\\$?(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)|@)|\\\\*)|(-?\\\\d+))(]))?(?:(?:(=)|(\\\\+=))|(-=))","beginCaptures":{"1":{"name":"variable.other.assignment.shell"},"2":{"name":"punctuation.definition.array.access.shell"},"3":{"name":"variable.other.assignment.shell"},"4":{"name":"constant.numeric.shell constant.numeric.integer.shell"},"5":{"name":"punctuation.definition.array.access.shell"},"6":{"name":"keyword.operator.assignment.shell"},"7":{"name":"keyword.operator.assignment.compound.shell"},"8":{"name":"keyword.operator.assignment.compound.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.expression.assignment.shell","patterns":[{"include":"#comment"},{"include":"#string"},{"include":"#normal_assignment_statement"},{"begin":"(?<=[\\\\t ])(?![\\\\t ]|\\\\w+=)","beginCaptures":{},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.command.env.shell","patterns":[{"include":"#command_name_range"},{"include":"#line_continuation"},{"include":"#option"},{"include":"#argument"},{"include":"#string"}]},{"include":"#simple_unquoted"},{"include":"#normal_context"}]},"normal_context":{"patterns":[{"include":"#comment"},{"include":"#pipeline"},{"include":"#normal_statement_seperator"},{"include":"#misc_ranges"},{"include":"#boolean"},{"include":"#redirect_number"},{"include":"#numeric_literal"},{"include":"#string"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#redirection"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#support"},{"include":"#parenthese"}]},"normal_statement":{"begin":"(?!^[\\\\t ]*+$)(?:(?<=(?:^until| until|\\\\tuntil|^while| while|\\\\twhile|^elif| elif|\\\\telif|^else| else|\\\\telse|^then| then|\\\\tthen|^do| do|\\\\tdo|^if| if|\\\\tif) )|(?<=^|[!\\\\&(;\`{|]))[\\\\t ]*+(?!nocorrect\\\\W|nocorrect\\\\$|function\\\\W|function\\\\$|foreach\\\\W|foreach\\\\$|repeat\\\\W|repeat\\\\$|logout\\\\W|logout\\\\$|coproc\\\\W|coproc\\\\$|select\\\\W|select\\\\$|while\\\\W|while\\\\$|pushd\\\\W|pushd\\\\$|until\\\\W|until\\\\$|case\\\\W|case\\\\$|done\\\\W|done\\\\$|elif\\\\W|elif\\\\$|else\\\\W|else\\\\$|esac\\\\W|esac\\\\$|popd\\\\W|popd\\\\$|then\\\\W|then\\\\$|time\\\\W|time\\\\$|for\\\\W|for\\\\$|end\\\\W|end\\\\$|fi\\\\W|fi\\\\$|do\\\\W|do\\\\$|in\\\\W|in\\\\$|if\\\\W|if\\\\$)","beginCaptures":{},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.statement.shell","patterns":[{"include":"#typical_statements"}]},"normal_statement_seperator":{"captures":{"1":{"name":"punctuation.terminator.statement.semicolon.shell"},"2":{"name":"punctuation.separator.statement.and.shell"},"3":{"name":"punctuation.separator.statement.or.shell"},"4":{"name":"punctuation.separator.statement.background.shell"}},"match":"(?:(?:(;)|(&&))|(\\\\|\\\\|))|(&)"},"numeric_literal":{"captures":{"1":{"name":"constant.numeric.shell constant.numeric.hex.shell"},"2":{"name":"constant.numeric.shell constant.numeric.octal.shell"},"3":{"name":"constant.numeric.shell constant.numeric.other.shell"},"4":{"name":"constant.numeric.shell constant.numeric.decimal.shell"},"5":{"name":"constant.numeric.shell constant.numeric.version.shell"},"6":{"name":"constant.numeric.shell constant.numeric.integer.shell"}},"match":"(?<=[\\\\t =]|^|[(\\\\[{])(?:(?:(?:(?:(?:(0[Xx]\\\\h+)|(0\\\\d+))|(\\\\d{1,2}#[0-9@-Z_a-z]+))|(-?\\\\d+\\\\.\\\\d+))|(-?\\\\d+(?:\\\\.\\\\d+)+))|(-?\\\\d+))(?=[\\\\t ]|$|[);}])"},"option":{"begin":"[\\\\t ]++(-)((?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;]))","beginCaptures":{"1":{"name":"string.unquoted.argument.shell constant.other.option.dash.shell"},"2":{"name":"string.unquoted.argument.shell constant.other.option.shell"}},"contentName":"string.unquoted.argument constant.other.option","end":"(?=[\\\\t ])|(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"patterns":[{"include":"#option_context"}]},"option_context":{"patterns":[{"include":"#misc_ranges"},{"include":"#string"},{"include":"#variable"},{"include":"#interpolation"},{"include":"#heredoc"},{"include":"#herestring"},{"include":"#redirection"},{"include":"#pathname"},{"include":"#floating_keyword"},{"include":"#support"}]},"parenthese":{"patterns":[{"begin":"\\\\(","beginCaptures":{"0":{"name":"punctuation.section.parenthese.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.section.parenthese.shell"}},"name":"meta.parenthese.group.shell","patterns":[{"include":"#initial_context"}]}]},"pathname":{"patterns":[{"match":"(?<=[:=\\\\s]|^)~","name":"keyword.operator.tilde.shell"},{"match":"[*?]","name":"keyword.operator.glob.shell"},{"begin":"([!*+?@])(\\\\()","beginCaptures":{"1":{"name":"keyword.operator.extglob.shell"},"2":{"name":"punctuation.definition.extglob.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.extglob.shell"}},"name":"meta.structure.extglob.shell","patterns":[{"include":"#initial_context"}]}]},"pipeline":{"patterns":[{"match":"(?<=^|[\\\\&;\\\\s])(time)(?=[\\\\&;\\\\s]|$)","name":"keyword.other.shell"},{"match":"[!|]","name":"keyword.operator.pipe.shell"}]},"redirect_fix":{"captures":{"1":{"name":"keyword.operator.redirect.shell"},"2":{"name":"string.unquoted.argument.shell"}},"match":"(>>?)[\\\\t ]*+([^\\\\t\\\\n \\"$\\\\&-);<>\\\\\\\\\`|]+)"},"redirect_number":{"captures":{"1":{"name":"keyword.operator.redirect.stdout.shell"},"2":{"name":"keyword.operator.redirect.stderr.shell"},"3":{"name":"keyword.operator.redirect.$3.shell"}},"match":"(?<=[\\\\t ])(?:(1)|(2)|(\\\\d+))(?=>)"},"redirection":{"patterns":[{"begin":"[<>]\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.interpolated.process-substitution.shell","patterns":[{"include":"#initial_context"}]},{"match":"(?<![<>])(&>|\\\\d*>&\\\\d*|\\\\d*(>>|[<>])|\\\\d*<&|\\\\d*<>)(?![<>])","name":"keyword.operator.redirect.shell"}]},"regex_comparison":{"match":"=~","name":"keyword.operator.logical.regex.shell"},"regexp":{"patterns":[{"match":".+"}]},"simple_options":{"captures":{"0":{"patterns":[{"captures":{"1":{"name":"string.unquoted.argument.shell constant.other.option.dash.shell"},"2":{"name":"string.unquoted.argument.shell constant.other.option.shell"}},"match":"[\\\\t ]++(-)(\\\\w+)"}]}},"match":"(?:[\\\\t ]++-\\\\w+)*"},"simple_unquoted":{"match":"[^\\\\t\\\\n \\"$\\\\&-);<>\\\\\\\\\`|]","name":"string.unquoted.shell"},"special_expansion":{"match":"!|:[-=?]?|[*@]|##?|%%|[%/]","name":"keyword.operator.expansion.shell"},"start_of_command":{"match":"[\\\\t ]*+(?![\\\\n!#\\\\&()<>\\\\[{|]|$|[\\\\t ;])(?!nocorrect |nocorrect\\\\t|nocorrect$|readonly |readonly\\\\t|readonly$|function |function\\\\t|function$|foreach |foreach\\\\t|foreach$|coproc |coproc\\\\t|coproc$|logout |logout\\\\t|logout$|export |export\\\\t|export$|select |select\\\\t|select$|repeat |repeat\\\\t|repeat$|pushd |pushd\\\\t|pushd$|until |until\\\\t|until$|while |while\\\\t|while$|local |local\\\\t|local$|case |case\\\\t|case$|done |done\\\\t|done$|elif |elif\\\\t|elif$|else |else\\\\t|else$|esac |esac\\\\t|esac$|popd |popd\\\\t|popd$|then |then\\\\t|then$|time |time\\\\t|time$|for |for\\\\t|for$|end |end\\\\t|end$|fi |fi\\\\t|fi$|do |do\\\\t|do$|in |in\\\\t|in$|if |if\\\\t|if$)(?!\\\\\\\\\\\\n?$)"},"string":{"patterns":[{"match":"\\\\\\\\.","name":"constant.character.escape.shell"},{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.quoted.single.shell"},{"begin":"\\\\$?\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.quoted.double.shell","patterns":[{"match":"\\\\\\\\[\\\\n\\"$\\\\\\\\\`]","name":"constant.character.escape.shell"},{"include":"#variable"},{"include":"#interpolation"}]},{"begin":"\\\\$'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.shell"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.shell"}},"name":"string.quoted.single.dollar.shell","patterns":[{"match":"\\\\\\\\['\\\\\\\\abefnrtv]","name":"constant.character.escape.ansi-c.shell"},{"match":"\\\\\\\\[0-9]{3}\\"","name":"constant.character.escape.octal.shell"},{"match":"\\\\\\\\x\\\\h{2}\\"","name":"constant.character.escape.hex.shell"},{"match":"\\\\\\\\c.\\"","name":"constant.character.escape.control-char.shell"}]}]},"subshell_dollar":{"patterns":[{"begin":"\\\\$\\\\(","beginCaptures":{"0":{"name":"punctuation.definition.subshell.single.shell"}},"end":"\\\\)","endCaptures":{"0":{"name":"punctuation.definition.subshell.single.shell"}},"name":"meta.scope.subshell","patterns":[{"include":"#parenthese"},{"include":"#initial_context"}]}]},"support":{"patterns":[{"match":"(?<=^|[\\\\&;\\\\s])[.:](?=[\\\\&;\\\\s]|$)","name":"support.function.builtin.shell"}]},"typical_statements":{"patterns":[{"include":"#assignment_statement"},{"include":"#case_statement"},{"include":"#for_statement"},{"include":"#while_statement"},{"include":"#function_definition"},{"include":"#command_statement"},{"include":"#line_continuation"},{"include":"#arithmetic_double"},{"include":"#normal_context"}]},"variable":{"patterns":[{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.parameter.positional.all.shell"},"2":{"name":"variable.parameter.positional.all.shell"}},"match":"(\\\\$)(@(?!\\\\w))"},{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.parameter.positional.shell"},"2":{"name":"variable.parameter.positional.shell"}},"match":"(\\\\$)([0-9](?!\\\\w))"},{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.language.special.shell"},"2":{"name":"variable.language.special.shell"}},"match":"(\\\\$)([-!#$*0?_](?!\\\\w))"},{"begin":"(\\\\$)(\\\\{)[\\\\t ]*+(?=\\\\d)","beginCaptures":{"1":{"name":"punctuation.definition.variable.shell variable.parameter.positional.shell"},"2":{"name":"punctuation.section.bracket.curly.variable.begin.shell punctuation.definition.variable.shell variable.parameter.positional.shell"}},"contentName":"meta.parameter-expansion","end":"}","endCaptures":{"0":{"name":"punctuation.section.bracket.curly.variable.end.shell punctuation.definition.variable.shell variable.parameter.positional.shell"}},"patterns":[{"include":"#special_expansion"},{"include":"#array_access_inline"},{"match":"[0-9]+","name":"variable.parameter.positional.shell"},{"match":"(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)","name":"variable.other.normal.shell"},{"include":"#variable"},{"include":"#string"}]},{"begin":"(\\\\$)(\\\\{)","beginCaptures":{"1":{"name":"punctuation.definition.variable.shell"},"2":{"name":"punctuation.section.bracket.curly.variable.begin.shell punctuation.definition.variable.shell"}},"contentName":"meta.parameter-expansion","end":"}","endCaptures":{"0":{"name":"punctuation.section.bracket.curly.variable.end.shell punctuation.definition.variable.shell"}},"patterns":[{"include":"#special_expansion"},{"include":"#array_access_inline"},{"match":"(?<!\\\\w)[-0-9A-Z_a-z]+(?!\\\\w)","name":"variable.other.normal.shell"},{"include":"#variable"},{"include":"#string"}]},{"captures":{"1":{"name":"punctuation.definition.variable.shell variable.other.normal.shell"},"2":{"name":"variable.other.normal.shell"}},"match":"(\\\\$)(\\\\w+(?!\\\\w))"}]},"while_statement":{"patterns":[{"begin":"\\\\b(while)\\\\b","beginCaptures":{"1":{"name":"keyword.control.while.shell"}},"end":"(?=[\\\\n\\\\&);\`{|}]|[\\\\t ]*#|])(?<!\\\\\\\\)","endCaptures":{},"name":"meta.while.shell","patterns":[{"include":"#line_continuation"},{"include":"#math_operators"},{"include":"#option"},{"include":"#simple_unquoted"},{"include":"#normal_context"},{"include":"#string"}]}]}},"scopeName":"source.shell","aliases":["bash","sh","shell","zsh"]}`))];export{t as n,n as t};