@dylanpiercey/work 0.0.21 → 0.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.mjs +215 -130
- package/dist/public/assets/{_BBCthCRB.js → _5l_SLhQO.js} +2 -2
- package/dist/public/assets/{_BBCthCRB.js.map → _5l_SLhQO.js.map} +1 -1
- package/dist/public/assets/{_D_8pG7bS2.js → _B22N0jOE2.js} +2 -2
- package/dist/public/assets/{_D_8pG7bS2.js.map → _B22N0jOE2.js.map} +1 -1
- package/dist/public/assets/{_CjNZdOEs.js → _B6O2FrRn.js} +2 -2
- package/dist/public/assets/{_CjNZdOEs.js.map → _B6O2FrRn.js.map} +1 -1
- package/dist/public/assets/{_C3OrD7LT.js → _B70XmXCb.js} +2 -2
- package/dist/public/assets/{_C3OrD7LT.js.map → _B70XmXCb.js.map} +1 -1
- package/dist/public/assets/{_Cbg9-SI_2.js → _BHjp4Wp62.js} +2 -2
- package/dist/public/assets/{_Cbg9-SI_2.js.map → _BHjp4Wp62.js.map} +1 -1
- package/dist/public/assets/{_cZMSm0LN.js → _BIU5EmFO.js} +2 -2
- package/dist/public/assets/{_cZMSm0LN.js.map → _BIU5EmFO.js.map} +1 -1
- package/dist/public/assets/{_CFwjuNga.js → _BNFIxlJR.js} +2 -2
- package/dist/public/assets/{_CFwjuNga.js.map → _BNFIxlJR.js.map} +1 -1
- package/dist/public/assets/{_H-G61tx0.js → _BURv1zn0.js} +2 -2
- package/dist/public/assets/{_H-G61tx0.js.map → _BURv1zn0.js.map} +1 -1
- package/dist/public/assets/{_DT71qSJE2.js → _BX5xyzBY2.js} +2 -2
- package/dist/public/assets/{_DT71qSJE2.js.map → _BX5xyzBY2.js.map} +1 -1
- package/dist/public/assets/{_C4JQ0avI.js → _Ba-VBf2z.js} +2 -2
- package/dist/public/assets/{_C4JQ0avI.js.map → _Ba-VBf2z.js.map} +1 -1
- package/dist/public/assets/{_BG21uqHk2.js → _BdVPUTjx2.js} +2 -2
- package/dist/public/assets/{_BG21uqHk2.js.map → _BdVPUTjx2.js.map} +1 -1
- package/dist/public/assets/{_C5tw5jaH2.js → _Bg1unGUo2.js} +2 -2
- package/dist/public/assets/{_C5tw5jaH2.js.map → _Bg1unGUo2.js.map} +1 -1
- package/dist/public/assets/{_JmyDHQ3S2.js → _BgMhxgll2.js} +2 -2
- package/dist/public/assets/{_JmyDHQ3S2.js.map → _BgMhxgll2.js.map} +1 -1
- package/dist/public/assets/{_m1KNq0Gx.js → _BlN6B4lX.js} +2 -2
- package/dist/public/assets/{_m1KNq0Gx.js.map → _BlN6B4lX.js.map} +1 -1
- package/dist/public/assets/{_CRMMWY-q.js → _BnZ5hdB-.js} +2 -2
- package/dist/public/assets/{_CRMMWY-q.js.map → _BnZ5hdB-.js.map} +1 -1
- package/dist/public/assets/{_BpxV-2f3.js → _BnlyQRjI.js} +2 -2
- package/dist/public/assets/{_BpxV-2f3.js.map → _BnlyQRjI.js.map} +1 -1
- package/dist/public/assets/{_DLg1-IRM.js → _BpZ3p5fk.js} +2 -2
- package/dist/public/assets/{_DLg1-IRM.js.map → _BpZ3p5fk.js.map} +1 -1
- package/dist/public/assets/{_DK5es8xg.js → _Bq8AEuDG.js} +2 -2
- package/dist/public/assets/{_DK5es8xg.js.map → _Bq8AEuDG.js.map} +1 -1
- package/dist/public/assets/{_DGZCHdAh.js → _BqBvsjYd.js} +2 -2
- package/dist/public/assets/{_DGZCHdAh.js.map → _BqBvsjYd.js.map} +1 -1
- package/dist/public/assets/{_DVIw_RgW2.js → _Bs98qN5-2.js} +2 -2
- package/dist/public/assets/{_DVIw_RgW2.js.map → _Bs98qN5-2.js.map} +1 -1
- package/dist/public/assets/{_Bo2t_uNU.js → _Bu7qESl9.js} +2 -2
- package/dist/public/assets/{_Bo2t_uNU.js.map → _Bu7qESl9.js.map} +1 -1
- package/dist/public/assets/{_CkT411UL.js → _Bu8da51m.js} +2 -2
- package/dist/public/assets/{_CkT411UL.js.map → _Bu8da51m.js.map} +1 -1
- package/dist/public/assets/{_B1Ress7e.js → _ByQEUmce.js} +2 -2
- package/dist/public/assets/{_B1Ress7e.js.map → _ByQEUmce.js.map} +1 -1
- package/dist/public/assets/{_CG65evuJ2.js → _BzxnfKym2.js} +2 -2
- package/dist/public/assets/{_CG65evuJ2.js.map → _BzxnfKym2.js.map} +1 -1
- package/dist/public/assets/{_g7Q1ADd0.js → _C9f7zuCK.js} +2 -2
- package/dist/public/assets/{_g7Q1ADd0.js.map → _C9f7zuCK.js.map} +1 -1
- package/dist/public/assets/{_RgPZr-u4.js → _CBoYeeXx.js} +2 -2
- package/dist/public/assets/{_RgPZr-u4.js.map → _CBoYeeXx.js.map} +1 -1
- package/dist/public/assets/{_anllqmOe.js → _CC8qBXCN.js} +2 -2
- package/dist/public/assets/{_anllqmOe.js.map → _CC8qBXCN.js.map} +1 -1
- package/dist/public/assets/{_COiINYul2.js → _CGPzzHpX2.js} +2 -2
- package/dist/public/assets/{_COiINYul2.js.map → _CGPzzHpX2.js.map} +1 -1
- package/dist/public/assets/{_BpIotmis.js → _CHO-fcR6.js} +2 -2
- package/dist/public/assets/{_BpIotmis.js.map → _CHO-fcR6.js.map} +1 -1
- package/dist/public/assets/{_Cww6wLe3.js → _CJBKn-UB.js} +2 -2
- package/dist/public/assets/{_Cww6wLe3.js.map → _CJBKn-UB.js.map} +1 -1
- package/dist/public/assets/{_BWIzVLMa2.js → _CK4WVIux2.js} +2 -2
- package/dist/public/assets/{_BWIzVLMa2.js.map → _CK4WVIux2.js.map} +1 -1
- package/dist/public/assets/{_B49wgrKW.js → _CLf30P17.js} +2 -2
- package/dist/public/assets/{_B49wgrKW.js.map → _CLf30P17.js.map} +1 -1
- package/dist/public/assets/{_D0-uwMfH2.js → _C_PnVjpe2.js} +2 -2
- package/dist/public/assets/{_D0-uwMfH2.js.map → _C_PnVjpe2.js.map} +1 -1
- package/dist/public/assets/{_BFnmKuGb.js → _CbS76xPa.js} +2 -2
- package/dist/public/assets/{_BFnmKuGb.js.map → _CbS76xPa.js.map} +1 -1
- package/dist/public/assets/{_CgX5-PN8.js → _CboThNtr.js} +2 -2
- package/dist/public/assets/{_CgX5-PN8.js.map → _CboThNtr.js.map} +1 -1
- package/dist/public/assets/{_E5dbeZEm2.js → _CkNgOJS_2.js} +2 -2
- package/dist/public/assets/{_E5dbeZEm2.js.map → _CkNgOJS_2.js.map} +1 -1
- package/dist/public/assets/{_B7ZTox7L.js → _CpGG57tS.js} +2 -2
- package/dist/public/assets/{_B7ZTox7L.js.map → _CpGG57tS.js.map} +1 -1
- package/dist/public/assets/{_D32jCBoK.js → _CxzK5dOR.js} +2 -2
- package/dist/public/assets/{_D32jCBoK.js.map → _CxzK5dOR.js.map} +1 -1
- package/dist/public/assets/{_dkeDDehz2.js → _CzHeRzBF2.js} +2 -2
- package/dist/public/assets/{_dkeDDehz2.js.map → _CzHeRzBF2.js.map} +1 -1
- package/dist/public/assets/{_BVimx11r.js → _D-GxVvEg.js} +2 -2
- package/dist/public/assets/{_BVimx11r.js.map → _D-GxVvEg.js.map} +1 -1
- package/dist/public/assets/{_Bv61tUGo.js → _D2-cyutB.js} +2 -2
- package/dist/public/assets/{_Bv61tUGo.js.map → _D2-cyutB.js.map} +1 -1
- package/dist/public/assets/{_DqqLoHco.js → _D49qceqY.js} +2 -2
- package/dist/public/assets/{_DqqLoHco.js.map → _D49qceqY.js.map} +1 -1
- package/dist/public/assets/{_CXLqhKMK2.js → _DFjCyuxr2.js} +2 -2
- package/dist/public/assets/{_CXLqhKMK2.js.map → _DFjCyuxr2.js.map} +1 -1
- package/dist/public/assets/{_xuVEda462.js → _DGx7YAZr2.js} +2 -2
- package/dist/public/assets/{_xuVEda462.js.map → _DGx7YAZr2.js.map} +1 -1
- package/dist/public/assets/{_DncMx76o2.js → _DHjLNDCN2.js} +2 -2
- package/dist/public/assets/{_DncMx76o2.js.map → _DHjLNDCN2.js.map} +1 -1
- package/dist/public/assets/{_ZSGrflxk.js → _DMiuUq_D.js} +2 -2
- package/dist/public/assets/{_ZSGrflxk.js.map → _DMiuUq_D.js.map} +1 -1
- package/dist/public/assets/{_ChXwBYfg.js → _DPXMcFb-.js} +2 -2
- package/dist/public/assets/{_ChXwBYfg.js.map → _DPXMcFb-.js.map} +1 -1
- package/dist/public/assets/{_DInIL5iq2.js → _DPgBCY_32.js} +2 -2
- package/dist/public/assets/{_DInIL5iq2.js.map → _DPgBCY_32.js.map} +1 -1
- package/dist/public/assets/{_DkpMMWAt2.js → _DQGram-O2.js} +2 -2
- package/dist/public/assets/{_DkpMMWAt2.js.map → _DQGram-O2.js.map} +1 -1
- package/dist/public/assets/{_753RhcUs.js → _DR_zCeOi.js} +2 -2
- package/dist/public/assets/{_753RhcUs.js.map → _DR_zCeOi.js.map} +1 -1
- package/dist/public/assets/{_-3M9WuU4.js → _DTvuMul1.js} +2 -2
- package/dist/public/assets/{_-3M9WuU4.js.map → _DTvuMul1.js.map} +1 -1
- package/dist/public/assets/{_BeCpXzaO2.js → _DXLq4GO62.js} +2 -2
- package/dist/public/assets/{_BeCpXzaO2.js.map → _DXLq4GO62.js.map} +1 -1
- package/dist/public/assets/{_O3QIPxoe.js → _DiJdY7gQ.js} +2 -2
- package/dist/public/assets/{_O3QIPxoe.js.map → _DiJdY7gQ.js.map} +1 -1
- package/dist/public/assets/{_C480-4NE.js → _DmQQt4hu.js} +2 -2
- package/dist/public/assets/{_C480-4NE.js.map → _DmQQt4hu.js.map} +1 -1
- package/dist/public/assets/{_CeybDOH3.js → _DnNvPxgR.js} +2 -2
- package/dist/public/assets/{_CeybDOH3.js.map → _DnNvPxgR.js.map} +1 -1
- package/dist/public/assets/{_ByaF5Ym8.js → _Du6sWmX1.js} +2 -2
- package/dist/public/assets/{_ByaF5Ym8.js.map → _Du6sWmX1.js.map} +1 -1
- package/dist/public/assets/{_D8RqMrGW2.js → _Dw_lnT1k2.js} +2 -2
- package/dist/public/assets/{_D8RqMrGW2.js.map → _Dw_lnT1k2.js.map} +1 -1
- package/dist/public/assets/{_aXYWp2ZC.js → _Dy_gFnsG.js} +2 -2
- package/dist/public/assets/{_aXYWp2ZC.js.map → _Dy_gFnsG.js.map} +1 -1
- package/dist/public/assets/{_CjAjLYnS.js → _ERq15mXY.js} +2 -2
- package/dist/public/assets/{_CjAjLYnS.js.map → _ERq15mXY.js.map} +1 -1
- package/dist/public/assets/{_BfCF5T_K.js → _FJ3epuTO.js} +2 -2
- package/dist/public/assets/{_BfCF5T_K.js.map → _FJ3epuTO.js.map} +1 -1
- package/dist/public/assets/{_3ZKZeEN32.js → _GbGk7W6w2.js} +2 -2
- package/dist/public/assets/{_3ZKZeEN32.js.map → _GbGk7W6w2.js.map} +1 -1
- package/dist/public/assets/{_BRfYhRDN.js → _Jso7DEzq.js} +2 -2
- package/dist/public/assets/{_BRfYhRDN.js.map → _Jso7DEzq.js.map} +1 -1
- package/dist/public/assets/{_BooCIZFD.js → _KgHefAOC.js} +2 -2
- package/dist/public/assets/{_BooCIZFD.js.map → _KgHefAOC.js.map} +1 -1
- package/dist/public/assets/{_BchSFDSU.js → _SsIq7tI_.js} +2 -2
- package/dist/public/assets/{_BchSFDSU.js.map → _SsIq7tI_.js.map} +1 -1
- package/dist/public/assets/{_q9TSOuKE.js → _TmenAuHp.js} +2 -2
- package/dist/public/assets/{_q9TSOuKE.js.map → _TmenAuHp.js.map} +1 -1
- package/dist/public/assets/{_DpLjBHyL.js → _XaQkxl5y.js} +2 -2
- package/dist/public/assets/{_DpLjBHyL.js.map → _XaQkxl5y.js.map} +1 -1
- package/dist/public/assets/{_DtmS6252.js → _XlH801Qf.js} +2 -2
- package/dist/public/assets/{_DtmS6252.js.map → _XlH801Qf.js.map} +1 -1
- package/dist/public/assets/{_CZtA_-Ie.js → _k-HR2JJy.js} +2 -2
- package/dist/public/assets/{_CZtA_-Ie.js.map → _k-HR2JJy.js.map} +1 -1
- package/dist/public/assets/{_BpB-O0HN.js → _mHazeEK3.js} +2 -2
- package/dist/public/assets/{_BpB-O0HN.js.map → _mHazeEK3.js.map} +1 -1
- package/dist/public/assets/{_Cm-mKxlV2.js → _pNAnwKme2.js} +2 -2
- package/dist/public/assets/{_Cm-mKxlV2.js.map → _pNAnwKme2.js.map} +1 -1
- package/dist/public/assets/{_BGO4yXnZ.js → _sILr7p5e.js} +2 -2
- package/dist/public/assets/{_BGO4yXnZ.js.map → _sILr7p5e.js.map} +1 -1
- package/dist/public/assets/{_DDpdWlxA.js → _unB9bj15.js} +2 -2
- package/dist/public/assets/{_DDpdWlxA.js.map → _unB9bj15.js.map} +1 -1
- package/dist/public/assets/{_BwnkAzDN2.js → _xOqgIxv42.js} +2 -2
- package/dist/public/assets/{_BwnkAzDN2.js.map → _xOqgIxv42.js.map} +1 -1
- package/dist/public/assets/{_Do3Q5gXZ2.js → _yYAbok8d2.js} +2 -2
- package/dist/public/assets/{_Do3Q5gXZ2.js.map → _yYAbok8d2.js.map} +1 -1
- package/dist/public/assets/{index-DJu3fA99.js → index-LnMHViqj.js} +63 -63
- package/dist/public/assets/index-LnMHViqj.js.map +1 -0
- package/package.json +1 -1
- package/dist/public/assets/index-DJu3fA99.js.map +0 -1
package/dist/index.mjs
CHANGED
|
@@ -5648,38 +5648,46 @@ var icon_search_default = _template("H", (input) => {
|
|
|
5648
5648
|
//#endregion
|
|
5649
5649
|
//#region src/tags/file-filter.marko
|
|
5650
5650
|
var file_filter_default = _template("f", (input) => {
|
|
5651
|
-
_scope_reason();
|
|
5651
|
+
const $scope0_reason = _scope_reason();
|
|
5652
5652
|
const $scope0_id = _scope_id();
|
|
5653
|
-
let
|
|
5653
|
+
let value = input.value;
|
|
5654
|
+
let pending = null;
|
|
5655
|
+
const draft = (pending ?? value) || "";
|
|
5654
5656
|
const box = { timer: 0 };
|
|
5655
5657
|
const flush = _resume(() => {
|
|
5656
5658
|
if (box.timer) {
|
|
5657
5659
|
clearTimeout(box.timer);
|
|
5658
5660
|
box.timer = 0;
|
|
5659
5661
|
}
|
|
5660
|
-
|
|
5662
|
+
const next = pending !== null ? pending : value || "";
|
|
5663
|
+
pending = null;
|
|
5664
|
+
value = next;
|
|
5661
5665
|
}, "f1", $scope0_id);
|
|
5662
5666
|
const type = _resume((v) => {
|
|
5663
|
-
draft = v;
|
|
5664
5667
|
if (box.timer) clearTimeout(box.timer);
|
|
5665
5668
|
if (!v) {
|
|
5666
5669
|
box.timer = 0;
|
|
5667
|
-
|
|
5670
|
+
pending = null;
|
|
5671
|
+
value = "";
|
|
5668
5672
|
return;
|
|
5669
5673
|
}
|
|
5674
|
+
pending = v;
|
|
5670
5675
|
box.timer = setTimeout(flush, 150);
|
|
5671
5676
|
}, "f2", $scope0_id);
|
|
5672
5677
|
_html(`<div class=wrap><input${_attr_input_value($scope0_id, "a", draft, _resume(function(v) {
|
|
5673
5678
|
type(v);
|
|
5674
5679
|
}, "f0", $scope0_id))} class=file-filter type=search placeholder="Filter files… (globs, !excludes)" aria-label="Filter files">${_el_resume($scope0_id, "a")}</div>`);
|
|
5675
5680
|
_script($scope0_id, "f3");
|
|
5676
|
-
_script($scope0_id, "f4");
|
|
5677
5681
|
writeScope($scope0_id, {
|
|
5678
|
-
|
|
5679
|
-
|
|
5680
|
-
|
|
5681
|
-
|
|
5682
|
-
|
|
5682
|
+
d: _serialize_if($scope0_reason, 1) && input.value,
|
|
5683
|
+
e: _serialize_if($scope0_reason, 0) && input.valueChange,
|
|
5684
|
+
g: value,
|
|
5685
|
+
i: pending,
|
|
5686
|
+
k: draft,
|
|
5687
|
+
m: box.timer,
|
|
5688
|
+
o: flush,
|
|
5689
|
+
q: type,
|
|
5690
|
+
h: input.valueChange || void 0
|
|
5683
5691
|
});
|
|
5684
5692
|
_resume_branch($scope0_id);
|
|
5685
5693
|
});
|
|
@@ -5781,6 +5789,7 @@ _template("c", (input) => {
|
|
|
5781
5789
|
//#region src/tags/diff-view.marko
|
|
5782
5790
|
var api$3;
|
|
5783
5791
|
var copyText;
|
|
5792
|
+
var prHeadSigFromDiff;
|
|
5784
5793
|
var getTermDims;
|
|
5785
5794
|
var makeFileFilter;
|
|
5786
5795
|
var diff_view_default = _template("e", (input) => {
|
|
@@ -5869,6 +5878,10 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5869
5878
|
};
|
|
5870
5879
|
requestAnimationFrame(tryScroll);
|
|
5871
5880
|
}, "e4", $scope0_id);
|
|
5881
|
+
const headBox = {
|
|
5882
|
+
sig: "",
|
|
5883
|
+
timer: 0
|
|
5884
|
+
};
|
|
5872
5885
|
const load = _resume(async (dirty = uncommitted, refresh = false) => {
|
|
5873
5886
|
loading = true;
|
|
5874
5887
|
error = null;
|
|
@@ -5881,6 +5894,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5881
5894
|
repos = diffData;
|
|
5882
5895
|
comments = reviewData.comments || [];
|
|
5883
5896
|
viewed = new Set(reviewData.viewed || []);
|
|
5897
|
+
headBox.sig = prHeadSigFromDiff(diffData);
|
|
5884
5898
|
if (input.focusPr) focusPrSection(input.focusPr);
|
|
5885
5899
|
} catch (err) {
|
|
5886
5900
|
error = String(err.message || err);
|
|
@@ -5894,6 +5908,17 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5894
5908
|
viewed = new Set(reviewData.viewed || []);
|
|
5895
5909
|
} catch {}
|
|
5896
5910
|
}, "e6", $scope0_id);
|
|
5911
|
+
const reload = _resume(() => {
|
|
5912
|
+
dismissedDrift = /* @__PURE__ */ new Set();
|
|
5913
|
+
return load(uncommitted, true);
|
|
5914
|
+
}, "e7", $scope0_id);
|
|
5915
|
+
const reloadSoon = _resume(() => {
|
|
5916
|
+
if (headBox.timer) clearTimeout(headBox.timer);
|
|
5917
|
+
headBox.timer = setTimeout(() => {
|
|
5918
|
+
headBox.timer = 0;
|
|
5919
|
+
reload();
|
|
5920
|
+
}, 250);
|
|
5921
|
+
}, "e8", $scope0_id);
|
|
5897
5922
|
const repoList = repos || [];
|
|
5898
5923
|
const allFiles = repoList.flatMap((r) => r.files.map((f) => ({
|
|
5899
5924
|
...f,
|
|
@@ -5916,15 +5941,11 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5916
5941
|
return map;
|
|
5917
5942
|
})();
|
|
5918
5943
|
const sendPick = (input.sessions || []).some((s) => s.id === sendTarget) ? sendTarget : input.sessions?.[0]?.id ?? null;
|
|
5919
|
-
const localDiffers = _resume((repo) => !!repo.pr && !!repo.localHead && (repo.localHead !== repo.head || repo.branch !== repo.pr.headRefName), "
|
|
5944
|
+
const localDiffers = _resume((repo) => !!repo.pr && !!repo.localHead && (repo.localHead !== repo.head || repo.branch !== repo.pr.headRefName), "e9");
|
|
5920
5945
|
const driftRepos = repoList.filter((r) => r.githubDrift && !dismissedDrift.has(r.id));
|
|
5921
5946
|
const dismissDrift = _resume(() => {
|
|
5922
5947
|
dismissedDrift = /* @__PURE__ */ new Set([...dismissedDrift, ...driftRepos.map((r) => r.id)]);
|
|
5923
|
-
}, "
|
|
5924
|
-
const reload = _resume(() => {
|
|
5925
|
-
dismissedDrift = /* @__PURE__ */ new Set();
|
|
5926
|
-
return load(uncommitted, true);
|
|
5927
|
-
}, "e9", $scope0_id);
|
|
5948
|
+
}, "e10", $scope0_id);
|
|
5928
5949
|
const toggleViewed = _resume((key) => {
|
|
5929
5950
|
const next = new Set(viewed);
|
|
5930
5951
|
const isViewed = !next.has(key);
|
|
@@ -5942,7 +5963,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5942
5963
|
}).catch(() => {
|
|
5943
5964
|
error = "Saving viewed state failed — it may reset on reload.";
|
|
5944
5965
|
});
|
|
5945
|
-
}, "
|
|
5966
|
+
}, "e11", $scope0_id);
|
|
5946
5967
|
const saveComment = _resume(async (file, text) => {
|
|
5947
5968
|
const range = draft;
|
|
5948
5969
|
draft = null;
|
|
@@ -5964,11 +5985,11 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5964
5985
|
} catch (err) {
|
|
5965
5986
|
error = String(err.message || err);
|
|
5966
5987
|
}
|
|
5967
|
-
}, "
|
|
5988
|
+
}, "e12", $scope0_id);
|
|
5968
5989
|
const removeComment = _resume(async (id) => {
|
|
5969
5990
|
comments = comments.filter((c) => c.id !== id);
|
|
5970
5991
|
await fetch(`/api/review-comments/${id}`, { method: "DELETE" });
|
|
5971
|
-
}, "
|
|
5992
|
+
}, "e13", $scope0_id);
|
|
5972
5993
|
const clearComments = _resume(async () => {
|
|
5973
5994
|
comments = [];
|
|
5974
5995
|
draft = null;
|
|
@@ -5977,7 +5998,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5977
5998
|
headers: { "content-type": "application/json" },
|
|
5978
5999
|
body: JSON.stringify({ action: "clear" })
|
|
5979
6000
|
});
|
|
5980
|
-
}, "
|
|
6001
|
+
}, "e14", $scope0_id);
|
|
5981
6002
|
const copyMarkdown = _resume(async () => {
|
|
5982
6003
|
if (!await copyText(commentMarkdown(comments, repos))) {
|
|
5983
6004
|
error = "Copy failed — clipboard needs HTTPS on this browser.";
|
|
@@ -5988,7 +6009,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
5988
6009
|
copied = false;
|
|
5989
6010
|
}, 1500);
|
|
5990
6011
|
await clearComments();
|
|
5991
|
-
}, "
|
|
6012
|
+
}, "e15", $scope0_id);
|
|
5992
6013
|
const sendTo = _resume(async (sessionId) => {
|
|
5993
6014
|
if (!sessionId) return;
|
|
5994
6015
|
sending = true;
|
|
@@ -6008,22 +6029,22 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6008
6029
|
error = String(err.message || err);
|
|
6009
6030
|
sending = false;
|
|
6010
6031
|
}
|
|
6011
|
-
}, "
|
|
6032
|
+
}, "e16", $scope0_id);
|
|
6012
6033
|
const jumpTo = _resume((key) => {
|
|
6013
6034
|
const el = ((scrollEl) => scrollEl())(_el_read_error).querySelector(`details[data-key="${CSS.escape(key)}"]`);
|
|
6014
6035
|
if (el) {
|
|
6015
6036
|
el.open = true;
|
|
6016
6037
|
el.scrollIntoView({ block: "start" });
|
|
6017
6038
|
}
|
|
6018
|
-
}, "
|
|
6039
|
+
}, "e17", $scope0_id);
|
|
6019
6040
|
const openFind = _resume(() => {
|
|
6020
6041
|
findOpen = true;
|
|
6021
6042
|
findTick++;
|
|
6022
|
-
}, "
|
|
6043
|
+
}, "e18", $scope0_id);
|
|
6023
6044
|
const onFindState = _resume((next) => {
|
|
6024
6045
|
findState = next;
|
|
6025
6046
|
if (next.hit) setTimeout(() => jumpTo(next.hit.key), 0);
|
|
6026
|
-
}, "
|
|
6047
|
+
}, "e19", $scope0_id);
|
|
6027
6048
|
_html(`<div class=diff-view><aside class=${!treeOpen ? "\"tree closed\"" : "tree"}>`);
|
|
6028
6049
|
_for_of(repoList.filter((r) => shownByRepo.get(r.id)?.length), (repo) => {
|
|
6029
6050
|
const $scope5_id = _scope_id();
|
|
@@ -6033,8 +6054,8 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6033
6054
|
const $scope6_id = _scope_id();
|
|
6034
6055
|
const $if_content4__dirKey__closures = /* @__PURE__ */ new Set();
|
|
6035
6056
|
const repoRows = treeRows(shownByRepo.get(repo.id) || []);
|
|
6036
|
-
const dirKey = _resume((path) => `${repo.id}/${path}`, "
|
|
6037
|
-
const rowDir = _resume((row) => row.kind === "dir" ? row.path : row.file.path.includes("/") ? row.file.path.slice(0, row.file.path.lastIndexOf("/")) : "", "
|
|
6057
|
+
const dirKey = _resume((path) => `${repo.id}/${path}`, "e20", $scope6_id);
|
|
6058
|
+
const rowDir = _resume((row) => row.kind === "dir" ? row.path : row.file.path.includes("/") ? row.file.path.slice(0, row.file.path.lastIndexOf("/")) : "", "e21");
|
|
6038
6059
|
const hiddenByCollapse = _resume((row) => {
|
|
6039
6060
|
const dir = rowDir(row);
|
|
6040
6061
|
for (const collapsed of collapsedDirs) {
|
|
@@ -6044,15 +6065,15 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6044
6065
|
if (dir === path || dir.startsWith(`${path}/`)) return true;
|
|
6045
6066
|
}
|
|
6046
6067
|
return false;
|
|
6047
|
-
}, "
|
|
6068
|
+
}, "e22", $scope6_id);
|
|
6048
6069
|
_for_of(repoRows, (row) => {
|
|
6049
6070
|
const $scope7_id = _scope_id();
|
|
6050
6071
|
_if(() => {
|
|
6051
6072
|
if (!hiddenByCollapse(row) && row.kind === "dir") {
|
|
6052
6073
|
const $scope29_id = _scope_id();
|
|
6053
6074
|
_html(`<button class=${collapsedDirs.has(dirKey(row.path)) ? "\"tree-dir dim mono closed\"" : "\"tree-dir dim mono\""}${_attr("title", row.path)}${_attr_style(`padding-left:${.35 + row.depth * .75}rem`)}><span class=tree-chev>${collapsedDirs.has(dirKey(row.path)) ? "▸" : "▾"}${_el_resume($scope29_id, "b")}</span>${_escape(row.label)}${_el_resume($scope29_id, "c")}/</button>${_el_resume($scope29_id, "a")}`);
|
|
6054
|
-
_script($scope29_id, "
|
|
6055
|
-
_subscribe($if_content4__dirKey__closures, _subscribe($collapsedDirs__closures, writeScope($scope29_id, {
|
|
6075
|
+
_script($scope29_id, "e33");
|
|
6076
|
+
_subscribe($if_content4__dirKey__closures, _subscribe($collapsedDirs__closures, writeScope($scope29_id, { Cd5: 1 })));
|
|
6056
6077
|
return 0;
|
|
6057
6078
|
} else if (!hiddenByCollapse(row) && row.kind !== "dir") {
|
|
6058
6079
|
const $scope8_id = _scope_id();
|
|
@@ -6066,7 +6087,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6066
6087
|
}
|
|
6067
6088
|
}, $scope8_id, "e", 1, 1, 1, 0, 1);
|
|
6068
6089
|
_html(`</button>${_el_resume($scope8_id, "a")}`);
|
|
6069
|
-
_script($scope8_id, "
|
|
6090
|
+
_script($scope8_id, "e34");
|
|
6070
6091
|
_subscribe($commentsByFile__closures, _subscribe($viewed__closures, writeScope($scope8_id, {})));
|
|
6071
6092
|
return 1;
|
|
6072
6093
|
}
|
|
@@ -6092,7 +6113,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6092
6113
|
}
|
|
6093
6114
|
}, $scope5_id, "d");
|
|
6094
6115
|
_html("</div>");
|
|
6095
|
-
_script($scope5_id, "
|
|
6116
|
+
_script($scope5_id, "e35");
|
|
6096
6117
|
writeScope($scope5_id, { g: repo?.id });
|
|
6097
6118
|
}, "id", $scope0_id, "a", 1, 1, 1, "</aside>", 1);
|
|
6098
6119
|
_html("<div class=diff-col><div class=diff-head>");
|
|
@@ -6102,7 +6123,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6102
6123
|
_html("<button class=icon-btn title=\"Back to terminal\">");
|
|
6103
6124
|
icon_back_default({ size: 14 });
|
|
6104
6125
|
_html(`</button>${_el_resume($scope1_id, "a")}`);
|
|
6105
|
-
_script($scope1_id, "
|
|
6126
|
+
_script($scope1_id, "e36");
|
|
6106
6127
|
writeScope($scope1_id, { _: _scope_with_id($scope0_id) });
|
|
6107
6128
|
return 0;
|
|
6108
6129
|
}
|
|
@@ -6116,7 +6137,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6116
6137
|
if ((input.sessions || []).length === 1) {
|
|
6117
6138
|
const $scope3_id = _scope_id();
|
|
6118
6139
|
_html(`<button class="btn primary"${_attr("disabled", sending)}>${sending ? "Sending…" : `Send to ${_escape(`${input.sessions[0].title || input.sessions[0].agent}`)}`}${_el_resume($scope3_id, "b")}</button>${_el_resume($scope3_id, "a")}`);
|
|
6119
|
-
_script($scope3_id, "
|
|
6140
|
+
_script($scope3_id, "e37");
|
|
6120
6141
|
_subscribe($sending__closures, _subscribe($si__input_sessions_0_agent && $input_sessions_0_agent__closures, _subscribe($si__input_sessions_0_title && $input_sessions_0_title__closures, writeScope($scope3_id, { _: _scope_with_id($scope2_id) }))));
|
|
6121
6142
|
return 0;
|
|
6122
6143
|
} else if ((input.sessions || []).length) {
|
|
@@ -6133,15 +6154,15 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6133
6154
|
}, "id", $scope4_id, "c", $sg__input_sessions, 1, $sg__input_sessions, "</select>", 1);
|
|
6134
6155
|
});
|
|
6135
6156
|
_html("</span>");
|
|
6136
|
-
_script($scope4_id, "
|
|
6157
|
+
_script($scope4_id, "e38");
|
|
6137
6158
|
_subscribe($sendTarget__closures, _subscribe($sending__closures, _subscribe($si__input_sessions && $input_sessions__closures, writeScope($scope4_id, {
|
|
6138
6159
|
_: _scope_with_id($scope2_id),
|
|
6139
|
-
|
|
6160
|
+
Ccy: 1
|
|
6140
6161
|
}))));
|
|
6141
6162
|
return 1;
|
|
6142
6163
|
}
|
|
6143
6164
|
}, $scope2_id, "c", $sg__input_sessions, $sg__input_sessions, $sg__input_sessions, 0, 1);
|
|
6144
|
-
_script($scope2_id, "
|
|
6165
|
+
_script($scope2_id, "e39");
|
|
6145
6166
|
writeScope($scope2_id, {});
|
|
6146
6167
|
return 0;
|
|
6147
6168
|
}
|
|
@@ -6153,12 +6174,13 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6153
6174
|
_html(`</button>${_el_resume($scope0_id, "j")}<button class="btn files-btn" title="Jump to file">Files (<!>${_escape(shownFiles.length)}${_el_resume($scope0_id, "m")})</button>${_el_resume($scope0_id, "l")}<button class=${findOpen ? "\"btn find-btn on\"" : "\"btn find-btn\""} title="Find in the review (⌘/Ctrl+F)">`);
|
|
6154
6175
|
icon_search_default({ size: 14 });
|
|
6155
6176
|
_html(`<span class=find-label>Find</span></button>${_el_resume($scope0_id, "n")}<label class=two-dot title="Include uncommitted and untracked files in the review. Off by default — the review is commit-to-commit."><input${_attr_input_checked($scope0_id, "p", uncommitted)} type=checkbox>${_el_resume($scope0_id, "p")} include uncommitted</label>`);
|
|
6177
|
+
_set_serialize_reason(2);
|
|
6156
6178
|
const $childScope = _peek_scope_id();
|
|
6157
6179
|
file_filter_default({
|
|
6158
6180
|
value: fileFilter,
|
|
6159
|
-
|
|
6160
|
-
fileFilter =
|
|
6161
|
-
}, "
|
|
6181
|
+
valueChange: _resume((_new_fileFilter) => {
|
|
6182
|
+
fileFilter = _new_fileFilter;
|
|
6183
|
+
}, "e23", $scope0_id)
|
|
6162
6184
|
});
|
|
6163
6185
|
_html("</div>");
|
|
6164
6186
|
_if(() => {
|
|
@@ -6170,7 +6192,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6170
6192
|
tick: findTick,
|
|
6171
6193
|
onState: _resume(function(s) {
|
|
6172
6194
|
onFindState(s);
|
|
6173
|
-
}, "
|
|
6195
|
+
}, "e24", $scope28_id),
|
|
6174
6196
|
onClose: _resume(function() {
|
|
6175
6197
|
findOpen = false;
|
|
6176
6198
|
findState = {
|
|
@@ -6178,7 +6200,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6178
6200
|
hit: null,
|
|
6179
6201
|
keys: []
|
|
6180
6202
|
};
|
|
6181
|
-
}, "
|
|
6203
|
+
}, "e25", $scope28_id)
|
|
6182
6204
|
});
|
|
6183
6205
|
writeScope($scope28_id, { a: _existing_scope($childScope2) });
|
|
6184
6206
|
return 0;
|
|
@@ -6191,8 +6213,8 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6191
6213
|
toast_default({
|
|
6192
6214
|
onDismiss: _resume(function() {
|
|
6193
6215
|
error = null;
|
|
6194
|
-
}, "
|
|
6195
|
-
content: _content_resume("
|
|
6216
|
+
}, "e26", $scope17_id),
|
|
6217
|
+
content: _content_resume("e40", () => {
|
|
6196
6218
|
_scope_reason();
|
|
6197
6219
|
const $scope18_id = _scope_id();
|
|
6198
6220
|
_html(`${_escape(error)}${_el_resume($scope18_id, "a")}`);
|
|
@@ -6213,7 +6235,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6213
6235
|
kind: "warn",
|
|
6214
6236
|
placement: "inline",
|
|
6215
6237
|
title: `${repo.worktree}: base not found`,
|
|
6216
|
-
content: _content_resume("
|
|
6238
|
+
content: _content_resume("e41", () => {
|
|
6217
6239
|
_scope_reason();
|
|
6218
6240
|
const $scope23_id = _scope_id();
|
|
6219
6241
|
_html(`${_escape(repo.base)}${_el_resume($scope23_id, "a")}<!>${uncommitted ? " — showing uncommitted changes only" : ""}${_el_resume($scope23_id, "b")}.`);
|
|
@@ -6236,13 +6258,13 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6236
6258
|
kind: "info",
|
|
6237
6259
|
placement: "inline",
|
|
6238
6260
|
title: repo.pr ? `${repo.worktree} #${repo.pr.number}` : repo.worktree,
|
|
6239
|
-
content: _content_resume("
|
|
6261
|
+
content: _content_resume("e42", () => {
|
|
6240
6262
|
_scope_reason();
|
|
6241
6263
|
const $scope25_id = _scope_id();
|
|
6242
6264
|
_html(`already in <!>${_escape(repo.base)}${_el_resume($scope25_id, "a")}<!>${uncommitted ? " — showing uncommitted changes only" : ""}${_el_resume($scope25_id, "b")}.`);
|
|
6243
6265
|
_subscribe($for_content7__repo_base__closures, _subscribe($uncommitted__closures, writeScope($scope25_id, {
|
|
6244
6266
|
_: _scope_with_id($scope24_id),
|
|
6245
|
-
|
|
6267
|
+
Cd1: 1
|
|
6246
6268
|
})));
|
|
6247
6269
|
_resume_branch($scope25_id);
|
|
6248
6270
|
}, $scope24_id)
|
|
@@ -6264,16 +6286,16 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6264
6286
|
title: "GitHub is behind",
|
|
6265
6287
|
onDismiss: _resume(function() {
|
|
6266
6288
|
dismissDrift();
|
|
6267
|
-
}, "
|
|
6268
|
-
action: attrTag({ content: _content_resume("
|
|
6289
|
+
}, "e27", $scope19_id),
|
|
6290
|
+
action: attrTag({ content: _content_resume("e44", () => {
|
|
6269
6291
|
_scope_reason();
|
|
6270
6292
|
const $scope20_id = _scope_id();
|
|
6271
6293
|
_html(`<button class=btn${_attr("disabled", loading)}>${loading ? "Reloading…" : "Reload"}${_el_resume($scope20_id, "b")}</button>${_el_resume($scope20_id, "a")}`);
|
|
6272
|
-
_script($scope20_id, "
|
|
6294
|
+
_script($scope20_id, "e43");
|
|
6273
6295
|
_subscribe($loading__closures, writeScope($scope20_id, { _: _scope_with_id($scope19_id) }));
|
|
6274
6296
|
_resume_branch($scope20_id);
|
|
6275
6297
|
}, $scope19_id) }),
|
|
6276
|
-
content: _content_resume("
|
|
6298
|
+
content: _content_resume("e45", () => {
|
|
6277
6299
|
_scope_reason();
|
|
6278
6300
|
const $scope34_id = _scope_id();
|
|
6279
6301
|
_html("<span class=dim>");
|
|
@@ -6308,13 +6330,13 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6308
6330
|
kind: "info",
|
|
6309
6331
|
placement: "inline",
|
|
6310
6332
|
title: `${repo.worktree} #${repo.pr.number}`,
|
|
6311
|
-
content: _content_resume("
|
|
6333
|
+
content: _content_resume("e46", () => {
|
|
6312
6334
|
_scope_reason();
|
|
6313
6335
|
const $scope27_id = _scope_id();
|
|
6314
6336
|
_html(`this view is <!>${_escape(shortSha(repo.head))}${_el_resume($scope27_id, "a")} (<!>${_escape(repo.pr.headRefName)}${_el_resume($scope27_id, "b")}). Local is <!>${_escape(shortSha(repo.localHead))}${_el_resume($scope27_id, "c")} (<!>${_escape(repo.branch)}${_el_resume($scope27_id, "d")}<!>${uncommitted ? ", plus uncommitted" : ""}${_el_resume($scope27_id, "e")}).`);
|
|
6315
6337
|
_subscribe($for_content8__repo_branch__closures, _subscribe($for_content8__repo_localHead__closures, _subscribe($for_content8__repo_pr_headRefName__closures, _subscribe($for_content8__repo_head__closures, _subscribe($uncommitted__closures, writeScope($scope27_id, {
|
|
6316
6338
|
_: _scope_with_id($scope26_id),
|
|
6317
|
-
|
|
6339
|
+
Cd1: 2
|
|
6318
6340
|
}))))));
|
|
6319
6341
|
_resume_branch($scope27_id);
|
|
6320
6342
|
}, $scope26_id)
|
|
@@ -6375,7 +6397,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6375
6397
|
if (repo.pr) {
|
|
6376
6398
|
const $scope39_id = _scope_id();
|
|
6377
6399
|
_html(`<a class="chip pr"${_attr("href", `${repo.pr.url}/files`)} target=_blank rel=noopener${_attr("title", `${repo.pr.title} — ${repo.pr.headRefName} ${repo.head} vs ${repo.base} ${repo.baseSha}`)}>#<!>${_escape(repo.pr.number)}${_el_resume($scope39_id, "b")}</a>${_el_resume($scope39_id, "a")}<span class=dim>${_escape(repo.pr.title)}${_el_resume($scope39_id, "c")}</span>`);
|
|
6378
|
-
_script($scope39_id, "
|
|
6400
|
+
_script($scope39_id, "e47");
|
|
6379
6401
|
_subscribe($for_content3__repo_baseSha__closures, _subscribe($for_content3__repo_base__closures, _subscribe($for_content3__repo_head__closures, _subscribe($for_content3__repo_pr_headRefName__closures, _subscribe($for_content3__repo_pr_title__closures, _subscribe($for_content3__repo_pr_url__closures, _subscribe($for_content3__repo_pr_number__closures, writeScope($scope39_id, {
|
|
6380
6402
|
Ca5: 2,
|
|
6381
6403
|
Ca6: 2,
|
|
@@ -6399,8 +6421,8 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6399
6421
|
}
|
|
6400
6422
|
}, $scope30_id, "i", 1, 1, 1, 0, 1);
|
|
6401
6423
|
_html(`</button>${_el_resume($scope30_id, "a")}`);
|
|
6402
|
-
_script($scope30_id, "
|
|
6403
|
-
_subscribe($for_content3__repo_branch__closures, _subscribe($for_content3__repo_baseSha__closures, _subscribe($for_content3__repo_base__closures, _subscribe($for_content3__repo_head__closures, _subscribe($for_content3__repo_worktree__closures, _subscribe($for_content3__repo_pr__closures, _subscribe($for_content3__repo_id__closures, _subscribe($for_content3__repo__closures, _subscribe($collapsedRepos__closures, writeScope($scope30_id, {
|
|
6424
|
+
_script($scope30_id, "e48");
|
|
6425
|
+
_subscribe($for_content3__repo_branch__closures, _subscribe($for_content3__repo_baseSha__closures, _subscribe($for_content3__repo_base__closures, _subscribe($for_content3__repo_head__closures, _subscribe($for_content3__repo_worktree__closures, _subscribe($for_content3__repo_pr__closures, _subscribe($for_content3__repo_id__closures, _subscribe($for_content3__repo__closures, _subscribe($collapsedRepos__closures, writeScope($scope30_id, { Cd6: 1 }))))))))));
|
|
6404
6426
|
return 0;
|
|
6405
6427
|
} else {
|
|
6406
6428
|
const $scope33_id = _scope_id();
|
|
@@ -6490,7 +6512,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6490
6512
|
{
|
|
6491
6513
|
const $scope31_id = _scope_id();
|
|
6492
6514
|
_html(`<div class=diff-wait></div>${_el_resume($scope31_id, "a")}`);
|
|
6493
|
-
_script($scope31_id, "
|
|
6515
|
+
_script($scope31_id, "e49");
|
|
6494
6516
|
writeScope($scope31_id, {});
|
|
6495
6517
|
return 0;
|
|
6496
6518
|
}
|
|
@@ -6500,7 +6522,7 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6500
6522
|
}
|
|
6501
6523
|
}, $scope12_id, "i");
|
|
6502
6524
|
_html(`</details>${_el_resume($scope12_id, "a")}`);
|
|
6503
|
-
_script($scope12_id, "
|
|
6525
|
+
_script($scope12_id, "e50");
|
|
6504
6526
|
_subscribe($toggleViewed2__closures, _subscribe($commentsByFile__closures, _subscribe($shownKeySet__closures, _subscribe($viewed__closures, writeScope($scope12_id, {
|
|
6505
6527
|
k: file,
|
|
6506
6528
|
l: file?.key,
|
|
@@ -6514,8 +6536,8 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6514
6536
|
a0: $for_content4__file__closures,
|
|
6515
6537
|
a1: $for_content4__file_key__closures,
|
|
6516
6538
|
a2: $for_content4__fileComments__closures,
|
|
6517
|
-
|
|
6518
|
-
|
|
6539
|
+
Ccs: 1,
|
|
6540
|
+
Cdg: 1
|
|
6519
6541
|
})))));
|
|
6520
6542
|
}, "key", $scope11_id, "a", 1, 1, 1, "</div>", 1);
|
|
6521
6543
|
_subscribe($for_content3__repoFiles__closures, writeScope($scope11_id, {}));
|
|
@@ -6564,8 +6586,8 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6564
6586
|
_html(`</div>${_el_resume($scope0_id, "s")}</div>`);
|
|
6565
6587
|
_if(() => {}, $scope0_id, "a0");
|
|
6566
6588
|
_html("</div>");
|
|
6567
|
-
_script($scope0_id, "e52");
|
|
6568
6589
|
_script($scope0_id, "e53");
|
|
6590
|
+
_script($scope0_id, "e54");
|
|
6569
6591
|
writeScope($scope0_id, {
|
|
6570
6592
|
a3: input.workspaceId,
|
|
6571
6593
|
a4: input.focusPr,
|
|
@@ -6602,56 +6624,59 @@ var diff_view_default = _template("e", (input) => {
|
|
|
6602
6624
|
b9: nearBox.io,
|
|
6603
6625
|
bb: observeNear,
|
|
6604
6626
|
bc: focusPrSection,
|
|
6605
|
-
be:
|
|
6606
|
-
bg:
|
|
6607
|
-
|
|
6608
|
-
|
|
6609
|
-
|
|
6610
|
-
bm:
|
|
6611
|
-
|
|
6612
|
-
|
|
6613
|
-
|
|
6614
|
-
bs:
|
|
6615
|
-
|
|
6616
|
-
|
|
6617
|
-
|
|
6618
|
-
|
|
6619
|
-
|
|
6620
|
-
|
|
6621
|
-
c4:
|
|
6622
|
-
|
|
6623
|
-
|
|
6624
|
-
|
|
6625
|
-
ca:
|
|
6626
|
-
|
|
6627
|
-
|
|
6628
|
-
cf:
|
|
6629
|
-
cg:
|
|
6630
|
-
ch:
|
|
6631
|
-
|
|
6632
|
-
|
|
6633
|
-
|
|
6634
|
-
cn:
|
|
6635
|
-
|
|
6636
|
-
|
|
6637
|
-
|
|
6638
|
-
|
|
6639
|
-
|
|
6640
|
-
|
|
6641
|
-
|
|
6627
|
+
be: headBox.sig,
|
|
6628
|
+
bg: headBox.timer,
|
|
6629
|
+
bh: load,
|
|
6630
|
+
bj: loadReview,
|
|
6631
|
+
bk: reload,
|
|
6632
|
+
bm: reloadSoon,
|
|
6633
|
+
bo: repoList,
|
|
6634
|
+
bq: repoList.length,
|
|
6635
|
+
br: allFiles,
|
|
6636
|
+
bs: allFiles?.length,
|
|
6637
|
+
bt: fileMatch,
|
|
6638
|
+
bv: fileFiltered,
|
|
6639
|
+
bw: findKeys,
|
|
6640
|
+
by: shownFiles,
|
|
6641
|
+
c2: shownKeySet,
|
|
6642
|
+
c3: filesByRepo,
|
|
6643
|
+
c4: shownByRepo,
|
|
6644
|
+
c6: commentsByFile,
|
|
6645
|
+
c7: sendPick,
|
|
6646
|
+
c8: localDiffers,
|
|
6647
|
+
ca: driftRepos,
|
|
6648
|
+
cd: dismissDrift,
|
|
6649
|
+
ce: toggleViewed,
|
|
6650
|
+
cf: saveComment,
|
|
6651
|
+
cg: removeComment,
|
|
6652
|
+
ch: clearComments,
|
|
6653
|
+
ck: copyMarkdown,
|
|
6654
|
+
cl: sendTo,
|
|
6655
|
+
cm: jumpTo,
|
|
6656
|
+
cn: openFind,
|
|
6657
|
+
co: onFindState,
|
|
6658
|
+
d5: $collapsedDirs__closures,
|
|
6659
|
+
cs: $viewed__closures,
|
|
6660
|
+
dg: $commentsByFile__closures,
|
|
6661
|
+
df: $shownByRepo__closures,
|
|
6662
|
+
cq: $si__input_sessions_0_title && $input_sessions_0_title__closures,
|
|
6663
|
+
cr: $si__input_sessions_0_agent && $input_sessions_0_agent__closures,
|
|
6664
|
+
cy: $sending__closures,
|
|
6665
|
+
cp: $si__input_sessions && $input_sessions__closures,
|
|
6666
|
+
cz: $sendTarget__closures,
|
|
6642
6667
|
q: _existing_scope($childScope),
|
|
6643
|
-
|
|
6644
|
-
|
|
6645
|
-
|
|
6646
|
-
|
|
6647
|
-
|
|
6648
|
-
|
|
6649
|
-
|
|
6650
|
-
|
|
6651
|
-
|
|
6652
|
-
|
|
6653
|
-
|
|
6654
|
-
|
|
6668
|
+
cv: $error__closures,
|
|
6669
|
+
d1: $uncommitted__closures,
|
|
6670
|
+
cw: $loading__closures,
|
|
6671
|
+
di: $driftRepos__closures,
|
|
6672
|
+
d6: $collapsedRepos__closures,
|
|
6673
|
+
cu: $draft__closures,
|
|
6674
|
+
dl: $saveComment2__closures,
|
|
6675
|
+
dm: $removeComment2__closures,
|
|
6676
|
+
dd: $shownKeySet__closures,
|
|
6677
|
+
dk: $toggleViewed2__closures,
|
|
6678
|
+
d4: $findState_hit_repo__closures,
|
|
6679
|
+
d9: $repoList_length__closures
|
|
6655
6680
|
});
|
|
6656
6681
|
_resume_branch($scope0_id);
|
|
6657
6682
|
});
|
|
@@ -14405,15 +14430,7 @@ async function createWorkspace(name, repos) {
|
|
|
14405
14430
|
const bare = await ensureBare(repo.fullName);
|
|
14406
14431
|
const defaultBranch = await bareDefaultBranch(bare);
|
|
14407
14432
|
const base = repo.baseBranch || defaultBranch;
|
|
14408
|
-
|
|
14409
|
-
await git([
|
|
14410
|
-
"worktree",
|
|
14411
|
-
"add",
|
|
14412
|
-
"-b",
|
|
14413
|
-
branch,
|
|
14414
|
-
path.join(dir, worktree),
|
|
14415
|
-
`origin/${base}`
|
|
14416
|
-
], bare);
|
|
14433
|
+
await addWorkspaceWorktree(bare, path.join(dir, worktree), branch, base);
|
|
14417
14434
|
return {
|
|
14418
14435
|
full_name: repo.fullName,
|
|
14419
14436
|
worktree,
|
|
@@ -14451,15 +14468,7 @@ async function addRepo(workspaceId, fullName, baseBranch) {
|
|
|
14451
14468
|
const bare = await ensureBare(fullName);
|
|
14452
14469
|
const defaultBranch = await bareDefaultBranch(bare);
|
|
14453
14470
|
const base = baseBranch || defaultBranch;
|
|
14454
|
-
|
|
14455
|
-
await git([
|
|
14456
|
-
"worktree",
|
|
14457
|
-
"add",
|
|
14458
|
-
"-b",
|
|
14459
|
-
ws.branch,
|
|
14460
|
-
path.join(ws.path, worktree),
|
|
14461
|
-
`origin/${base}`
|
|
14462
|
-
], bare);
|
|
14471
|
+
await addWorkspaceWorktree(bare, path.join(ws.path, worktree), ws.branch, base);
|
|
14463
14472
|
return {
|
|
14464
14473
|
base,
|
|
14465
14474
|
defaultBranch
|
|
@@ -14637,6 +14646,82 @@ async function ensureBare(fullName) {
|
|
|
14637
14646
|
async function bareDefaultBranch(bare) {
|
|
14638
14647
|
return (await git(["symbolic-ref", "HEAD"], bare)).replace("refs/heads/", "");
|
|
14639
14648
|
}
|
|
14649
|
+
/** `git rev-parse --verify` → oid, or null if the ref is missing. */
|
|
14650
|
+
async function revParse(cwd, ref) {
|
|
14651
|
+
try {
|
|
14652
|
+
return await git([
|
|
14653
|
+
"rev-parse",
|
|
14654
|
+
"--verify",
|
|
14655
|
+
ref
|
|
14656
|
+
], cwd);
|
|
14657
|
+
} catch {
|
|
14658
|
+
return null;
|
|
14659
|
+
}
|
|
14660
|
+
}
|
|
14661
|
+
/**
|
|
14662
|
+
* Create a worktree on the workspace branch tip that matches latest
|
|
14663
|
+
* `origin/<base>`.
|
|
14664
|
+
*
|
|
14665
|
+
* Fresh branch → cut from `origin/<base>` after fetch (ensureBare).
|
|
14666
|
+
* Existing `origin/<ws-branch>` (re-add, open PR, prior push) → restore
|
|
14667
|
+
* that branch then rebase onto `origin/<base>` so the checkout is not
|
|
14668
|
+
* stuck on an old main tip. Leftover local branches with no worktree are
|
|
14669
|
+
* deleted so `worktree add -b` can recreate them.
|
|
14670
|
+
*/
|
|
14671
|
+
async function addWorkspaceWorktree(bare, dest, branch, base) {
|
|
14672
|
+
const baseRef = `origin/${base}`;
|
|
14673
|
+
if (!await revParse(bare, baseRef)) throw new Error(`missing ${baseRef} after fetch`);
|
|
14674
|
+
await git(["worktree", "prune"], bare).catch(() => {});
|
|
14675
|
+
if (await revParse(bare, `refs/heads/${branch}`)) {
|
|
14676
|
+
if ((await git([
|
|
14677
|
+
"worktree",
|
|
14678
|
+
"list",
|
|
14679
|
+
"--porcelain"
|
|
14680
|
+
], bare)).includes(`branch refs/heads/${branch}`)) throw new Error(`${branch} is already checked out in another worktree`);
|
|
14681
|
+
await git([
|
|
14682
|
+
"branch",
|
|
14683
|
+
"-D",
|
|
14684
|
+
branch
|
|
14685
|
+
], bare);
|
|
14686
|
+
}
|
|
14687
|
+
const remoteWs = await revParse(bare, `refs/remotes/origin/${branch}`);
|
|
14688
|
+
const label = path.basename(dest);
|
|
14689
|
+
if (remoteWs) {
|
|
14690
|
+
progress(`Restoring ${label}/ from origin/${branch}…`);
|
|
14691
|
+
await git([
|
|
14692
|
+
"worktree",
|
|
14693
|
+
"add",
|
|
14694
|
+
"-b",
|
|
14695
|
+
branch,
|
|
14696
|
+
dest,
|
|
14697
|
+
`origin/${branch}`
|
|
14698
|
+
], bare);
|
|
14699
|
+
if (await git([
|
|
14700
|
+
"merge-base",
|
|
14701
|
+
branch,
|
|
14702
|
+
baseRef
|
|
14703
|
+
], dest) !== await git(["rev-parse", baseRef], dest)) {
|
|
14704
|
+
progress(`Rebasing ${label}/ onto ${base}…`);
|
|
14705
|
+
try {
|
|
14706
|
+
await git(["rebase", baseRef], dest);
|
|
14707
|
+
} catch (err) {
|
|
14708
|
+
await git(["rebase", "--abort"], dest).catch(() => {});
|
|
14709
|
+
const why = err instanceof Error ? err.message : String(err);
|
|
14710
|
+
throw new Error(`Could not rebase ${branch} onto ${baseRef} for ${label}/. ${why}`);
|
|
14711
|
+
}
|
|
14712
|
+
}
|
|
14713
|
+
} else {
|
|
14714
|
+
progress(`Adding worktree ${label}/ (${base})…`);
|
|
14715
|
+
await git([
|
|
14716
|
+
"worktree",
|
|
14717
|
+
"add",
|
|
14718
|
+
"-b",
|
|
14719
|
+
branch,
|
|
14720
|
+
dest,
|
|
14721
|
+
baseRef
|
|
14722
|
+
], bare);
|
|
14723
|
+
}
|
|
14724
|
+
}
|
|
14640
14725
|
/** `ref` is this workspace branch or a `-topic` lane of it. Another
|
|
14641
14726
|
* workspace's branch can extend this prefix, so callers must also
|
|
14642
14727
|
* subtract `otherWorkspaceBranches`. */
|
|
@@ -21949,4 +22034,4 @@ server.listen(port, () => {
|
|
|
21949
22034
|
//#endregion
|
|
21950
22035
|
export {};
|
|
21951
22036
|
|
|
21952
|
-
;var __MARKO_MANIFEST__={"esfPH6H":{"block":[2,"stylesheet#/assets/index-BxVK_c-q.css",6,"<link",0," rel=\"stylesheet\" crossorigin href=\"",1,"assets/index-BxVK_c-q.css\"",">"],"defer":[2,"/assets/index-
|
|
22037
|
+
;var __MARKO_MANIFEST__={"esfPH6H":{"block":[2,"stylesheet#/assets/index-BxVK_c-q.css",6,"<link",0," rel=\"stylesheet\" crossorigin href=\"",1,"assets/index-BxVK_c-q.css\"",">"],"defer":[2,"/assets/index-LnMHViqj.js",6,"<script",0," async type=\"module\" crossorigin src=\"",1,"assets/index-LnMHViqj.js\"","></script>"]}};
|