openplanr 2.2641.2 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/dist/cli/commands/doctor.d.ts.map +1 -1
  3. package/dist/cli/commands/doctor.js +19 -4
  4. package/dist/cli/commands/doctor.js.map +1 -1
  5. package/dist/cli/commands/upgrade.d.ts.map +1 -1
  6. package/dist/cli/commands/upgrade.js +12 -10
  7. package/dist/cli/commands/upgrade.js.map +1 -1
  8. package/dist/cli/error-boundary.d.ts.map +1 -1
  9. package/dist/cli/error-boundary.js +2 -1
  10. package/dist/cli/error-boundary.js.map +1 -1
  11. package/dist/dashboard/.vite/manifest.json +1 -1
  12. package/dist/dashboard/assets/{index-DI_TKz9J.js → index-Csby7_ur.js} +2 -2
  13. package/dist/dashboard/assets/{index-DI_TKz9J.js.map → index-Csby7_ur.js.map} +1 -1
  14. package/dist/dashboard/dashboard-manifest.json +8 -8
  15. package/dist/dashboard/index.html +1 -1
  16. package/dist/services/runtime-change-summary.d.ts +4 -0
  17. package/dist/services/runtime-change-summary.d.ts.map +1 -1
  18. package/dist/services/runtime-change-summary.js +7 -0
  19. package/dist/services/runtime-change-summary.js.map +1 -1
  20. package/dist/services/runtime-manager/doctor.js +1 -1
  21. package/dist/services/runtime-manager/doctor.js.map +1 -1
  22. package/dist/services/runtime-manager/runtime-package.d.ts +15 -0
  23. package/dist/services/runtime-manager/runtime-package.d.ts.map +1 -1
  24. package/dist/services/runtime-manager/runtime-package.js +50 -10
  25. package/dist/services/runtime-manager/runtime-package.js.map +1 -1
  26. package/dist/services/runtime-manager-service.d.ts +11 -0
  27. package/dist/services/runtime-manager-service.d.ts.map +1 -1
  28. package/dist/services/runtime-manager-service.js +88 -16
  29. package/dist/services/runtime-manager-service.js.map +1 -1
  30. package/dist/services/upgrade-report.d.ts +2 -2
  31. package/dist/services/upgrade-report.d.ts.map +1 -1
  32. package/dist/services/upgrade-report.js +11 -2
  33. package/dist/services/upgrade-report.js.map +1 -1
  34. package/dist/services/upgrade-service.d.ts +8 -2
  35. package/dist/services/upgrade-service.d.ts.map +1 -1
  36. package/dist/services/upgrade-service.js +44 -12
  37. package/dist/services/upgrade-service.js.map +1 -1
  38. package/docs/CLI.md +4 -1
  39. package/docs/TROUBLESHOOTING.md +9 -6
  40. package/install.ps1 +3 -3
  41. package/install.sh +3 -3
  42. package/lib/host-packages/adapter-registry.json +5 -5
  43. package/lib/host-packages/capability-map.json +1 -1
  44. package/lib/host-packages/claude/.claude-plugin/marketplace.json +2 -2
  45. package/lib/host-packages/claude/openplanr/.claude-plugin/plugin.json +2 -2
  46. package/lib/host-packages/claude/openplanr/.openplanr-content.json +21 -21
  47. package/lib/host-packages/claude/openplanr/README.md +1 -1
  48. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/lib/artifact/ui/studio-shell.css +1 -1
  49. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/package.json +4 -4
  50. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/enhancements.css +14 -4
  51. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.css +14 -5
  52. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/12-design-review-experience.js +28 -0
  53. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/16-studio-shell.js +105 -27
  54. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources.json +6 -6
  55. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/protocol/package.json +2 -2
  56. package/lib/host-packages/claude/openplanr/runtime/plan/scripts/runtime/packages/protocol/package.json +2 -2
  57. package/lib/host-packages/claude/openplanr/skills/delegate/SKILL.md +1 -1
  58. package/lib/host-packages/claude/openplanr/skills/delegate/references/capsule-contract.md +1 -1
  59. package/lib/host-packages/claude/openplanr/skills/delegate/scripts/run-preparation.mjs +3 -3
  60. package/lib/host-packages/claude/openplanr/skills/design/references/utilities.md +1 -1
  61. package/lib/host-packages/claude/openplanr/skills/design-loop/references/utilities.md +1 -1
  62. package/lib/host-packages/claude/openplanr/skills/design-review/references/utilities.md +1 -1
  63. package/lib/host-packages/claude/openplanr/skills/doctor/SKILL.md +4 -1
  64. package/lib/host-packages/claude/openplanr/skills/doctor/references/upgrade.md +8 -0
  65. package/lib/host-packages/claude/openplanr/skills/plan/SKILL.md +2 -2
  66. package/lib/host-packages/cursor/openplanr/.openplanr-content.json +20 -20
  67. package/lib/host-packages/cursor/openplanr/manifest.json +1 -1
  68. package/lib/host-packages/cursor/openplanr/rules/planr-delegate/references/capsule-contract.md +1 -1
  69. package/lib/host-packages/cursor/openplanr/rules/planr-delegate/scripts/run-preparation.mjs +3 -3
  70. package/lib/host-packages/cursor/openplanr/rules/planr-delegate.mdc +1 -1
  71. package/lib/host-packages/cursor/openplanr/rules/planr-design/references/utilities.md +1 -1
  72. package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/utilities.md +1 -1
  73. package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/utilities.md +1 -1
  74. package/lib/host-packages/cursor/openplanr/rules/planr-doctor/references/upgrade.md +8 -0
  75. package/lib/host-packages/cursor/openplanr/rules/planr-doctor.mdc +4 -1
  76. package/lib/host-packages/cursor/openplanr/rules/planr-plan.mdc +2 -2
  77. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/lib/artifact/ui/studio-shell.css +1 -1
  78. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/package.json +4 -4
  79. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/enhancements.css +14 -4
  80. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.css +14 -5
  81. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/12-design-review-experience.js +28 -0
  82. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/16-studio-shell.js +105 -27
  83. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources.json +6 -6
  84. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/protocol/package.json +2 -2
  85. package/lib/host-packages/cursor/openplanr/runtime/plan/scripts/runtime/packages/protocol/package.json +2 -2
  86. package/lib/host-packages/openai/.claude-plugin/marketplace.json +2 -2
  87. package/lib/host-packages/openai/openplanr/.codex-plugin/plugin.json +1 -1
  88. package/lib/host-packages/openai/openplanr/.openplanr-content.json +20 -20
  89. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/lib/artifact/ui/studio-shell.css +1 -1
  90. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/package.json +4 -4
  91. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/enhancements.css +14 -4
  92. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.css +14 -5
  93. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/12-design-review-experience.js +28 -0
  94. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/16-studio-shell.js +105 -27
  95. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources.json +6 -6
  96. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/protocol/package.json +2 -2
  97. package/lib/host-packages/openai/openplanr/runtime/plan/scripts/runtime/packages/protocol/package.json +2 -2
  98. package/lib/host-packages/openai/openplanr/skills/delegate/SKILL.md +1 -1
  99. package/lib/host-packages/openai/openplanr/skills/delegate/references/capsule-contract.md +1 -1
  100. package/lib/host-packages/openai/openplanr/skills/delegate/scripts/run-preparation.mjs +3 -3
  101. package/lib/host-packages/openai/openplanr/skills/design/references/utilities.md +1 -1
  102. package/lib/host-packages/openai/openplanr/skills/design-loop/references/utilities.md +1 -1
  103. package/lib/host-packages/openai/openplanr/skills/design-review/references/utilities.md +1 -1
  104. package/lib/host-packages/openai/openplanr/skills/doctor/SKILL.md +4 -1
  105. package/lib/host-packages/openai/openplanr/skills/doctor/references/upgrade.md +8 -0
  106. package/lib/host-packages/openai/openplanr/skills/plan/SKILL.md +2 -2
  107. package/lib/node-runtime.d.mts +1 -1
  108. package/lib/node-runtime.mjs +2 -7
  109. package/package.json +4 -5
  110. package/bin/planr.js +0 -7
@@ -2307,6 +2307,33 @@ ${fence}`;
2307
2307
  );
2308
2308
  content.append(value, reason, save);
2309
2309
  }
2310
+ function installStageContextGeometry() {
2311
+ const context = q(".design-stage-context", root);
2312
+ if (!context) return;
2313
+ let frame = 0;
2314
+ const measure = () => {
2315
+ frame = 0;
2316
+ if (disposed) return;
2317
+ const height = Math.ceil(context.getBoundingClientRect().height);
2318
+ const value = `${height}px`;
2319
+ if (height && root.style.getPropertyValue("--design-stage-context-measured-height") !== value)
2320
+ root.style.setProperty("--design-stage-context-measured-height", value);
2321
+ };
2322
+ const schedule = () => {
2323
+ if (!frame && !disposed) frame = requestAnimationFrame(measure);
2324
+ };
2325
+ const observer = typeof ResizeObserver === "function" ? new ResizeObserver(schedule) : null;
2326
+ observer?.observe(context);
2327
+ on(window, "resize", schedule);
2328
+ on(root, "planr:design-render", schedule);
2329
+ void document.fonts?.ready.then(schedule);
2330
+ measure();
2331
+ destroyers.push(() => {
2332
+ observer?.disconnect();
2333
+ cancelAnimationFrame(frame);
2334
+ root.style.removeProperty("--design-stage-context-measured-height");
2335
+ });
2336
+ }
2310
2337
  function installCanvas() {
2311
2338
  const tools = q(".design-canvas-tools");
2312
2339
  const more = node("details", "", { class: "design-tools-menu" });
@@ -3494,6 +3521,7 @@ ${fence}`;
3494
3521
  installComposerCategory();
3495
3522
  installInspector();
3496
3523
  installCanvas();
3524
+ installStageContextGeometry();
3497
3525
  installThumbnails();
3498
3526
  installPersonalDrafts();
3499
3527
  about(true);
@@ -46,36 +46,114 @@
46
46
  actions,
47
47
  className = ""
48
48
  }) {
49
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(Tag, { className: `planr-toolbar studio-toolbar ${className}`, "data-studio-react-chrome": "true", children: [
50
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "studio-toolbar-leading design-toolbar-leading", children: [
51
- leading,
52
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "planr-brand", children: [
53
- brand && /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(import_jsx_runtime15.Fragment, { children: [
54
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StudioMark, {}),
55
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { className: "design-wordmark", children: [
56
- "Open",
57
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { children: "Planr" })
49
+ const toolbar = (0, import_react3.useRef)(null);
50
+ (0, import_react3.useLayoutEffect)(() => {
51
+ const element = toolbar.current;
52
+ const window2 = element?.ownerDocument.defaultView;
53
+ if (!element || !window2) return;
54
+ const center = element.querySelector(".studio-toolbar-center");
55
+ const trailing = element.querySelector(".studio-toolbar-trailing");
56
+ const leading2 = element.querySelector(".studio-toolbar-leading");
57
+ if (!center || !trailing || !leading2) return;
58
+ const measure = () => {
59
+ const width = element.getBoundingClientRect().width;
60
+ if (!width) return;
61
+ element.dataset.studioDensity = width <= 680 ? "narrow" : "regular";
62
+ const style = window2.getComputedStyle(element);
63
+ const available = width - parseFloat(style.paddingLeft) - parseFloat(style.paddingRight);
64
+ const gap = parseFloat(style.columnGap) || 0;
65
+ element.dataset.studioCenter = "true";
66
+ const centerWidth = center.scrollWidth;
67
+ element.dataset.studioCenter = String(centerWidth > 0);
68
+ const controlSelector = 'button,a,summary,input,select,output,[role="status"]';
69
+ const controls = [...trailing.querySelectorAll(controlSelector)].filter(
70
+ (control) => control.getClientRects().length && !control.closest('[role="menu"],.studio-tooltip,[role="dialog"]') && (!control.closest("details") || !!control.closest("summary")) && !control.parentElement?.closest(controlSelector)
71
+ );
72
+ const actionWidth = controls.reduce((total, control) => total + control.getBoundingClientRect().width, 0) + Math.max(0, controls.length - 1) * (parseFloat(window2.getComputedStyle(trailing).gap) || 8);
73
+ const leadingControl = leading2.firstElementChild;
74
+ const branding = [
75
+ ...leading2.querySelectorAll(".planr-mark,.design-wordmark")
76
+ ].filter((node) => node.getClientRects().length);
77
+ const brandingWidth = branding.reduce(
78
+ (total, node) => total + node.getBoundingClientRect().width + 8,
79
+ 0
80
+ );
81
+ const leadingFloor = 128 + brandingWidth + (leadingControl instanceof window2.HTMLElement && !leadingControl.classList.contains("planr-brand") ? leadingControl.getBoundingClientRect().width + 8 : 0);
82
+ const outerWidth = Math.max(leadingFloor, actionWidth);
83
+ element.dataset.studioLayout = centerWidth > 0 ? width <= 680 || centerWidth + outerWidth * 2 + gap * 2 > available ? "compact" : "inline" : leadingFloor + actionWidth + gap > available ? "compact" : "inline";
84
+ };
85
+ measure();
86
+ let frame = 0;
87
+ const scheduleMeasure = () => {
88
+ if (frame) return;
89
+ frame = window2.requestAnimationFrame(() => {
90
+ frame = 0;
91
+ measure();
92
+ });
93
+ };
94
+ const resize = typeof window2.ResizeObserver === "function" ? new window2.ResizeObserver(scheduleMeasure) : null;
95
+ for (const node of [element, center, trailing]) resize?.observe(node);
96
+ const mutations = new window2.MutationObserver(scheduleMeasure);
97
+ mutations.observe(element, {
98
+ subtree: true,
99
+ childList: true,
100
+ characterData: true,
101
+ attributes: true,
102
+ attributeFilter: ["hidden"]
103
+ });
104
+ window2.addEventListener("resize", scheduleMeasure);
105
+ let active = true;
106
+ void element.ownerDocument.fonts?.ready.then(() => {
107
+ if (active) scheduleMeasure();
108
+ });
109
+ return () => {
110
+ active = false;
111
+ resize?.disconnect();
112
+ mutations.disconnect();
113
+ window2.cancelAnimationFrame(frame);
114
+ window2.removeEventListener("resize", scheduleMeasure);
115
+ };
116
+ }, [Tag]);
117
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
118
+ Tag,
119
+ {
120
+ ref: (node) => {
121
+ toolbar.current = node;
122
+ },
123
+ className: `planr-toolbar studio-toolbar ${className}`,
124
+ "data-studio-react-chrome": "true",
125
+ children: [
126
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "studio-toolbar-leading design-toolbar-leading", children: [
127
+ leading,
128
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "planr-brand", children: [
129
+ brand && /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(import_jsx_runtime15.Fragment, { children: [
130
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StudioMark, {}),
131
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { className: "design-wordmark", children: [
132
+ "Open",
133
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { children: "Planr" })
134
+ ] })
135
+ ] }),
136
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "studio-identity", children: [
137
+ hierarchy.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("nav", { className: "studio-hierarchy", "aria-label": "Project path", children: hierarchy.map((item, index2) => /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { children: [
138
+ index2 > 0 && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { "aria-hidden": "true", children: " / " }),
139
+ item.href ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("a", { href: item.href, children: item.label }) : item.label
140
+ ] }, item.href ?? item.label)) }),
141
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { className: "planr-title-block", children: [
142
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StudioBadge, { children: kind === "artifact" ? "Artifact" : kind === "diagram" ? "Diagram" : "Design" }),
143
+ titleNode ?? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("strong", { title, children: title })
144
+ ] }),
145
+ subtitle && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "studio-subtitle", children: subtitle })
146
+ ] })
58
147
  ] })
59
148
  ] }),
60
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "studio-identity", children: [
61
- hierarchy.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("nav", { className: "studio-hierarchy", "aria-label": "Project path", children: hierarchy.map((item, index2) => /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { children: [
62
- index2 > 0 && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { "aria-hidden": "true", children: " / " }),
63
- item.href ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("a", { href: item.href, children: item.label }) : item.label
64
- ] }, item.href ?? item.label)) }),
65
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("span", { className: "planr-title-block", children: [
66
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StudioBadge, { children: kind === "artifact" ? "Artifact" : kind === "diagram" ? "Diagram" : "Design" }),
67
- titleNode ?? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("strong", { title, children: title })
68
- ] }),
69
- subtitle && /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "studio-subtitle", children: subtitle })
149
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "studio-toolbar-center", children: viewPicker }),
150
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "studio-toolbar-trailing design-toolbar-trailing", children: [
151
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "studio-toolbar-status", children: status }),
152
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "studio-toolbar-actions", children: actions })
70
153
  ] })
71
- ] })
72
- ] }),
73
- viewPicker,
74
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "studio-toolbar-trailing design-toolbar-trailing", children: [
75
- status,
76
- actions
77
- ] })
78
- ] });
154
+ ]
155
+ }
156
+ );
79
157
  }
80
158
  function StudioMenu({
81
159
  label,
@@ -2,8 +2,8 @@
2
2
  "kind": "openplanr-runtime-asset-sources",
3
3
  "schemaVersion": "1.0.0",
4
4
  "asset": "studio.js",
5
- "bytes": 1136703,
6
- "sha256": "24745f5b2327275efa2cb904652c4451b16a6893d4284e375a3ce986d909f49e",
5
+ "bytes": 1142078,
6
+ "sha256": "b8688a3102c5028847fc9a1d4a257b096768de1db3b4bfd4656482d318013c71",
7
7
  "scopes": [
8
8
  {
9
9
  "id": "bundle",
@@ -143,8 +143,8 @@
143
143
  "packages/design/lib/design/ui/enhancements.mjs",
144
144
  "packages/design/lib/design/ui/handoff-center.mjs"
145
145
  ],
146
- "bytes": 151613,
147
- "sha256": "c40392e1328eb17f9d0a778d1f20e44118731d7c6a0a25f0aa731304a86994a0"
146
+ "bytes": 152776,
147
+ "sha256": "9e2ac3d6b99028c7335aacf548f9e04fdf709d15f889db3e35bbebc389631000"
148
148
  },
149
149
  {
150
150
  "path": "studio.js.sources/13-studio-shell.js",
@@ -238,8 +238,8 @@
238
238
  "packages/artifact/lib/artifact/ui/studio-shell-components.mjs",
239
239
  "packages/artifact/lib/artifact/ui/studio-shell-mount-impl.mjs"
240
240
  ],
241
- "bytes": 19068,
242
- "sha256": "a84049d6a41dd3f655e85a4a39e4874a4c7f6f2013ad9d8c192d22a7082bf407"
241
+ "bytes": 23280,
242
+ "sha256": "5306387b1f59d43e1cd0ed2c471b18b0b35d5cc8c573ffe5439ea9315494c01e"
243
243
  },
244
244
  {
245
245
  "path": "studio.js.sources/17-design-studio.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openplanr/protocol",
3
- "version": "0.10.3",
3
+ "version": "0.11.0",
4
4
  "type": "module",
5
5
  "description": "Canonical OpenPlanr schemas, registries, typed errors, and portable contract validation",
6
6
  "license": "MIT",
@@ -132,7 +132,7 @@
132
132
  "test": "node --test ../../tests/protocol/*.test.mjs"
133
133
  },
134
134
  "engines": {
135
- "node": ">=20"
135
+ "node": ">=22.13.0"
136
136
  },
137
137
  "repository": {
138
138
  "type": "git",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openplanr/protocol",
3
- "version": "0.10.3",
3
+ "version": "0.11.0",
4
4
  "type": "module",
5
5
  "description": "Canonical OpenPlanr schemas, registries, typed errors, and portable contract validation",
6
6
  "license": "MIT",
@@ -132,7 +132,7 @@
132
132
  "test": "node --test ../../tests/protocol/*.test.mjs"
133
133
  },
134
134
  "engines": {
135
- "node": ">=20"
135
+ "node": ">=22.13.0"
136
136
  },
137
137
  "repository": {
138
138
  "type": "git",
@@ -16,7 +16,7 @@ Ordinary implementation remains with `planr-ship`.
16
16
  Resolve [runner.mjs](scripts/runner.mjs) from this installed skill. Call it through
17
17
  Node as `node <installed-skill>/scripts/runner.mjs <action>`, with one JSON object
18
18
  on stdin. Alternatively, include `action` in that object and omit the command-line
19
- action; conflicting actions are rejected. `probe` discovers Node 20+, Git, installed
19
+ action; conflicting actions are rejected. `probe` discovers Node 22+, Git, installed
20
20
  CLIs and optional profiles; an OpenPlanr checkout or public CLI command is not
21
21
  needed. Reuse normal signed-in authentication. Preserve selection precedence:
22
22
  explicit engine/profile, saved choice, then a sole compatible native choice; ask
@@ -1,6 +1,6 @@
1
1
  # Delegation context capsule v1
2
2
 
3
- `context.mjs` is an internal, Node 20+ package resource. It gathers **work context** only. It does not select a profile, grant a writable path, launch an agent, or authorize publication. The orchestrator must show `previewContextCapsule` alongside the selected writable repository, native engine/model selection, configuration trust and known provider or native-managed routing before dispatch.
3
+ `context.mjs` is an internal, Node 22+ package resource. It gathers **work context** only. It does not select a profile, grant a writable path, launch an agent, or authorize publication. The orchestrator must show `previewContextCapsule` alongside the selected writable repository, native engine/model selection, configuration trust and known provider or native-managed routing before dispatch.
4
4
 
5
5
  ## API
6
6
 
@@ -58,7 +58,7 @@ async function inspectWorktreeDependencies(worktreePath) {
58
58
  }
59
59
 
60
60
  export async function probeDelegateHost({ repositoryRoot, env = process.env } = {}) {
61
- const nodeReady = Number(process.versions.node.split('.')[0]) >= 20;
61
+ const nodeReady = Number(process.versions.node.split('.')[0]) >= 22;
62
62
  const options = {
63
63
  env: { PATH: env.PATH, HOME: env.HOME, USER: env.USER, TMPDIR: env.TMPDIR },
64
64
  cwd: repositoryRoot,
@@ -128,7 +128,7 @@ export async function probeDelegateHost({ repositoryRoot, env = process.env } =
128
128
  }
129
129
  return {
130
130
  ready: nodeReady && gitReady,
131
- node: { ready: nodeReady, minimumMajor: 20 },
131
+ node: { ready: nodeReady, minimumMajor: 22 },
132
132
  git: { ready: gitReady, ...(gitDiagnostic ? { diagnostic: gitDiagnostic } : {}) },
133
133
  repository,
134
134
  engines,
@@ -167,7 +167,7 @@ export async function prepareDelegateRun({
167
167
  if (!host.ready || !host.repository?.ready)
168
168
  throw new DelegateRunError(
169
169
  'E_DELEGATE_PREREQUISITE',
170
- 'Node 20+, Git, and a repository with a commit are required before task collection.',
170
+ 'Node 22+, Git, and a repository with a commit are required before task collection.',
171
171
  null,
172
172
  host,
173
173
  );
@@ -2,7 +2,7 @@
2
2
 
3
3
  Run the linked design helper from the skill entrypoint relative to the skill's
4
4
  directory. It contains deterministic operations and all required assets. It needs
5
- Node 20 or later, with no global CLI, provider credentials or runtime downloads.
5
+ Node.js 22.13 or later, with no global CLI, provider credentials or runtime downloads.
6
6
  Use `--help` to inspect the installed command interface before writing documents
7
7
  or invoking operations; the installed contract is authoritative.
8
8
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  Run the linked design helper from the skill entrypoint relative to the skill's
4
4
  directory. It contains deterministic operations and all required assets. It needs
5
- Node 20 or later, with no global CLI, provider credentials or runtime downloads.
5
+ Node.js 22.13 or later, with no global CLI, provider credentials or runtime downloads.
6
6
  Use `--help` to inspect the installed command interface before writing documents
7
7
  or invoking operations; the installed contract is authoritative.
8
8
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  Run the linked design helper from the skill entrypoint relative to the skill's
4
4
  directory. It contains deterministic operations and all required assets. It needs
5
- Node 20 or later, with no global CLI, provider credentials or runtime downloads.
5
+ Node.js 22.13 or later, with no global CLI, provider credentials or runtime downloads.
6
6
  Use `--help` to inspect the installed command interface before writing documents
7
7
  or invoking operations; the installed contract is authoritative.
8
8
 
@@ -37,7 +37,10 @@ skill's job, then reporting what actually changed — never what was merely
37
37
  attempted.
38
38
 
39
39
  1. **Decide.** Run `openplanr upgrade status --json` and read `status`. If it is
40
- `aligned` or `unknown`, there is nothing to drive — report it and stop.
40
+ `aligned` or `unknown` with empty `nextSteps`, there is nothing to drive —
41
+ report it and stop. If it is `agents-behind`, or `aligned` with `nextSteps`,
42
+ the CLI is already current: run its `nextSteps` commands in order, as step 3
43
+ describes, without upgrading the CLI.
41
44
  Record the reported `installed` versions; that is the before state.
42
45
  2. **Own half, prescribe half.** If `status` is `upgrade-available` or
43
46
  `incompatible`, confirm with the user (this upgrades the npm CLI), then run
@@ -52,6 +52,10 @@ Shape (the fields this skill reads):
52
52
  - `upgrade-available` or `incompatible` → act. First **record the `installed`
53
53
  block as the before state** — the honest diff at the end depends on it. When
54
54
  only `nextSteps` is non-empty, skip to step 3.
55
+ - `agents-behind` → the CLI is current and a coding agent's OpenPlanr install
56
+ needs updating. Record the `installed` block, then skip to step 3.
57
+ - `aligned` with non-empty `nextSteps` → the versions match, but an install needs
58
+ the `openplanr doctor` commands listed. Skip to step 3.
55
59
 
56
60
  ## 2. Upgrade the CLI and obtain the next steps
57
61
 
@@ -90,6 +94,10 @@ this file.** Other shapes:
90
94
  `openplanr upgrade status --json` and use its `nextSteps`.
91
95
  - An `openplanr doctor` command: planning that agent's update failed, and `detail`
92
96
  says why. Relay it and run `openplanr doctor --json`.
97
+ - An `openplanr doctor --fix` command: a file in that agent's runtime package was
98
+ changed outside OpenPlanr, and `detail` names it. Run it, show the user the
99
+ repair preview, and rerun it with `--yes` only after they confirm. The changed
100
+ files are backed up before they are replaced.
93
101
 
94
102
  `pluginHalfCommands` repeats the commands for older readers; read `nextSteps`.
95
103
 
@@ -118,8 +118,8 @@ instead of repeating every path in chat.
118
118
  - **Checks:** frontmatter, ID and acceptance coverage checks actually performed.
119
119
  - **Issues:** unresolved inputs or material assumptions, with their impact and recovery step; omit when empty.
120
120
  - **Next:** the exact ready task selector and a copy-ready host-native
121
- invocation such as `$planr:ship T-NNN` (Codex/ChatGPT) or
122
- `/planr:ship T-NNN` (Claude Code).
121
+ invocation such as `/planr:ship T-NNN` (Claude Code), `$planr:ship T-NNN`
122
+ (Codex/ChatGPT) or the `planr-ship` rule (Cursor).
123
123
 
124
124
  Mention the planning layout or consulted lenses only when they explain a material
125
125
  choice. Different summary wording never requires another planning run.
@@ -1,4 +1,4 @@
1
- export declare const CLI_NODE_RANGE: '^20.19.0 || ^22.13.0 || >=23.5.0';
1
+ export declare const CLI_NODE_RANGE: '^22.13.0 || >=23.5.0';
2
2
  export declare const CLI_NODE_REMEDIATION: string;
3
3
  export declare function supportsCliNodeVersion(version: unknown): boolean;
4
4
  export declare function cliNodeVersionMessage(version: string): string;
@@ -1,7 +1,7 @@
1
1
  // @ts-check
2
2
  /** Installed CLI dependency support, checked before loading prompt/runtime modules. */
3
3
  /** @type {typeof import('./node-runtime.d.mts').CLI_NODE_RANGE} */
4
- export const CLI_NODE_RANGE = '^20.19.0 || ^22.13.0 || >=23.5.0';
4
+ export const CLI_NODE_RANGE = '^22.13.0 || >=23.5.0';
5
5
  /** @type {typeof import('./node-runtime.d.mts').CLI_NODE_REMEDIATION} */
6
6
  export const CLI_NODE_REMEDIATION =
7
7
  'Install a supported Node.js version, then rerun. OpenPlanr never changes Node.js for you.';
@@ -13,12 +13,7 @@ export function supportsCliNodeVersion(version) {
13
13
  return false;
14
14
  const [major, minor, patch] = version.replace(/^v/u, '').split('.').map(Number);
15
15
  if (![major, minor, patch].every(Number.isSafeInteger)) return false;
16
- return (
17
- (major === 20 && minor >= 19) ||
18
- (major === 22 && minor >= 13) ||
19
- (major === 23 && minor >= 5) ||
20
- major > 23
21
- );
16
+ return (major === 22 && minor >= 13) || (major === 23 && minor >= 5) || major > 23;
22
17
  }
23
18
 
24
19
  /** @type {typeof import('./node-runtime.d.mts').cliNodeVersionMessage} */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openplanr",
3
- "version": "2.2641.2",
3
+ "version": "3.0.0",
4
4
  "description": "Deterministic OpenPlanr utilities for planning storage, validation, rendering, setup, diagnostics, and GitHub/Linear synchronization",
5
5
  "type": "module",
6
6
  "main": "./dist/cli/index.js",
@@ -20,8 +20,7 @@
20
20
  },
21
21
  "bin": {
22
22
  "openplanr": "./bin/openplanr.js",
23
- "opr": "./bin/openplanr.js",
24
- "planr": "./bin/planr.js"
23
+ "opr": "./bin/openplanr.js"
25
24
  },
26
25
  "publishConfig": {
27
26
  "access": "public",
@@ -74,7 +73,7 @@
74
73
  "verify:release-artifact": "node scripts/verify-release-artifact.mjs"
75
74
  },
76
75
  "engines": {
77
- "node": "^20.19.0 || ^22.13.0 || >=23.5.0"
76
+ "node": "^22.13.0 || >=23.5.0"
78
77
  },
79
78
  "keywords": [
80
79
  "agile",
@@ -115,7 +114,7 @@
115
114
  "zod": "^4.3.6"
116
115
  },
117
116
  "optionalDependencies": {
118
- "planr-pipeline": "0.57.0"
117
+ "planr-pipeline": "0.58.0"
119
118
  },
120
119
  "devDependencies": {
121
120
  "@biomejs/biome": "^2.4.9",
package/bin/planr.js DELETED
@@ -1,7 +0,0 @@
1
- #!/usr/bin/env node
2
- import { CLI_COMMAND } from '../lib/names.mjs';
3
-
4
- process.stderr.write(
5
- `planr is now ${CLI_COMMAND} (short alias: opr). The planr command will be removed in the next release.\n`,
6
- );
7
- await import('./openplanr.js');