@open-mercato/cezar 0.16.2-pr1607.3501 → 0.16.2-pr1637.3572
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/server/preview/location-reporter.d.ts +12 -0
- package/dist/server/preview/location-reporter.js +45 -0
- package/dist/server/preview/location-reporter.js.map +1 -0
- package/dist/server/preview/picker-script.d.ts +0 -22
- package/dist/server/preview/picker-script.js +3 -1
- package/dist/server/preview/picker-script.js.map +1 -1
- package/dist/server/server.d.ts +58 -58
- package/dist/server/worktree-lifecycle.d.ts +8 -8
- package/package.json +3 -3
- package/web/dist/assets/{agent-task-pickers-C0xVQpQ9.js → agent-task-pickers-BdzfdJR3.js} +1 -1
- package/web/dist/assets/{automations-route-C-orQBdY.js → automations-route-BTZ2_boj.js} +1 -1
- package/web/dist/assets/{compare-variants-GBJSu7zP.js → compare-variants-Dg6QlK--.js} +1 -1
- package/web/dist/assets/{dashboard-tG_z4yFB.js → dashboard-3U8d_5s9.js} +1 -1
- package/web/dist/assets/{github-Bcv9Q6jT.js → github-VWFbTfEu.js} +1 -1
- package/web/dist/assets/{index-0vWg8fSS.js → index-mdntR9AC.js} +3 -3
- package/web/dist/assets/{repo-git-BqZoILWJ.js → repo-git-DuMm5pnv.js} +1 -1
- package/web/dist/assets/{skills-D9J6iEWD.js → skills-CHxDHol_.js} +1 -1
- package/web/dist/assets/{task-graph-BMNrU2Zb.js → task-graph-CK9O0hHi.js} +1 -1
- package/web/dist/assets/task-workspace-a9K1whJT.js +27 -0
- package/web/dist/assets/{tracker-CEZg3_sQ.js → tracker-WX0sXgya.js} +1 -1
- package/web/dist/assets/{workflow-graph-CJrBfBpY.js → workflow-graph-BDZNtD4Y.js} +1 -1
- package/web/dist/assets/worktree-lifecycle-operation-DOTiqQFx.js +18 -0
- package/web/dist/index.html +2 -2
- package/web/dist/assets/task-workspace-C91wLzlM.js +0 -27
- package/web/dist/assets/worktree-lifecycle-operation-DJ38G3Xu.js +0 -18
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Preview's location reporter: tells the cockpit where a framed page is after it moves on its
|
|
3
|
+
* own — `pushState`, `replaceState`, a hash change — which fires no `load` and leaves a
|
|
4
|
+
* cross-origin frame's address unreadable from outside. The Design Mode picker carries it; the
|
|
5
|
+
* desktop shell injects its own copy into every frame (`FRAME_SCRIPT` in
|
|
6
|
+
* `packages/desktop/src-tauri/src/lib.rs`), and the first to run claims `__cezarLocation`.
|
|
7
|
+
*
|
|
8
|
+
* It only REPORTS — `{ source: 'cezar-preview', type: 'location', url, how }` to its parent at one
|
|
9
|
+
* origin — and obeys nothing. `how` is `load`, `push`, `replace` or `pop` (a traversal, or a hash
|
|
10
|
+
* change that added no entry). Plain ES5-flavoured source, for the same reasons as the picker.
|
|
11
|
+
*/
|
|
12
|
+
export declare function locationReporterScript(parentOrigin: string): string;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Preview's location reporter: tells the cockpit where a framed page is after it moves on its
|
|
3
|
+
* own — `pushState`, `replaceState`, a hash change — which fires no `load` and leaves a
|
|
4
|
+
* cross-origin frame's address unreadable from outside. The Design Mode picker carries it; the
|
|
5
|
+
* desktop shell injects its own copy into every frame (`FRAME_SCRIPT` in
|
|
6
|
+
* `packages/desktop/src-tauri/src/lib.rs`), and the first to run claims `__cezarLocation`.
|
|
7
|
+
*
|
|
8
|
+
* It only REPORTS — `{ source: 'cezar-preview', type: 'location', url, how }` to its parent at one
|
|
9
|
+
* origin — and obeys nothing. `how` is `load`, `push`, `replace` or `pop` (a traversal, or a hash
|
|
10
|
+
* change that added no entry). Plain ES5-flavoured source, for the same reasons as the picker.
|
|
11
|
+
*/
|
|
12
|
+
export function locationReporterScript(parentOrigin) {
|
|
13
|
+
return LOCATION_REPORTER_SOURCE.replace('__CEZAR_PARENT_ORIGIN__', () => JSON.stringify(parentOrigin).replace(/</g, '\\u003c'));
|
|
14
|
+
}
|
|
15
|
+
const LOCATION_REPORTER_SOURCE = String.raw `(function (parentOrigin) {
|
|
16
|
+
'use strict';
|
|
17
|
+
if (window.parent === window || window.__cezarLocation) return;
|
|
18
|
+
window.__cezarLocation = true;
|
|
19
|
+
var last = null;
|
|
20
|
+
var length = history.length;
|
|
21
|
+
function report(how) {
|
|
22
|
+
var url = location.href;
|
|
23
|
+
if (url === last) return;
|
|
24
|
+
last = url;
|
|
25
|
+
length = history.length;
|
|
26
|
+
try { window.parent.postMessage({ source: 'cezar-preview', type: 'location', url: url, how: how }, parentOrigin); } catch (e) { /* parent gone */ }
|
|
27
|
+
}
|
|
28
|
+
function wrap(name, how) {
|
|
29
|
+
var original = history[name];
|
|
30
|
+
if (typeof original !== 'function') return;
|
|
31
|
+
history[name] = function () {
|
|
32
|
+
var result = original.apply(this, arguments);
|
|
33
|
+
report(how);
|
|
34
|
+
return result;
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
wrap('pushState', 'push');
|
|
38
|
+
wrap('replaceState', 'replace');
|
|
39
|
+
function moved() { report(history.length > length ? 'push' : 'pop'); }
|
|
40
|
+
window.addEventListener('popstate', moved);
|
|
41
|
+
window.addEventListener('hashchange', moved);
|
|
42
|
+
report('load');
|
|
43
|
+
})(__CEZAR_PARENT_ORIGIN__);
|
|
44
|
+
`;
|
|
45
|
+
//# sourceMappingURL=location-reporter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"location-reporter.js","sourceRoot":"","sources":["../../../src/server/preview/location-reporter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,MAAM,UAAU,sBAAsB,CAAC,YAAoB;IACzD,OAAO,wBAAwB,CAAC,OAAO,CAAC,yBAAyB,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,OAAO,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC;AAClI,CAAC;AAED,MAAM,wBAAwB,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6B1C,CAAC"}
|
|
@@ -1,25 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The Design Mode picker — the script the design proxy injects into every HTML page it re-serves
|
|
3
|
-
* (spec `.ai/specs/2026-10-09-design-mode.md`).
|
|
4
|
-
*
|
|
5
|
-
* It runs INSIDE the task's app, which is untrusted and is somebody else's page, so it is written
|
|
6
|
-
* to leave no trace when idle: no listeners that swallow events, no styles, no nodes — until the
|
|
7
|
-
* cockpit switches it on. It speaks to exactly one window (its parent) at exactly one origin (the
|
|
8
|
-
* cockpit's, baked in when the proxy was opened) and listens to nothing else, so neither the app
|
|
9
|
-
* nor a page that frames the proxy can drive it or read what it reports.
|
|
10
|
-
*
|
|
11
|
-
* A string rather than a function serialized with `toString()`: the dev runner (tsx/esbuild) may
|
|
12
|
-
* rewrite function bodies with helpers that do not exist in the page. Plain ES5-flavoured source,
|
|
13
|
-
* because it has to run in whatever the framed app's browser target is, unbundled.
|
|
14
|
-
*
|
|
15
|
-
* A picked element stays MARKED — a lime frame with its number — for as long as the cockpit says
|
|
16
|
-
* it is part of the note being written (`set-marks`). The cockpit owns the list and the numbers;
|
|
17
|
-
* this script only owns the element references, which is why a mark does not survive a reload of
|
|
18
|
-
* the page: the node it pointed at is gone, and guessing a replacement would mark the wrong thing.
|
|
19
|
-
*
|
|
20
|
-
* The caps below are what keep one pick small enough to ride a message: every picked element
|
|
21
|
-
* lives in ONE draft entry on the cockpit side, and an agent needs the element, not the page.
|
|
22
|
-
*/
|
|
23
1
|
export declare const PICKER_PATH = "/__cezar_design__/picker.js";
|
|
24
2
|
export declare const PICK_HTML_MAX = 1500;
|
|
25
3
|
export declare const PICK_TEXT_MAX = 200;
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
* The caps below are what keep one pick small enough to ride a message: every picked element
|
|
21
21
|
* lives in ONE draft entry on the cockpit side, and an agent needs the element, not the page.
|
|
22
22
|
*/
|
|
23
|
+
import { locationReporterScript } from './location-reporter.js';
|
|
23
24
|
export const PICKER_PATH = '/__cezar_design__/picker.js';
|
|
24
25
|
export const PICK_HTML_MAX = 1500;
|
|
25
26
|
export const PICK_TEXT_MAX = 200;
|
|
@@ -27,7 +28,8 @@ export function pickerScript(config) {
|
|
|
27
28
|
// `<` cannot end a script here (this is served as a .js file, not inlined), but escaping it
|
|
28
29
|
// costs nothing and keeps the config inert if that ever changes.
|
|
29
30
|
const json = JSON.stringify({ ...config, htmlMax: PICK_HTML_MAX, textMax: PICK_TEXT_MAX }).replace(/</g, '\\u003c');
|
|
30
|
-
|
|
31
|
+
// The page's address rides along, so the Preview's bar follows in-page moves through the mirror.
|
|
32
|
+
return PICKER_SOURCE.replace('__CEZAR_DESIGN_CONFIG__', () => json) + locationReporterScript(config.parentOrigin);
|
|
31
33
|
}
|
|
32
34
|
const PICKER_SOURCE = String.raw `(function () {
|
|
33
35
|
'use strict';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"picker-script.js","sourceRoot":"","sources":["../../../src/server/preview/picker-script.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG,6BAA6B,CAAC;AAEzD,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,CAAC;AAClC,MAAM,CAAC,MAAM,aAAa,GAAG,GAAG,CAAC;AASjC,MAAM,UAAU,YAAY,CAAC,MAAoB;IAC/C,4FAA4F;IAC5F,iEAAiE;IACjE,MAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,GAAG,MAAM,EAAE,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,aAAa,EAAE,CAAC,CAAC,OAAO,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC;IACpH,OAAO,aAAa,CAAC,OAAO,CAAC,yBAAyB,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"picker-script.js","sourceRoot":"","sources":["../../../src/server/preview/picker-script.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,MAAM,CAAC,MAAM,WAAW,GAAG,6BAA6B,CAAC;AAEzD,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,CAAC;AAClC,MAAM,CAAC,MAAM,aAAa,GAAG,GAAG,CAAC;AASjC,MAAM,UAAU,YAAY,CAAC,MAAoB;IAC/C,4FAA4F;IAC5F,iEAAiE;IACjE,MAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,GAAG,MAAM,EAAE,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,aAAa,EAAE,CAAC,CAAC,OAAO,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC;IACpH,iGAAiG;IACjG,OAAO,aAAa,CAAC,OAAO,CAAC,yBAAyB,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,GAAG,sBAAsB,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC;AACpH,CAAC;AAED,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqb/B,CAAC"}
|
package/dist/server/server.d.ts
CHANGED
|
@@ -10872,6 +10872,19 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
10872
10872
|
} & {
|
|
10873
10873
|
"/repo/commit/:sha": {
|
|
10874
10874
|
$get: {
|
|
10875
|
+
output: string;
|
|
10876
|
+
outputFormat: "text";
|
|
10877
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
10878
|
+
input: {
|
|
10879
|
+
query: {
|
|
10880
|
+
structured?: string | string[] | undefined;
|
|
10881
|
+
};
|
|
10882
|
+
} & {
|
|
10883
|
+
param: {
|
|
10884
|
+
sha: string;
|
|
10885
|
+
};
|
|
10886
|
+
};
|
|
10887
|
+
} | {
|
|
10875
10888
|
output: {
|
|
10876
10889
|
sha: string;
|
|
10877
10890
|
subject: string;
|
|
@@ -10919,19 +10932,6 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
10919
10932
|
sha: string;
|
|
10920
10933
|
};
|
|
10921
10934
|
};
|
|
10922
|
-
} | {
|
|
10923
|
-
output: string;
|
|
10924
|
-
outputFormat: "text";
|
|
10925
|
-
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
10926
|
-
input: {
|
|
10927
|
-
query: {
|
|
10928
|
-
structured?: string | string[] | undefined;
|
|
10929
|
-
};
|
|
10930
|
-
} & {
|
|
10931
|
-
param: {
|
|
10932
|
-
sha: string;
|
|
10933
|
-
};
|
|
10934
|
-
};
|
|
10935
10935
|
};
|
|
10936
10936
|
};
|
|
10937
10937
|
} & {
|
|
@@ -16910,20 +16910,20 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
16910
16910
|
} & {
|
|
16911
16911
|
"/runs/:id/handoff": {
|
|
16912
16912
|
$get: {
|
|
16913
|
-
output:
|
|
16914
|
-
|
|
16915
|
-
|
|
16916
|
-
outputFormat: "json";
|
|
16917
|
-
status: 404;
|
|
16913
|
+
output: string;
|
|
16914
|
+
outputFormat: "text";
|
|
16915
|
+
status: 200;
|
|
16918
16916
|
input: {
|
|
16919
16917
|
param: {
|
|
16920
16918
|
id: string;
|
|
16921
16919
|
};
|
|
16922
16920
|
};
|
|
16923
16921
|
} | {
|
|
16924
|
-
output:
|
|
16925
|
-
|
|
16926
|
-
|
|
16922
|
+
output: {
|
|
16923
|
+
error: string;
|
|
16924
|
+
};
|
|
16925
|
+
outputFormat: "json";
|
|
16926
|
+
status: 404;
|
|
16927
16927
|
input: {
|
|
16928
16928
|
param: {
|
|
16929
16929
|
id: string;
|
|
@@ -16949,20 +16949,20 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
16949
16949
|
} & {
|
|
16950
16950
|
"/runs/:id/diff": {
|
|
16951
16951
|
$get: {
|
|
16952
|
-
output:
|
|
16953
|
-
|
|
16954
|
-
|
|
16955
|
-
outputFormat: "json";
|
|
16956
|
-
status: 404;
|
|
16952
|
+
output: string;
|
|
16953
|
+
outputFormat: "text";
|
|
16954
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
16957
16955
|
input: {
|
|
16958
16956
|
param: {
|
|
16959
16957
|
id: string;
|
|
16960
16958
|
};
|
|
16961
16959
|
};
|
|
16962
16960
|
} | {
|
|
16963
|
-
output:
|
|
16964
|
-
|
|
16965
|
-
|
|
16961
|
+
output: {
|
|
16962
|
+
error: string;
|
|
16963
|
+
};
|
|
16964
|
+
outputFormat: "json";
|
|
16965
|
+
status: 404;
|
|
16966
16966
|
input: {
|
|
16967
16967
|
param: {
|
|
16968
16968
|
id: string;
|
|
@@ -24502,6 +24502,19 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
24502
24502
|
} & {
|
|
24503
24503
|
"/repo/commit/:sha": {
|
|
24504
24504
|
$get: {
|
|
24505
|
+
output: string;
|
|
24506
|
+
outputFormat: "text";
|
|
24507
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
24508
|
+
input: {
|
|
24509
|
+
query: {
|
|
24510
|
+
structured?: string | string[] | undefined;
|
|
24511
|
+
};
|
|
24512
|
+
} & {
|
|
24513
|
+
param: {
|
|
24514
|
+
sha: string;
|
|
24515
|
+
};
|
|
24516
|
+
};
|
|
24517
|
+
} | {
|
|
24505
24518
|
output: {
|
|
24506
24519
|
sha: string;
|
|
24507
24520
|
subject: string;
|
|
@@ -24549,19 +24562,6 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
24549
24562
|
sha: string;
|
|
24550
24563
|
};
|
|
24551
24564
|
};
|
|
24552
|
-
} | {
|
|
24553
|
-
output: string;
|
|
24554
|
-
outputFormat: "text";
|
|
24555
|
-
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
24556
|
-
input: {
|
|
24557
|
-
query: {
|
|
24558
|
-
structured?: string | string[] | undefined;
|
|
24559
|
-
};
|
|
24560
|
-
} & {
|
|
24561
|
-
param: {
|
|
24562
|
-
sha: string;
|
|
24563
|
-
};
|
|
24564
|
-
};
|
|
24565
24565
|
};
|
|
24566
24566
|
};
|
|
24567
24567
|
} & {
|
|
@@ -30540,20 +30540,20 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
30540
30540
|
} & {
|
|
30541
30541
|
"/runs/:id/handoff": {
|
|
30542
30542
|
$get: {
|
|
30543
|
-
output:
|
|
30544
|
-
|
|
30545
|
-
|
|
30546
|
-
outputFormat: "json";
|
|
30547
|
-
status: 404;
|
|
30543
|
+
output: string;
|
|
30544
|
+
outputFormat: "text";
|
|
30545
|
+
status: 200;
|
|
30548
30546
|
input: {
|
|
30549
30547
|
param: {
|
|
30550
30548
|
id: string;
|
|
30551
30549
|
};
|
|
30552
30550
|
};
|
|
30553
30551
|
} | {
|
|
30554
|
-
output:
|
|
30555
|
-
|
|
30556
|
-
|
|
30552
|
+
output: {
|
|
30553
|
+
error: string;
|
|
30554
|
+
};
|
|
30555
|
+
outputFormat: "json";
|
|
30556
|
+
status: 404;
|
|
30557
30557
|
input: {
|
|
30558
30558
|
param: {
|
|
30559
30559
|
id: string;
|
|
@@ -30579,20 +30579,20 @@ export declare function createApp(deps: ServerDeps): import("hono/hono-base").Ho
|
|
|
30579
30579
|
} & {
|
|
30580
30580
|
"/runs/:id/diff": {
|
|
30581
30581
|
$get: {
|
|
30582
|
-
output:
|
|
30583
|
-
|
|
30584
|
-
|
|
30585
|
-
outputFormat: "json";
|
|
30586
|
-
status: 404;
|
|
30582
|
+
output: string;
|
|
30583
|
+
outputFormat: "text";
|
|
30584
|
+
status: import("hono/utils/http-status").ContentfulStatusCode;
|
|
30587
30585
|
input: {
|
|
30588
30586
|
param: {
|
|
30589
30587
|
id: string;
|
|
30590
30588
|
};
|
|
30591
30589
|
};
|
|
30592
30590
|
} | {
|
|
30593
|
-
output:
|
|
30594
|
-
|
|
30595
|
-
|
|
30591
|
+
output: {
|
|
30592
|
+
error: string;
|
|
30593
|
+
};
|
|
30594
|
+
outputFormat: "json";
|
|
30595
|
+
status: 404;
|
|
30596
30596
|
input: {
|
|
30597
30597
|
param: {
|
|
30598
30598
|
id: string;
|
|
@@ -233,7 +233,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
233
233
|
error: string;
|
|
234
234
|
};
|
|
235
235
|
outputFormat: "json";
|
|
236
|
-
status: 400;
|
|
236
|
+
status: 400 | 404 | 409;
|
|
237
237
|
input: {
|
|
238
238
|
param: {
|
|
239
239
|
operationId: string;
|
|
@@ -244,7 +244,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
244
244
|
error: string;
|
|
245
245
|
};
|
|
246
246
|
outputFormat: "json";
|
|
247
|
-
status: 400
|
|
247
|
+
status: 400;
|
|
248
248
|
input: {
|
|
249
249
|
param: {
|
|
250
250
|
operationId: string;
|
|
@@ -317,7 +317,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
317
317
|
error: string;
|
|
318
318
|
};
|
|
319
319
|
outputFormat: "json";
|
|
320
|
-
status: 400;
|
|
320
|
+
status: 400 | 404 | 409;
|
|
321
321
|
input: {
|
|
322
322
|
param: {
|
|
323
323
|
operationId: string;
|
|
@@ -334,7 +334,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
334
334
|
error: string;
|
|
335
335
|
};
|
|
336
336
|
outputFormat: "json";
|
|
337
|
-
status: 400
|
|
337
|
+
status: 400;
|
|
338
338
|
input: {
|
|
339
339
|
param: {
|
|
340
340
|
operationId: string;
|
|
@@ -419,7 +419,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
419
419
|
error: string;
|
|
420
420
|
};
|
|
421
421
|
outputFormat: "json";
|
|
422
|
-
status: 400;
|
|
422
|
+
status: 400 | 404 | 409;
|
|
423
423
|
input: {
|
|
424
424
|
param: {
|
|
425
425
|
operationId: string;
|
|
@@ -435,7 +435,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
435
435
|
error: string;
|
|
436
436
|
};
|
|
437
437
|
outputFormat: "json";
|
|
438
|
-
status: 400
|
|
438
|
+
status: 400;
|
|
439
439
|
input: {
|
|
440
440
|
param: {
|
|
441
441
|
operationId: string;
|
|
@@ -479,7 +479,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
479
479
|
error: string;
|
|
480
480
|
};
|
|
481
481
|
outputFormat: "json";
|
|
482
|
-
status: 400;
|
|
482
|
+
status: 400 | 404 | 409;
|
|
483
483
|
input: {
|
|
484
484
|
param: {
|
|
485
485
|
worktreeId: string;
|
|
@@ -490,7 +490,7 @@ export declare function worktreeLifecycleRoutes(opts?: {
|
|
|
490
490
|
error: string;
|
|
491
491
|
};
|
|
492
492
|
outputFormat: "json";
|
|
493
|
-
status: 400
|
|
493
|
+
status: 400;
|
|
494
494
|
input: {
|
|
495
495
|
param: {
|
|
496
496
|
worktreeId: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@open-mercato/cezar",
|
|
3
|
-
"version": "0.16.2-
|
|
3
|
+
"version": "0.16.2-pr1637.3572",
|
|
4
4
|
"description": "Local cockpit for running and tracking AI agent tasks in your repo. Uses your logged-in `claude` CLI and `gh` — zero config, zero database.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -54,8 +54,8 @@
|
|
|
54
54
|
"zod": "^4.4.3"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
57
|
-
"@open-mercato/cezar-api-client": "0.16.2-
|
|
58
|
-
"@open-mercato/cezar-contract": "0.16.2-
|
|
57
|
+
"@open-mercato/cezar-api-client": "0.16.2-pr1637.3572",
|
|
58
|
+
"@open-mercato/cezar-contract": "0.16.2-pr1637.3572",
|
|
59
59
|
"@types/node": "^20.14.0",
|
|
60
60
|
"@types/proper-lockfile": "4.1.4",
|
|
61
61
|
"@types/ws": "^8.18.1",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-QTnfLwEv.js";import{i as t,t as n}from"./react-runtime-CCIEwYL0.js";import{r}from"./button-Clwd6u4_.js";import{t as i}from"./project-router-DZsR9P9C.js";import{a,o,r as s}from"./reference-chip-DnemrSPW.js";import{d as c,f as l,h as u,l as d,m as f,p}from"./use-now-pBdvhv13.js";import{bn as m,x as h}from"./git-tab-loading-BfC2ir8N.js";import{B as g,L as _,N as v,V as y,z as b}from"./worktree-lifecycle-operation-
|
|
1
|
+
import{r as e}from"./rolldown-runtime-QTnfLwEv.js";import{i as t,t as n}from"./react-runtime-CCIEwYL0.js";import{r}from"./button-Clwd6u4_.js";import{t as i}from"./project-router-DZsR9P9C.js";import{a,o,r as s}from"./reference-chip-DnemrSPW.js";import{d as c,f as l,h as u,l as d,m as f,p}from"./use-now-pBdvhv13.js";import{bn as m,x as h}from"./git-tab-loading-BfC2ir8N.js";import{B as g,L as _,N as v,V as y,z as b}from"./worktree-lifecycle-operation-DOTiqQFx.js";import{n as x}from"./textarea-ewNKsXDa.js";import{t as S}from"./check-Dt8U0Zvm.js";import{f as C}from"./tooltip-B628Gs7C.js";import{m as w}from"./git-toolbar-DU5Ca6RI.js";import{c as T}from"./index-mdntR9AC.js";var E=n();function D({name:e,route:t,selected:n,list:i,detail:a}){return(0,E.jsxs)(`div`,{"data-route":t,className:`flex h-full min-h-0 items-stretch`,children:[(0,E.jsx)(`section`,{"data-slot":`${e}-list`,className:r(`w-full min-h-0 flex-col overflow-y-auto overscroll-contain border-border md:flex md:w-[360px] md:shrink-0 md:border-r`,n?`hidden`:`flex`),children:i}),(0,E.jsx)(`section`,{"data-slot":`${e}-detail`,className:r(`min-w-0 min-h-0 flex-1 flex-col overflow-y-auto overscroll-contain`,n?`flex`:`hidden md:flex`),children:a})]})}function O(e){return`${e.kind===`pr`?`Address GitHub pull request`:`Fix GitHub issue`} #${e.number}: ${e.title}\n\n${e.url}`}function k(e,t=[]){let n=O(e);return e.body?.trim()&&(n+=`\n\n---\n\n${e.body.trim()}`),t.length&&(n+=A(t)),n}function A(e){return`\n\nUse these skills where relevant: ${e.join(`, `)}.`}function j(e,t){return e.replace(/\{\{\s*number\s*\}\}/gi,()=>`#${t.number}`).replace(/\{\{\s*title\s*\}\}/gi,()=>t.title).replace(/\{\{\s*url\s*\}\}/gi,()=>t.url)}function M(e,t){if(e.includes(t.url))return!0;let n=t.kind===`pr`?String.raw`(?:pull\s+request|pr)`:String.raw`issue`;return new RegExp(String.raw`\b${n}\s*#?\s*${t.number}\b`,`i`).test(e)}function N(e,t,n){let r=(n??``).trim();if(!r)return k(e,t);let i=O(e),a=r.startsWith(i)?i+j(r.slice(i.length),e):j(r,e),o=M(a,e)?a:`${i}\n\n${a}`;return t.length?o+A(t):o}function P(e){let t=[];for(let n of e.slice(0,8)){let e=new Set(t.map(e=>e.id)),r=n;for(let t=2;e.has(r);t++)r=`${n}-${t}`;t.push({id:r,name:n,skill:n,prompt:`{{task}}`})}return t}function F(e,t,n,r,i={}){return t?{...i,workflow:t,task:N(e,n,r)}:n.length?{...i,steps:P(n),task:N(e,[],r)}:{...i,workflow:`quick-task`,task:N(e,[],r)}}function I({resolved:e,dataSlot:t}){return e.providerPending||e.canRun?null:(0,E.jsxs)(`span`,{"data-slot":t,className:`inline-flex flex-wrap items-center gap-1 text-xs text-muted-foreground`,children:[e.providerError?`Provider authentication could not be verified.`:`Connect an agent provider to run this item.`,(0,E.jsx)(i,{to:`/settings/agents#providers`,className:`font-medium text-foreground underline underline-offset-4`,children:`Configure providers`})]})}var L=e(t(),1);function R({workflows:e,value:t,onChange:n,slotPrefix:i=`gh`}){let[m,_]=(0,L.useState)(!1),[v,b]=(0,L.useState)(``),w=(0,L.useRef)(null),T=g(e,v);return(0,E.jsxs)(s,{open:m,onOpenChange:e=>{_(e),e||b(``)},children:[(0,E.jsx)(o,{asChild:!0,children:(0,E.jsxs)(`button`,{type:`button`,"data-slot":`${i}-workflow-trigger`,"aria-label":`Choose a workflow`,className:r(h,t&&`border-foreground/60 font-mono text-[11.5px] font-semibold text-foreground`),children:[(0,E.jsx)(x,{"aria-hidden":`true`,className:`size-3 shrink-0 text-violet`}),(0,E.jsx)(`span`,{className:`max-w-44 truncate`,children:t??`workflow`}),(0,E.jsx)(C,{"aria-hidden":`true`,className:`size-2.5 shrink-0 text-soft-foreground`})]})}),(0,E.jsx)(a,{align:`start`,sideOffset:8,className:`w-[320px] max-w-[calc(100vw-2rem)] p-0`,children:(0,E.jsxs)(d,{label:`Choose a workflow`,shouldFilter:!1,children:[(0,E.jsx)(p,{placeholder:`search workflows…`,value:v,onValueChange:b,onInput:()=>w.current?.scrollTo(0,0)}),(0,E.jsxs)(u,{ref:w,"data-slot":`${i}-workflow-menu`,className:`max-h-[min(16rem,calc(var(--radix-popover-content-available-height)-3rem))]`,children:[T.length===0?(0,E.jsx)(c,{children:`Nothing matches.`}):null,(0,E.jsx)(l,{children:T.map(e=>{let r=t===e.name;return(0,E.jsxs)(f,{value:`workflow ${e.name}`,keywords:y(e.name,e.description),"data-slot":`${i}-workflow-option`,"data-workflow":e.name,onSelect:()=>{n(r?null:e.name),_(!1)},children:[(0,E.jsx)(`span`,{className:`shrink-0 font-mono text-xs`,children:e.name}),e.description?(0,E.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-xs text-soft-foreground`,children:e.description}):null,r?(0,E.jsx)(S,{"aria-hidden":`true`,className:`ml-auto size-3.5 shrink-0 text-primary`}):null]},e.name)})})]})]})})]})}function z({skills:e,skillUsage:t,selected:n,onToggle:i,maxSelections:g,slotPrefix:x=`gh`}){let[D,O]=(0,L.useState)(!1),[k,A]=(0,L.useState)(``),[j,M]=(0,L.useState)(null),N=(0,L.useRef)(null),{mostUsed:P,project:F,global:I}=_(b(e,k,t),t),R=(e,t)=>{let a=n.includes(e.name);return(0,E.jsxs)(f,{value:`skill ${e.name} ${e.path}`,keywords:y(e.name,e.description),"data-slot":`${x}-skill-option`,"data-skill":e.name,"data-selected":a?`true`:void 0,disabled:!a&&g!==void 0&&n.length>=g,onSelect:()=>i(e.name),children:[(0,E.jsx)(`span`,{className:r(`shrink-0 font-mono text-xs`,t&&`font-semibold`),children:e.name}),e.description?(0,E.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-xs text-soft-foreground`,children:e.description}):null,(0,E.jsx)(`button`,{type:`button`,"data-slot":`${x}-skill-view`,"aria-label":`View skill ${e.name}`,title:`View skill`,onClick:t=>{t.preventDefault(),t.stopPropagation(),M(e)},className:`ml-auto shrink-0 rounded-sm p-0.5 text-soft-foreground transition-colors hover:text-foreground`,children:(0,E.jsx)(w,{"aria-hidden":`true`,className:`size-3.5`})}),a?(0,E.jsx)(S,{"aria-hidden":`true`,className:`size-3.5 shrink-0 text-primary`}):null]},e.path)};return e.length===0?null:(0,E.jsxs)(E.Fragment,{children:[(0,E.jsx)(T,{skill:j,onClose:()=>M(null)}),(0,E.jsxs)(s,{open:D,onOpenChange:e=>{O(e),e||A(``)},children:[(0,E.jsx)(o,{asChild:!0,children:(0,E.jsxs)(`button`,{type:`button`,"data-slot":`${x}-skills-trigger`,"aria-label":`Choose skills`,className:r(h,n.length>0&&`border-foreground/60 font-semibold text-foreground`),children:[(0,E.jsx)(m,{"aria-hidden":`true`,className:`size-3 shrink-0 text-violet`}),`skills`,n.length>0?` · ${n.length}`:``,(0,E.jsx)(C,{"aria-hidden":`true`,className:`size-2.5 shrink-0 text-soft-foreground`})]})}),(0,E.jsx)(a,{align:`start`,sideOffset:8,className:`w-[336px] max-w-[calc(100vw-2rem)] p-0`,children:(0,E.jsxs)(d,{label:`Choose skills`,shouldFilter:!1,children:[(0,E.jsx)(p,{placeholder:`search skills…`,value:k,onValueChange:A,onInput:()=>N.current?.scrollTo(0,0)}),(0,E.jsxs)(u,{ref:N,"data-slot":`${x}-skill-menu`,className:`max-h-[min(16rem,calc(var(--radix-popover-content-available-height)-3rem))]`,children:[P.length===0&&F.length===0&&I.length===0?(0,E.jsx)(c,{children:`Nothing matches.`}):null,P.length>0?(0,E.jsx)(l,{heading:`Most used`,children:P.map(e=>R(e,v(e)))}):null,F.length>0?(0,E.jsx)(l,{heading:`Project skills`,children:F.map(e=>R(e,!0))}):null,I.length>0?(0,E.jsx)(l,{heading:`Global`,children:I.map(e=>R(e,!1))}):null]})]})})]})]})}export{k as a,D as c,F as i,R as n,O as o,I as r,P as s,z as t};
|