@starlein/paperclip-plugin-company-wizard 0.5.0 → 0.6.2
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/CHANGELOG.md +101 -0
- package/README.md +23 -11
- package/dist/manifest.js +8 -8
- package/dist/manifest.js.map +2 -2
- package/dist/ui/index.css +636 -589
- package/dist/ui/index.css.map +2 -2
- package/dist/ui/index.js +365 -60
- package/dist/ui/index.js.map +4 -4
- package/dist/worker.js +22007 -5105
- package/dist/worker.js.map +4 -4
- package/docs/PAPERCLIP-COMPATIBILITY.md +66 -0
- package/package.json +10 -10
- package/templates/ai-wizard/interview-system.md +2 -0
- package/templates/ai-wizard/single-shot-system.md +2 -0
- package/templates/bootstrap-instructions.md +3 -3
- package/templates/modules/accessibility/agents/engineer/skills/accessibility-audit.fallback.md +2 -2
- package/templates/modules/accessibility/agents/ui-designer/skills/accessibility-audit.fallback.md +2 -2
- package/templates/modules/accessibility/module.meta.json +1 -1
- package/templates/modules/accessibility/skills/accessibility-audit.bar.md +1 -1
- package/templates/modules/accessibility/skills/accessibility-audit.md +1 -1
- package/templates/modules/architecture-plan/agents/ceo/skills/architecture-plan.bar.md +2 -2
- package/templates/modules/architecture-plan/agents/ceo/skills/architecture-plan.fallback.md +2 -2
- package/templates/modules/architecture-plan/agents/engineer/skills/design-system.fallback.md +2 -2
- package/templates/modules/architecture-plan/agents/ui-designer/skills/architecture-plan.md +2 -2
- package/templates/modules/architecture-plan/agents/ui-designer/skills/design-system.md +3 -3
- package/templates/modules/architecture-plan/module.meta.json +2 -2
- package/templates/modules/architecture-plan/skills/architecture-plan.bar.md +1 -1
- package/templates/modules/architecture-plan/skills/architecture-plan.md +3 -3
- package/templates/modules/architecture-plan/skills/design-system.md +5 -5
- package/templates/modules/auto-assign/README.md +4 -4
- package/templates/modules/auto-assign/agents/ceo/heartbeat-section.md +1 -1
- package/templates/modules/auto-assign/agents/ceo/skills/auto-assign.fallback.md +6 -6
- package/templates/modules/auto-assign/agents/product-owner/heartbeat-section.md +1 -1
- package/templates/modules/auto-assign/module.meta.json +1 -1
- package/templates/modules/auto-assign/skills/auto-assign.md +3 -2
- package/templates/modules/backlog/agents/ceo/heartbeat-section.md +1 -1
- package/templates/modules/backlog/agents/ceo/skills/backlog-health.fallback.md +9 -9
- package/templates/modules/backlog/agents/product-owner/heartbeat-section.md +1 -1
- package/templates/modules/backlog/docs/backlog-process.md +36 -21
- package/templates/modules/backlog/docs/backlog-template.md +10 -9
- package/templates/modules/backlog/module.meta.json +2 -2
- package/templates/modules/backlog/skills/backlog-health.bar.md +3 -3
- package/templates/modules/backlog/skills/backlog-health.md +16 -15
- package/templates/modules/brand-identity/agents/ceo/skills/brand-identity.fallback.md +2 -2
- package/templates/modules/brand-identity/agents/cmo/skills/brand-identity.fallback.md +2 -2
- package/templates/modules/brand-identity/module.meta.json +1 -1
- package/templates/modules/brand-identity/skills/brand-identity.bar.md +1 -1
- package/templates/modules/brand-identity/skills/brand-identity.md +3 -3
- package/templates/modules/build-api/skills/api-design.bar.md +1 -1
- package/templates/modules/build-api/skills/api-design.md +1 -1
- package/templates/modules/ci-cd/agents/devops/skills/ci-cd.md +1 -1
- package/templates/modules/ci-cd/agents/engineer/skills/ci-cd.fallback.md +2 -2
- package/templates/modules/ci-cd/module.meta.json +1 -1
- package/templates/modules/ci-cd/skills/ci-cd.bar.md +1 -1
- package/templates/modules/ci-cd/skills/ci-cd.md +6 -4
- package/templates/modules/codebase-onboarding/agents/ceo/skills/codebase-audit.fallback.md +5 -5
- package/templates/modules/codebase-onboarding/module.meta.json +1 -1
- package/templates/modules/codebase-onboarding/skills/codebase-audit.bar.md +1 -1
- package/templates/modules/codebase-onboarding/skills/codebase-audit.md +2 -2
- package/templates/modules/competitive-intel/agents/ceo/skills/competitive-tracking.fallback.md +2 -2
- package/templates/modules/competitive-intel/agents/cmo/skills/competitive-tracking.fallback.md +2 -2
- package/templates/modules/competitive-intel/agents/customer-success/skills/competitive-tracking.md +2 -2
- package/templates/modules/competitive-intel/agents/product-owner/skills/competitive-tracking.fallback.md +2 -2
- package/templates/modules/competitive-intel/module.meta.json +1 -1
- package/templates/modules/competitive-intel/skills/competitive-tracking.bar.md +2 -2
- package/templates/modules/competitive-intel/skills/competitive-tracking.md +3 -3
- package/templates/modules/dependency-management/agents/engineer/skills/dependency-audit.fallback.md +2 -2
- package/templates/modules/dependency-management/agents/security-engineer/skills/dependency-audit.fallback.md +2 -2
- package/templates/modules/dependency-management/module.meta.json +2 -2
- package/templates/modules/dependency-management/skills/dependency-audit.md +2 -2
- package/templates/modules/game-design/agents/ceo/skills/game-design.fallback.md +1 -1
- package/templates/modules/game-design/agents/engineer/skills/game-design.fallback.md +1 -1
- package/templates/modules/game-design/agents/game-designer/skills/game-design.md +2 -2
- package/templates/modules/game-design/module.meta.json +1 -1
- package/templates/modules/game-design/skills/audio-design.fallback.md +2 -2
- package/templates/modules/game-design/skills/audio-design.md +3 -3
- package/templates/modules/game-design/skills/game-design.bar.md +1 -1
- package/templates/modules/game-design/skills/game-design.md +3 -3
- package/templates/modules/game-design/skills/level-design.fallback.md +2 -2
- package/templates/modules/game-design/skills/level-design.md +4 -4
- package/templates/modules/github-repo/agents/engineer/skills/git-workflow.md +15 -14
- package/templates/modules/github-repo/docs/git-workflow.md +7 -7
- package/templates/modules/github-repo/module.meta.json +1 -1
- package/templates/modules/lean-delivery/docs/lean-delivery.md +15 -0
- package/templates/modules/lean-delivery/module.meta.json +6 -0
- package/templates/modules/market-analysis/agents/ceo/skills/market-analysis.fallback.md +2 -2
- package/templates/modules/market-analysis/agents/cmo/skills/market-analysis.fallback.md +2 -2
- package/templates/modules/market-analysis/agents/product-owner/skills/market-analysis.fallback.md +2 -2
- package/templates/modules/market-analysis/agents/ux-researcher/skills/market-analysis.md +2 -2
- package/templates/modules/market-analysis/module.meta.json +1 -1
- package/templates/modules/market-analysis/skills/market-analysis.bar.md +1 -1
- package/templates/modules/market-analysis/skills/market-analysis.md +2 -2
- package/templates/modules/monitoring/agents/devops/skills/monitoring.md +1 -1
- package/templates/modules/monitoring/agents/engineer/skills/monitoring.fallback.md +2 -2
- package/templates/modules/monitoring/module.meta.json +1 -1
- package/templates/modules/monitoring/skills/monitoring.bar.md +1 -1
- package/templates/modules/monitoring/skills/monitoring.md +3 -3
- package/templates/modules/pr-review/README.md +10 -12
- package/templates/modules/pr-review/agents/code-reviewer/skills/code-review.md +16 -13
- package/templates/modules/pr-review/agents/devops/skills/infra-review.md +2 -2
- package/templates/modules/pr-review/agents/engineer/skills/pr-workflow.md +36 -26
- package/templates/modules/pr-review/agents/product-owner/skills/product-review.md +8 -8
- package/templates/modules/pr-review/agents/qa/skills/qa-review.md +10 -10
- package/templates/modules/pr-review/agents/security-engineer/skills/pr-security-review.md +5 -4
- package/templates/modules/pr-review/agents/ui-designer/skills/design-review.md +4 -4
- package/templates/modules/pr-review/agents/ux-researcher/skills/ux-review.md +3 -3
- package/templates/modules/pr-review/docs/pr-conventions.md +22 -26
- package/templates/modules/pr-review/module.meta.json +2 -2
- package/templates/modules/release-management/agents/ceo/skills/release-process.fallback.md +2 -2
- package/templates/modules/release-management/agents/engineer/skills/release-process.fallback.md +2 -2
- package/templates/modules/release-management/module.meta.json +3 -3
- package/templates/modules/release-management/skills/release-process.md +2 -2
- package/templates/modules/security-audit/agents/devops/skills/security-review.fallback.md +2 -2
- package/templates/modules/security-audit/agents/devops/skills/threat-model.fallback.md +2 -2
- package/templates/modules/security-audit/agents/engineer/skills/security-review.fallback.md +2 -2
- package/templates/modules/security-audit/agents/engineer/skills/threat-model.fallback.md +2 -2
- package/templates/modules/security-audit/module.meta.json +2 -2
- package/templates/modules/security-audit/skills/security-review.bar.md +1 -1
- package/templates/modules/security-audit/skills/security-review.md +1 -1
- package/templates/modules/security-audit/skills/threat-model.bar.md +1 -1
- package/templates/modules/security-audit/skills/threat-model.md +3 -3
- package/templates/modules/stall-detection/agents/ceo/heartbeat-section.md +1 -1
- package/templates/modules/stall-detection/agents/ceo/skills/stall-detection.md +19 -16
- package/templates/modules/tech-stack/agents/ceo/skills/tech-stack.fallback.md +2 -2
- package/templates/modules/tech-stack/module.meta.json +1 -1
- package/templates/modules/tech-stack/skills/tech-stack.bar.md +1 -1
- package/templates/modules/tech-stack/skills/tech-stack.md +2 -2
- package/templates/modules/triage/agents/ceo/skills/issue-triage.fallback.md +1 -1
- package/templates/modules/triage/agents/engineer/skills/issue-triage.fallback.md +1 -1
- package/templates/modules/triage/skills/issue-triage.md +1 -1
- package/templates/modules/user-testing/agents/ceo/skills/user-testing.fallback.md +2 -2
- package/templates/modules/user-testing/agents/product-owner/skills/user-testing.fallback.md +2 -2
- package/templates/modules/user-testing/agents/qa/skills/user-testing.md +2 -2
- package/templates/modules/user-testing/agents/ux-researcher/skills/user-testing.fallback.md +2 -2
- package/templates/modules/user-testing/module.meta.json +1 -1
- package/templates/modules/user-testing/skills/user-testing.md +2 -2
- package/templates/modules/vision-workshop/agents/ceo/skills/vision-workshop.md +2 -2
- package/templates/modules/vision-workshop/agents/ux-researcher/skills/vision-workshop.md +1 -1
- package/templates/modules/vision-workshop/module.meta.json +1 -1
- package/templates/modules/website-relaunch/agents/ui-designer/skills/site-audit.md +1 -1
- package/templates/modules/website-relaunch/module.meta.json +7 -7
- package/templates/modules/website-relaunch/skills/design-ingestion.md +1 -1
- package/templates/modules/website-relaunch/skills/site-audit.md +1 -1
- package/templates/presets/build-game/preset.meta.json +6 -6
- package/templates/presets/repo-maintenance/preset.meta.json +20 -21
- package/templates/roles/audio-designer/HEARTBEAT.md +1 -1
- package/templates/roles/ceo/AGENTS.md +2 -0
- package/templates/roles/ceo/HEARTBEAT.md +1 -1
- package/templates/roles/ceo/role.meta.json +1 -1
- package/templates/roles/cmo/HEARTBEAT.md +1 -1
- package/templates/roles/code-reviewer/AGENTS.md +3 -1
- package/templates/roles/code-reviewer/HEARTBEAT.md +1 -1
- package/templates/roles/cto/HEARTBEAT.md +1 -1
- package/templates/roles/customer-success/HEARTBEAT.md +1 -1
- package/templates/roles/devops/HEARTBEAT.md +1 -1
- package/templates/roles/engineer/AGENTS.md +3 -3
- package/templates/roles/engineer/HEARTBEAT.md +2 -2
- package/templates/roles/game-artist/HEARTBEAT.md +1 -1
- package/templates/roles/game-designer/HEARTBEAT.md +1 -1
- package/templates/roles/level-designer/HEARTBEAT.md +1 -1
- package/templates/roles/product-owner/AGENTS.md +1 -1
- package/templates/roles/product-owner/HEARTBEAT.md +2 -2
- package/templates/roles/qa/HEARTBEAT.md +4 -4
- package/templates/roles/security-engineer/AGENTS.md +2 -2
- package/templates/roles/security-engineer/HEARTBEAT.md +1 -1
- package/templates/roles/technical-writer/HEARTBEAT.md +1 -1
- package/templates/roles/ui-designer/HEARTBEAT.md +1 -1
- package/templates/roles/ux-researcher/HEARTBEAT.md +1 -1
package/dist/ui/index.js
CHANGED
|
@@ -387,17 +387,29 @@ var __iconNode27 = [
|
|
|
387
387
|
];
|
|
388
388
|
var Pencil = createLucideIcon("pencil", __iconNode27);
|
|
389
389
|
|
|
390
|
-
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/
|
|
390
|
+
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/play.js
|
|
391
391
|
var __iconNode28 = [
|
|
392
|
+
[
|
|
393
|
+
"path",
|
|
394
|
+
{
|
|
395
|
+
d: "M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",
|
|
396
|
+
key: "10ikf1"
|
|
397
|
+
}
|
|
398
|
+
]
|
|
399
|
+
];
|
|
400
|
+
var Play = createLucideIcon("play", __iconNode28);
|
|
401
|
+
|
|
402
|
+
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/refresh-cw.js
|
|
403
|
+
var __iconNode29 = [
|
|
392
404
|
["path", { d: "M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8", key: "v9h5vc" }],
|
|
393
405
|
["path", { d: "M21 3v5h-5", key: "1q7to0" }],
|
|
394
406
|
["path", { d: "M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16", key: "3uifl3" }],
|
|
395
407
|
["path", { d: "M8 16H3v5", key: "1cv678" }]
|
|
396
408
|
];
|
|
397
|
-
var RefreshCw = createLucideIcon("refresh-cw",
|
|
409
|
+
var RefreshCw = createLucideIcon("refresh-cw", __iconNode29);
|
|
398
410
|
|
|
399
411
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/rocket.js
|
|
400
|
-
var
|
|
412
|
+
var __iconNode30 = [
|
|
401
413
|
["path", { d: "M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5", key: "qeys4" }],
|
|
402
414
|
[
|
|
403
415
|
"path",
|
|
@@ -415,17 +427,17 @@ var __iconNode29 = [
|
|
|
415
427
|
],
|
|
416
428
|
["path", { d: "M9 12H4s.55-3.03 2-4c1.62-1.08 5 .05 5 .05", key: "92ym6u" }]
|
|
417
429
|
];
|
|
418
|
-
var Rocket = createLucideIcon("rocket",
|
|
430
|
+
var Rocket = createLucideIcon("rocket", __iconNode30);
|
|
419
431
|
|
|
420
432
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/rotate-ccw.js
|
|
421
|
-
var
|
|
433
|
+
var __iconNode31 = [
|
|
422
434
|
["path", { d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8", key: "1357e3" }],
|
|
423
435
|
["path", { d: "M3 3v5h5", key: "1xhq8a" }]
|
|
424
436
|
];
|
|
425
|
-
var RotateCcw = createLucideIcon("rotate-ccw",
|
|
437
|
+
var RotateCcw = createLucideIcon("rotate-ccw", __iconNode31);
|
|
426
438
|
|
|
427
439
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/send.js
|
|
428
|
-
var
|
|
440
|
+
var __iconNode32 = [
|
|
429
441
|
[
|
|
430
442
|
"path",
|
|
431
443
|
{
|
|
@@ -435,19 +447,19 @@ var __iconNode31 = [
|
|
|
435
447
|
],
|
|
436
448
|
["path", { d: "m21.854 2.147-10.94 10.939", key: "12cjpa" }]
|
|
437
449
|
];
|
|
438
|
-
var Send = createLucideIcon("send",
|
|
450
|
+
var Send = createLucideIcon("send", __iconNode32);
|
|
439
451
|
|
|
440
452
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/settings-2.js
|
|
441
|
-
var
|
|
453
|
+
var __iconNode33 = [
|
|
442
454
|
["path", { d: "M14 17H5", key: "gfn3mx" }],
|
|
443
455
|
["path", { d: "M19 7h-9", key: "6i9tg" }],
|
|
444
456
|
["circle", { cx: "17", cy: "17", r: "3", key: "18b49y" }],
|
|
445
457
|
["circle", { cx: "7", cy: "7", r: "3", key: "dfmy0x" }]
|
|
446
458
|
];
|
|
447
|
-
var Settings2 = createLucideIcon("settings-2",
|
|
459
|
+
var Settings2 = createLucideIcon("settings-2", __iconNode33);
|
|
448
460
|
|
|
449
461
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/settings.js
|
|
450
|
-
var
|
|
462
|
+
var __iconNode34 = [
|
|
451
463
|
[
|
|
452
464
|
"path",
|
|
453
465
|
{
|
|
@@ -457,10 +469,23 @@ var __iconNode33 = [
|
|
|
457
469
|
],
|
|
458
470
|
["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
|
|
459
471
|
];
|
|
460
|
-
var Settings = createLucideIcon("settings",
|
|
472
|
+
var Settings = createLucideIcon("settings", __iconNode34);
|
|
473
|
+
|
|
474
|
+
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/shield-check.js
|
|
475
|
+
var __iconNode35 = [
|
|
476
|
+
[
|
|
477
|
+
"path",
|
|
478
|
+
{
|
|
479
|
+
d: "M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",
|
|
480
|
+
key: "oel41y"
|
|
481
|
+
}
|
|
482
|
+
],
|
|
483
|
+
["path", { d: "m9 12 2 2 4-4", key: "dzmm74" }]
|
|
484
|
+
];
|
|
485
|
+
var ShieldCheck = createLucideIcon("shield-check", __iconNode35);
|
|
461
486
|
|
|
462
487
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/shield.js
|
|
463
|
-
var
|
|
488
|
+
var __iconNode36 = [
|
|
464
489
|
[
|
|
465
490
|
"path",
|
|
466
491
|
{
|
|
@@ -469,10 +494,10 @@ var __iconNode34 = [
|
|
|
469
494
|
}
|
|
470
495
|
]
|
|
471
496
|
];
|
|
472
|
-
var Shield = createLucideIcon("shield",
|
|
497
|
+
var Shield = createLucideIcon("shield", __iconNode36);
|
|
473
498
|
|
|
474
499
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/sparkles.js
|
|
475
|
-
var
|
|
500
|
+
var __iconNode37 = [
|
|
476
501
|
[
|
|
477
502
|
"path",
|
|
478
503
|
{
|
|
@@ -484,18 +509,18 @@ var __iconNode35 = [
|
|
|
484
509
|
["path", { d: "M22 4h-4", key: "gwowj6" }],
|
|
485
510
|
["circle", { cx: "4", cy: "20", r: "2", key: "6kqj1y" }]
|
|
486
511
|
];
|
|
487
|
-
var Sparkles = createLucideIcon("sparkles",
|
|
512
|
+
var Sparkles = createLucideIcon("sparkles", __iconNode37);
|
|
488
513
|
|
|
489
514
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/target.js
|
|
490
|
-
var
|
|
515
|
+
var __iconNode38 = [
|
|
491
516
|
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
|
|
492
517
|
["circle", { cx: "12", cy: "12", r: "6", key: "1vlfrh" }],
|
|
493
518
|
["circle", { cx: "12", cy: "12", r: "2", key: "1c9p78" }]
|
|
494
519
|
];
|
|
495
|
-
var Target = createLucideIcon("target",
|
|
520
|
+
var Target = createLucideIcon("target", __iconNode38);
|
|
496
521
|
|
|
497
522
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/triangle-alert.js
|
|
498
|
-
var
|
|
523
|
+
var __iconNode39 = [
|
|
499
524
|
[
|
|
500
525
|
"path",
|
|
501
526
|
{
|
|
@@ -506,51 +531,51 @@ var __iconNode37 = [
|
|
|
506
531
|
["path", { d: "M12 9v4", key: "juzpu7" }],
|
|
507
532
|
["path", { d: "M12 17h.01", key: "p32p05" }]
|
|
508
533
|
];
|
|
509
|
-
var TriangleAlert = createLucideIcon("triangle-alert",
|
|
534
|
+
var TriangleAlert = createLucideIcon("triangle-alert", __iconNode39);
|
|
510
535
|
|
|
511
536
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/user-minus.js
|
|
512
|
-
var
|
|
537
|
+
var __iconNode40 = [
|
|
513
538
|
["path", { d: "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2", key: "1yyitq" }],
|
|
514
539
|
["circle", { cx: "9", cy: "7", r: "4", key: "nufk8" }],
|
|
515
540
|
["line", { x1: "22", x2: "16", y1: "11", y2: "11", key: "1shjgl" }]
|
|
516
541
|
];
|
|
517
|
-
var UserMinus = createLucideIcon("user-minus",
|
|
542
|
+
var UserMinus = createLucideIcon("user-minus", __iconNode40);
|
|
518
543
|
|
|
519
544
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/user-plus.js
|
|
520
|
-
var
|
|
545
|
+
var __iconNode41 = [
|
|
521
546
|
["path", { d: "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2", key: "1yyitq" }],
|
|
522
547
|
["circle", { cx: "9", cy: "7", r: "4", key: "nufk8" }],
|
|
523
548
|
["line", { x1: "19", x2: "19", y1: "8", y2: "14", key: "1bvyxn" }],
|
|
524
549
|
["line", { x1: "22", x2: "16", y1: "11", y2: "11", key: "1shjgl" }]
|
|
525
550
|
];
|
|
526
|
-
var UserPlus = createLucideIcon("user-plus",
|
|
551
|
+
var UserPlus = createLucideIcon("user-plus", __iconNode41);
|
|
527
552
|
|
|
528
553
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/user.js
|
|
529
|
-
var
|
|
554
|
+
var __iconNode42 = [
|
|
530
555
|
["path", { d: "M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2", key: "975kel" }],
|
|
531
556
|
["circle", { cx: "12", cy: "7", r: "4", key: "17ys0d" }]
|
|
532
557
|
];
|
|
533
|
-
var User = createLucideIcon("user",
|
|
558
|
+
var User = createLucideIcon("user", __iconNode42);
|
|
534
559
|
|
|
535
560
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/users.js
|
|
536
|
-
var
|
|
561
|
+
var __iconNode43 = [
|
|
537
562
|
["path", { d: "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2", key: "1yyitq" }],
|
|
538
563
|
["path", { d: "M16 3.128a4 4 0 0 1 0 7.744", key: "16gr8j" }],
|
|
539
564
|
["path", { d: "M22 21v-2a4 4 0 0 0-3-3.87", key: "kshegd" }],
|
|
540
565
|
["circle", { cx: "9", cy: "7", r: "4", key: "nufk8" }]
|
|
541
566
|
];
|
|
542
|
-
var Users = createLucideIcon("users",
|
|
567
|
+
var Users = createLucideIcon("users", __iconNode43);
|
|
543
568
|
|
|
544
569
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/workflow.js
|
|
545
|
-
var
|
|
570
|
+
var __iconNode44 = [
|
|
546
571
|
["rect", { width: "8", height: "8", x: "3", y: "3", rx: "2", key: "by2w9f" }],
|
|
547
572
|
["path", { d: "M7 11v4a2 2 0 0 0 2 2h4", key: "xkn7yn" }],
|
|
548
573
|
["rect", { width: "8", height: "8", x: "13", y: "13", rx: "2", key: "1cgmvn" }]
|
|
549
574
|
];
|
|
550
|
-
var Workflow = createLucideIcon("workflow",
|
|
575
|
+
var Workflow = createLucideIcon("workflow", __iconNode44);
|
|
551
576
|
|
|
552
577
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/wrench.js
|
|
553
|
-
var
|
|
578
|
+
var __iconNode45 = [
|
|
554
579
|
[
|
|
555
580
|
"path",
|
|
556
581
|
{
|
|
@@ -559,17 +584,17 @@ var __iconNode43 = [
|
|
|
559
584
|
}
|
|
560
585
|
]
|
|
561
586
|
];
|
|
562
|
-
var Wrench = createLucideIcon("wrench",
|
|
587
|
+
var Wrench = createLucideIcon("wrench", __iconNode45);
|
|
563
588
|
|
|
564
589
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/x.js
|
|
565
|
-
var
|
|
590
|
+
var __iconNode46 = [
|
|
566
591
|
["path", { d: "M18 6 6 18", key: "1bl5f8" }],
|
|
567
592
|
["path", { d: "m6 6 12 12", key: "d8bk6v" }]
|
|
568
593
|
];
|
|
569
|
-
var X = createLucideIcon("x",
|
|
594
|
+
var X = createLucideIcon("x", __iconNode46);
|
|
570
595
|
|
|
571
596
|
// node_modules/.pnpm/lucide-react@0.574.0_react@19.2.4/node_modules/lucide-react/dist/esm/icons/zap.js
|
|
572
|
-
var
|
|
597
|
+
var __iconNode47 = [
|
|
573
598
|
[
|
|
574
599
|
"path",
|
|
575
600
|
{
|
|
@@ -578,10 +603,10 @@ var __iconNode45 = [
|
|
|
578
603
|
}
|
|
579
604
|
]
|
|
580
605
|
];
|
|
581
|
-
var Zap = createLucideIcon("zap",
|
|
606
|
+
var Zap = createLucideIcon("zap", __iconNode47);
|
|
582
607
|
|
|
583
608
|
// src/ui/components/WizardShell.tsx
|
|
584
|
-
import { useEffect as
|
|
609
|
+
import { useEffect as useEffect10, useRef as useRef9 } from "react";
|
|
585
610
|
|
|
586
611
|
// src/ui/context/WizardContext.tsx
|
|
587
612
|
import { createContext, useCallback, useContext, useState } from "react";
|
|
@@ -4381,11 +4406,29 @@ var ADAPTER_TYPES = [
|
|
|
4381
4406
|
{ value: "opencode_local", label: "OpenCode", desc: "Local OpenCode agent" },
|
|
4382
4407
|
{ value: "cursor", label: "Cursor", desc: "Cursor IDE agent" },
|
|
4383
4408
|
{ value: "openclaw_gateway", label: "OpenClaw", desc: "OpenClaw gateway" },
|
|
4384
|
-
{ value: "hermes_local", label: "Hermes", desc: "Local Hermes agent" }
|
|
4409
|
+
{ value: "hermes_local", label: "Hermes", desc: "Local Hermes agent" },
|
|
4410
|
+
{ value: "gemini_local", label: "Gemini", desc: "Local Gemini agent" },
|
|
4411
|
+
{ value: "grok_local", label: "Grok", desc: "Local Grok agent" },
|
|
4412
|
+
{ value: "kimi_local", label: "Kimi", desc: "Local Kimi agent" },
|
|
4413
|
+
{ value: "pi_local", label: "Pi", desc: "Local Pi agent" }
|
|
4385
4414
|
];
|
|
4386
4415
|
var MODEL_SUGGESTIONS = {
|
|
4387
|
-
|
|
4388
|
-
|
|
4416
|
+
// `gpt-5.6-sol` is Codex's own default for the 5.6 family. The bare `gpt-5.6`
|
|
4417
|
+
// alias is deliberately omitted: it has no published model metadata, so Codex
|
|
4418
|
+
// warns and falls back to generic context limits (Paperclip rewrites it for
|
|
4419
|
+
// legacy agents, but new companies should not be provisioned onto it).
|
|
4420
|
+
// Mirrors the ids Paperclip's codex_local adapter publishes; `gpt-6-astra`
|
|
4421
|
+
// additionally accepts the extended `max`/`ultra` reasoning efforts.
|
|
4422
|
+
codex_local: ["gpt-5.6-sol", "gpt-6-astra", "gpt-5.6-terra", "gpt-5.6-luna", "gpt-5.4"],
|
|
4423
|
+
claude_local: [
|
|
4424
|
+
"claude-opus-4-8",
|
|
4425
|
+
"claude-opus-5",
|
|
4426
|
+
"claude-sonnet-5",
|
|
4427
|
+
"claude-fable-5-1",
|
|
4428
|
+
"claude-fable-5",
|
|
4429
|
+
"claude-mythos-5",
|
|
4430
|
+
"claude-sonnet-4-6"
|
|
4431
|
+
]
|
|
4389
4432
|
};
|
|
4390
4433
|
function modelSuggestionsFor(adapterType) {
|
|
4391
4434
|
return MODEL_SUGGESTIONS[adapterType] ?? [];
|
|
@@ -4494,7 +4537,7 @@ function StepName() {
|
|
|
4494
4537
|
/* @__PURE__ */ jsxs2("p", { className: "text-xs text-muted-foreground", children: [
|
|
4495
4538
|
"Leave empty for the adapter default (",
|
|
4496
4539
|
modelSuggestionsFor(state.ceoAdapter.type)[0] || "adapter default",
|
|
4497
|
-
"). Codex: gpt-5.6
|
|
4540
|
+
"). Codex: gpt-5.6-sol/terra/luna, gpt-6-astra. Claude: opus-4-8, opus-5, sonnet-5, fable-5.1, mythos-5."
|
|
4498
4541
|
] })
|
|
4499
4542
|
] })
|
|
4500
4543
|
] })
|
|
@@ -5771,6 +5814,7 @@ function ConfigReview() {
|
|
|
5771
5814
|
setPreviewError(null);
|
|
5772
5815
|
try {
|
|
5773
5816
|
const result = await previewFilesAction({
|
|
5817
|
+
existingCompanyId: state.existingCompanyId || void 0,
|
|
5774
5818
|
companyName: state.companyName || "Preview",
|
|
5775
5819
|
presetName: state.presetName,
|
|
5776
5820
|
selectedModules: state.selectedModules,
|
|
@@ -5790,6 +5834,7 @@ function ConfigReview() {
|
|
|
5790
5834
|
setLoadingFiles(false);
|
|
5791
5835
|
}
|
|
5792
5836
|
}, [
|
|
5837
|
+
state.existingCompanyId,
|
|
5793
5838
|
state.companyName,
|
|
5794
5839
|
state.presetName,
|
|
5795
5840
|
state.selectedModules,
|
|
@@ -6279,6 +6324,63 @@ function StepSummary() {
|
|
|
6279
6324
|
import { useState as useState8, useRef as useRef4, useEffect as useEffect5 } from "react";
|
|
6280
6325
|
import { usePluginAction as usePluginAction4 } from "@paperclipai/plugin-sdk/ui";
|
|
6281
6326
|
|
|
6327
|
+
// src/logic/project-workspace-policy.js
|
|
6328
|
+
var isRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
6329
|
+
function normalizeExecutionWorkspacePolicy(value) {
|
|
6330
|
+
if (!isRecord(value)) return void 0;
|
|
6331
|
+
const policy = {};
|
|
6332
|
+
for (const key of ["enabled", "allowIssueOverride"]) {
|
|
6333
|
+
if (typeof value[key] === "boolean") policy[key] = value[key];
|
|
6334
|
+
}
|
|
6335
|
+
for (const [key, allowed] of [
|
|
6336
|
+
[
|
|
6337
|
+
"defaultMode",
|
|
6338
|
+
["shared_workspace", "isolated_workspace", "operator_branch", "adapter_default"]
|
|
6339
|
+
],
|
|
6340
|
+
["sharedWorkspaceConcurrency", ["auto", "serialize", "allow"]]
|
|
6341
|
+
]) {
|
|
6342
|
+
const candidate = typeof value[key] === "string" ? value[key].trim() : value[key];
|
|
6343
|
+
if (allowed.includes(candidate)) policy[key] = candidate;
|
|
6344
|
+
}
|
|
6345
|
+
for (const key of ["defaultProjectWorkspaceId", "environmentId"]) {
|
|
6346
|
+
const candidate = typeof value[key] === "string" ? value[key].trim() : value[key];
|
|
6347
|
+
if (candidate === null || typeof candidate === "string" && /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(candidate)) {
|
|
6348
|
+
policy[key] = candidate;
|
|
6349
|
+
}
|
|
6350
|
+
}
|
|
6351
|
+
if (value.workspaceStrategy === null) policy.workspaceStrategy = null;
|
|
6352
|
+
else if (isRecord(value.workspaceStrategy)) {
|
|
6353
|
+
const source = value.workspaceStrategy;
|
|
6354
|
+
const strategy = {};
|
|
6355
|
+
if (["project_primary", "git_worktree", "adapter_managed", "cloud_sandbox"].includes(source.type)) {
|
|
6356
|
+
strategy.type = source.type;
|
|
6357
|
+
}
|
|
6358
|
+
for (const key of [
|
|
6359
|
+
"baseRef",
|
|
6360
|
+
"branchTemplate",
|
|
6361
|
+
"worktreeParentDir",
|
|
6362
|
+
"provisionCommand",
|
|
6363
|
+
"runtimeProvisionCommand",
|
|
6364
|
+
"teardownCommand"
|
|
6365
|
+
]) {
|
|
6366
|
+
if (source[key] === null || typeof source[key] === "string") strategy[key] = source[key];
|
|
6367
|
+
}
|
|
6368
|
+
policy.workspaceStrategy = strategy;
|
|
6369
|
+
}
|
|
6370
|
+
for (const key of [
|
|
6371
|
+
"workspaceRuntime",
|
|
6372
|
+
"branchPolicy",
|
|
6373
|
+
"pullRequestPolicy",
|
|
6374
|
+
"runtimePolicy",
|
|
6375
|
+
"cleanupPolicy",
|
|
6376
|
+
"authorizationPolicy"
|
|
6377
|
+
]) {
|
|
6378
|
+
if (value[key] === null) policy[key] = null;
|
|
6379
|
+
else if (isRecord(value[key])) policy[key] = structuredClone(value[key]);
|
|
6380
|
+
}
|
|
6381
|
+
return Object.keys(policy).length ? policy : void 0;
|
|
6382
|
+
}
|
|
6383
|
+
|
|
6282
6384
|
// raw:/home/runner/work/paperclip-plugin-company-wizard/paperclip-plugin-company-wizard/src/ui/prompts/interview-system.md
|
|
6283
6385
|
var interview_system_default = 'You are the Company Wizard \u2014 an expert at assembling AI agent teams. You\'re enthusiastic but concise. Company Wizard bootstraps AI-agent company workspaces from composable templates.\n\nYou are conducting a guided interview to understand what company to set up.\n\n{{CATALOG}}\n\n## How Roles Work\n\n- **Base roles** (marked "always included") are auto-added. You do NOT list them in the JSON.\n- **All other roles** (listed under "Available Extra Roles") are OPTIONAL and must be EXPLICITLY listed in your JSON `roles` array if you want them.\n- **Critically: `engineer` is NOT a base role.** Most software projects need an engineer. If the project involves writing code, building software, or maintaining a repository, you MUST include `engineer` in your `roles` array. The preset does NOT auto-add roles \u2014 you must list every non-base role the company needs.\n- When in doubt, include the engineer. A company that builds software without an engineer agent will have no one to write code.\n\n## Interview Rules\n\n- Ask exactly ONE question per turn. Keep it short and energetic (1-2 sentences). Use a conversational tone.\n- Do NOT output JSON during questions \u2014 just ask the question as plain text.\n- Tailor each question based on previous answers. Show you understood what they said.\n- After 3 questions, summarize what you understood in a brief, enthusiastic paragraph. End with: "Ready to generate your configuration?"\n- When the user confirms, output a human-readable recommendation with reasoning, then the JSON config.\n\n## What to Ask About\n\nAcross your 3 questions, try to cover as many of these as the user\'s initial description left unclear:\n\n1. **What they\'re building** \u2014 Product type, target users, domain (fintech, SaaS, game, etc.)\n2. **Current stage** \u2014 Greenfield, existing codebase, research phase, relaunch?\n3. **Quality vs speed** \u2014 Ship fast, iterate? Or production-grade, high quality from the start?\n4. **Team needs** \u2014 Do they need code review, security, design, marketing, docs, DevOps?\n5. **Special requirements** \u2014 Compliance, accessibility, specific tech stack, CI/CD, game engine?\n6. **Repository** \u2014 Should Paperclip create a new Git repository/workspace, or should the agents use an existing external repo such as GitHub/GitLab? If external, ask for URL and branch/ref; never ask for tokens.\n\nDon\'t ask about things already clear from the initial description. Skip to what\'s missing.\n\n## Information Preservation\n\nThe user\'s interview answers are the primary source of context for the company. When generating the configuration:\n\n- **`companyDescription`**: Write a comprehensive 2-4 paragraph description that captures EVERYTHING learned during the interview \u2014 what the company does, what it\'s building, who it\'s for, key technical decisions, constraints, priorities, and any special context. This is the company\'s permanent record. Be thorough. Do NOT summarize into a single vague sentence.\n- **`goals`**: Array of goals. The first goal is the main user-specific company goal \u2014 its description is the most important field. Keep it outcome-first and product-first: the title and opening sentence must state the primary deliverable or operating outcome, not a supporting constraint. Write a THOROUGH, DETAILED description that includes EVERYTHING the user shared: full requirements, technical specs, acceptance criteria, constraints, edge cases, API contracts, user stories, design decisions, performance targets. Put compliance/security/accessibility/performance constraints in a clearly labelled "Constraints / quality bars" section unless the user explicitly says that constraint is the primary project. If the user\'s wording mixes a main outcome with secondary facts, determine which thing the agents should build/operate first and write that as the top-level goal; put side facts into acceptance criteria, risks, or sub-goals only when they are independent workstreams. Preset/module template goals are added by the wizard after your JSON, so do NOT replace the user\'s objective with generic preset goals like "Build a REST API" or "Set up CI/CD" unless the user explicitly asked only for that.\n- **`projects`**: Array of projects. Each has a `name`, `description`, `goals` array (goal titles it\'s linked to), and repository workspace metadata. If the user chose an external repo, use `workspace.sourceType: "git_repo"` with `repoUrl`, plus `repoRef`/`defaultRef` exactly when the user or repository context provides one; do not force a branch name or remote prefix. If no external repo was provided, use a fresh local Git repository with `workspace.sourceType: "local_path"`, `workspace.defaultRef: "main"` unless the user requested another initial branch, `workspace.setupCommand: "git init -b <defaultRef>"`, and `workspace.isPrimary: true`. Do not include `executionWorkspacePolicy`; the assembler applies isolated worktrees only when Paperclip\'s experimental isolated-workspaces setting is enabled and a usable project base ref exists.\n- **`issues`**: Array of 6-12 CONCRETE, domain-specific initial work items taken straight from what you learned in the interview \u2014 the real features, components, and integrations the user actually described, each with a `title`, a `description` with acceptance criteria, a `priority` (`critical`/`high`/`medium`/`low`), and `assignTo` set to a role on the team. These seed the backlog so the project starts in its actual domain. Issue titles should lead with the core product capability; secondary constraints belong in acceptance criteria or risk notes unless the issue is specifically about that constraint. Do NOT put generic scaffolding here (vision docs, linters, CI, branch protection) \u2014 the wizard adds those automatically.\n\n## RECOMMENDATION Format (when generating config)\n\n- One paragraph explaining your reasoning: why this preset, why these modules, why these roles.\n- A bullet list of the key choices.\n\nThen output the JSON (no markdown fences):\n{{CONFIG_FORMAT}}\n\n## Rules\n\n- `modules` should list ALL modules to activate (including preset ones).\n- `roles` should list ALL non-base roles the company needs. This includes roles that come with the preset. The system does not auto-add preset roles \u2014 you must list them explicitly.\n- If the project involves building software, `engineer` MUST be in `roles`.\n- The primary project MUST state whether it uses a fresh local Git repository or an external Git repository. Do not put credentials or tokens in repository fields.\n- Be pragmatic \u2014 don\'t over-engineer. Match the config to actual needs.\n';
|
|
6284
6386
|
|
|
@@ -6396,20 +6498,6 @@ function normalizeWorkspaceConfig(value) {
|
|
|
6396
6498
|
if (isPlainObject(value.runtimeConfig)) workspace.runtimeConfig = value.runtimeConfig;
|
|
6397
6499
|
return Object.keys(workspace).length > 0 ? workspace : void 0;
|
|
6398
6500
|
}
|
|
6399
|
-
function normalizeExecutionWorkspacePolicy(value) {
|
|
6400
|
-
if (!isPlainObject(value)) return void 0;
|
|
6401
|
-
const policy = {};
|
|
6402
|
-
copyStringField(value, policy, "defaultMode");
|
|
6403
|
-
copyStringField(value, policy, "defaultProjectWorkspaceId");
|
|
6404
|
-
copyStringField(value, policy, "environmentId");
|
|
6405
|
-
if (typeof value.allowIssueOverride === "boolean") {
|
|
6406
|
-
policy.allowIssueOverride = value.allowIssueOverride;
|
|
6407
|
-
}
|
|
6408
|
-
if (isPlainObject(value.workspaceStrategy)) {
|
|
6409
|
-
policy.workspaceStrategy = { ...value.workspaceStrategy };
|
|
6410
|
-
}
|
|
6411
|
-
return Object.keys(policy).length > 0 ? policy : void 0;
|
|
6412
|
-
}
|
|
6413
6501
|
function PhaseIndicator({
|
|
6414
6502
|
phase,
|
|
6415
6503
|
questionCount
|
|
@@ -7346,6 +7434,25 @@ function StepPreview() {
|
|
|
7346
7434
|
"."
|
|
7347
7435
|
] })
|
|
7348
7436
|
] }),
|
|
7437
|
+
diff.projectPolicies?.length > 0 && /* @__PURE__ */ jsxs12("div", { className: "rounded-lg border p-4 space-y-3", children: [
|
|
7438
|
+
/* @__PURE__ */ jsx18("h3", { className: "text-sm font-semibold", children: "Project workspace policies" }),
|
|
7439
|
+
/* @__PURE__ */ jsxs12("p", { className: "text-sm text-muted-foreground", children: [
|
|
7440
|
+
"Existing workspace paths and project identities are preserved.",
|
|
7441
|
+
!diff.workspacePolicyEnforced && " Policies are not enforced until the instance setting enableIsolatedWorkspaces is enabled."
|
|
7442
|
+
] }),
|
|
7443
|
+
diff.projectPolicies.map((project) => /* @__PURE__ */ jsxs12("details", { className: "text-sm", children: [
|
|
7444
|
+
/* @__PURE__ */ jsxs12("summary", { children: [
|
|
7445
|
+
project.name,
|
|
7446
|
+
": shared concurrency",
|
|
7447
|
+
" ",
|
|
7448
|
+
project.before?.sharedWorkspaceConcurrency ?? "unset",
|
|
7449
|
+
" \u2192",
|
|
7450
|
+
" ",
|
|
7451
|
+
project.after?.sharedWorkspaceConcurrency
|
|
7452
|
+
] }),
|
|
7453
|
+
/* @__PURE__ */ jsx18("pre", { className: "overflow-auto whitespace-pre-wrap text-xs mt-2", children: JSON.stringify({ before: project.before, after: project.after }, null, 2) })
|
|
7454
|
+
] }, project.id))
|
|
7455
|
+
] }),
|
|
7349
7456
|
/* @__PURE__ */ jsxs12("div", { className: "rounded-lg border p-4 space-y-3", children: [
|
|
7350
7457
|
/* @__PURE__ */ jsxs12("h3", { className: "text-sm font-semibold", children: [
|
|
7351
7458
|
"Agents (",
|
|
@@ -7558,7 +7665,186 @@ function StepExistingCompany() {
|
|
|
7558
7665
|
}
|
|
7559
7666
|
|
|
7560
7667
|
// src/ui/components/steps/StepDone.tsx
|
|
7668
|
+
import { usePluginAction as usePluginAction8 } from "@paperclipai/plugin-sdk/ui";
|
|
7669
|
+
import { useCallback as useCallback7, useEffect as useEffect9, useRef as useRef8, useState as useState11 } from "react";
|
|
7561
7670
|
import { jsx as jsx20, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
7671
|
+
function PendingHires({
|
|
7672
|
+
companyId,
|
|
7673
|
+
approvalIds
|
|
7674
|
+
}) {
|
|
7675
|
+
const listPendingHires = usePluginAction8("list-pending-hires");
|
|
7676
|
+
const approvePendingHires = usePluginAction8("approve-pending-hires");
|
|
7677
|
+
const [hires, setHires] = useState11(null);
|
|
7678
|
+
const [selectedIds, setSelectedIds] = useState11([]);
|
|
7679
|
+
const [loadError, setLoadError] = useState11(null);
|
|
7680
|
+
const [actionError, setActionError] = useState11(null);
|
|
7681
|
+
const [message, setMessage] = useState11(null);
|
|
7682
|
+
const [loading, setLoading] = useState11(true);
|
|
7683
|
+
const [approving, setApproving] = useState11(false);
|
|
7684
|
+
const mounted = useRef8(false);
|
|
7685
|
+
const loadSequence = useRef8(0);
|
|
7686
|
+
const listAction = useRef8(listPendingHires);
|
|
7687
|
+
listAction.current = listPendingHires;
|
|
7688
|
+
const scopeKey = JSON.stringify(approvalIds);
|
|
7689
|
+
const load = useCallback7(async () => {
|
|
7690
|
+
const sequence = ++loadSequence.current;
|
|
7691
|
+
setLoading(true);
|
|
7692
|
+
setLoadError(null);
|
|
7693
|
+
try {
|
|
7694
|
+
const res = await listAction.current({
|
|
7695
|
+
companyId,
|
|
7696
|
+
approvalIds: JSON.parse(scopeKey)
|
|
7697
|
+
});
|
|
7698
|
+
if (!mounted.current || sequence !== loadSequence.current) return;
|
|
7699
|
+
if (res?.error) throw new Error(String(res.error));
|
|
7700
|
+
const approvals = Array.isArray(res?.approvals) ? res.approvals : [];
|
|
7701
|
+
setHires(approvals);
|
|
7702
|
+
setSelectedIds(
|
|
7703
|
+
(previous) => previous.filter((id) => approvals.some((hire) => hire.id === id))
|
|
7704
|
+
);
|
|
7705
|
+
} catch (err) {
|
|
7706
|
+
if (mounted.current && sequence === loadSequence.current) {
|
|
7707
|
+
setLoadError(err instanceof Error ? err.message : "Could not load pending hires");
|
|
7708
|
+
}
|
|
7709
|
+
} finally {
|
|
7710
|
+
if (mounted.current && sequence === loadSequence.current) setLoading(false);
|
|
7711
|
+
}
|
|
7712
|
+
}, [companyId, scopeKey]);
|
|
7713
|
+
useEffect9(() => {
|
|
7714
|
+
mounted.current = true;
|
|
7715
|
+
void load();
|
|
7716
|
+
return () => {
|
|
7717
|
+
mounted.current = false;
|
|
7718
|
+
++loadSequence.current;
|
|
7719
|
+
};
|
|
7720
|
+
}, [load]);
|
|
7721
|
+
const approveSelected = async () => {
|
|
7722
|
+
const approvalIds2 = selectedIds.filter((id) => hires?.some((hire) => hire.id === id));
|
|
7723
|
+
if (approving || loading || approvalIds2.length === 0) return;
|
|
7724
|
+
setApproving(true);
|
|
7725
|
+
setActionError(null);
|
|
7726
|
+
setMessage(null);
|
|
7727
|
+
try {
|
|
7728
|
+
const res = await approvePendingHires({ companyId, approvalIds: approvalIds2 });
|
|
7729
|
+
if (!mounted.current) return;
|
|
7730
|
+
if (res?.error) throw new Error(String(res.error));
|
|
7731
|
+
if (Array.isArray(res?.failed) && res.failed.length > 0) {
|
|
7732
|
+
setActionError(
|
|
7733
|
+
`${res.failed.length} hire(s) could not be approved: ${res.failed[0]?.error}`
|
|
7734
|
+
);
|
|
7735
|
+
}
|
|
7736
|
+
if (Array.isArray(res?.approved) && res.approved.length > 0) {
|
|
7737
|
+
setMessage(
|
|
7738
|
+
`${res.approved.length} hire(s) approved. Start bootstrap when the team is ready.`
|
|
7739
|
+
);
|
|
7740
|
+
}
|
|
7741
|
+
await load();
|
|
7742
|
+
} catch (err) {
|
|
7743
|
+
if (mounted.current)
|
|
7744
|
+
setActionError(err instanceof Error ? err.message : "Could not approve hires");
|
|
7745
|
+
} finally {
|
|
7746
|
+
if (mounted.current) setApproving(false);
|
|
7747
|
+
}
|
|
7748
|
+
};
|
|
7749
|
+
if (!loading && !loadError && !actionError && !message && hires?.length === 0) return null;
|
|
7750
|
+
return /* @__PURE__ */ jsx20(Card, { className: "border-amber-500/40", children: /* @__PURE__ */ jsxs14(CardContent, { className: "pt-6 space-y-3", children: [
|
|
7751
|
+
/* @__PURE__ */ jsxs14("div", { className: "flex items-start gap-2", children: [
|
|
7752
|
+
/* @__PURE__ */ jsx20(ShieldCheck, { className: "h-4 w-4 text-amber-600 shrink-0 mt-0.5" }),
|
|
7753
|
+
/* @__PURE__ */ jsxs14("div", { className: "space-y-1", children: [
|
|
7754
|
+
/* @__PURE__ */ jsx20("p", { className: "text-sm font-medium", children: hires && hires.length > 0 ? `${hires.length} hire${hires.length === 1 ? "" : "s"} awaiting board approval` : "Pending hires" }),
|
|
7755
|
+
/* @__PURE__ */ jsx20("p", { className: "text-xs text-muted-foreground", children: "These hire requests were created by this wizard run. Review and select the hires to approve. Pending agents cannot run; approval does not start bootstrap automatically." })
|
|
7756
|
+
] })
|
|
7757
|
+
] }),
|
|
7758
|
+
hires && hires.length > 0 && /* @__PURE__ */ jsx20("div", { className: "space-y-2", children: hires.map((h) => /* @__PURE__ */ jsxs14("label", { className: "flex items-center gap-2 text-sm", children: [
|
|
7759
|
+
/* @__PURE__ */ jsx20(
|
|
7760
|
+
"input",
|
|
7761
|
+
{
|
|
7762
|
+
type: "checkbox",
|
|
7763
|
+
checked: selectedIds.includes(h.id),
|
|
7764
|
+
disabled: approving || loading,
|
|
7765
|
+
onChange: (event) => setSelectedIds(
|
|
7766
|
+
(previous) => event.target.checked ? [...previous, h.id] : previous.filter((id) => id !== h.id)
|
|
7767
|
+
)
|
|
7768
|
+
}
|
|
7769
|
+
),
|
|
7770
|
+
h.name || h.id.slice(0, 8)
|
|
7771
|
+
] }, h.id)) }),
|
|
7772
|
+
loading && /* @__PURE__ */ jsx20("p", { className: "text-xs text-muted-foreground", role: "status", children: "Loading pending hires\u2026" }),
|
|
7773
|
+
loadError && /* @__PURE__ */ jsx20("p", { className: "text-xs text-red-600 wrap-break-word", role: "alert", children: loadError }),
|
|
7774
|
+
actionError && /* @__PURE__ */ jsx20("p", { className: "text-xs text-red-600 wrap-break-word", role: "alert", children: actionError }),
|
|
7775
|
+
message && /* @__PURE__ */ jsx20("p", { className: "text-xs text-muted-foreground", role: "status", children: message }),
|
|
7776
|
+
/* @__PURE__ */ jsxs14("div", { className: "flex flex-wrap gap-2", children: [
|
|
7777
|
+
hires && hires.length > 0 && /* @__PURE__ */ jsxs14(
|
|
7778
|
+
Button,
|
|
7779
|
+
{
|
|
7780
|
+
size: "sm",
|
|
7781
|
+
onClick: approveSelected,
|
|
7782
|
+
disabled: approving || loading || selectedIds.length === 0,
|
|
7783
|
+
children: [
|
|
7784
|
+
approving ? /* @__PURE__ */ jsx20(LoaderCircle, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ jsx20(ShieldCheck, { className: "h-4 w-4" }),
|
|
7785
|
+
approving ? "Approving\u2026" : `Approve selected (${selectedIds.length})`
|
|
7786
|
+
]
|
|
7787
|
+
}
|
|
7788
|
+
),
|
|
7789
|
+
/* @__PURE__ */ jsxs14(
|
|
7790
|
+
Button,
|
|
7791
|
+
{
|
|
7792
|
+
variant: "outline",
|
|
7793
|
+
size: "sm",
|
|
7794
|
+
onClick: () => void load(),
|
|
7795
|
+
disabled: approving || loading,
|
|
7796
|
+
children: [
|
|
7797
|
+
/* @__PURE__ */ jsx20(RotateCcw, { className: "h-4 w-4" }),
|
|
7798
|
+
"Refresh hires"
|
|
7799
|
+
]
|
|
7800
|
+
}
|
|
7801
|
+
)
|
|
7802
|
+
] })
|
|
7803
|
+
] }) });
|
|
7804
|
+
}
|
|
7805
|
+
function BootstrapStart({
|
|
7806
|
+
companyId,
|
|
7807
|
+
agentId,
|
|
7808
|
+
issueId
|
|
7809
|
+
}) {
|
|
7810
|
+
const startBootstrap = usePluginAction8("start-bootstrap");
|
|
7811
|
+
const [starting, setStarting] = useState11(false);
|
|
7812
|
+
const [started, setStarted] = useState11(false);
|
|
7813
|
+
const [error, setError] = useState11(null);
|
|
7814
|
+
const [message, setMessage] = useState11(null);
|
|
7815
|
+
const [warnings, setWarnings] = useState11([]);
|
|
7816
|
+
const start = async () => {
|
|
7817
|
+
if (starting || started) return;
|
|
7818
|
+
setStarting(true);
|
|
7819
|
+
setError(null);
|
|
7820
|
+
setMessage(null);
|
|
7821
|
+
setWarnings([]);
|
|
7822
|
+
try {
|
|
7823
|
+
const res = await startBootstrap({ companyId, agentId, issueId });
|
|
7824
|
+
setWarnings(Array.isArray(res?.warnings) ? res.warnings : []);
|
|
7825
|
+
if (res?.error) throw new Error(String(res.error));
|
|
7826
|
+
setStarted(res?.started === true);
|
|
7827
|
+
setMessage(
|
|
7828
|
+
res?.started ? "Bootstrap queued. Follow the CEO\u2019s progress in Paperclip." : String(res?.message || "Bootstrap was not started.")
|
|
7829
|
+
);
|
|
7830
|
+
} catch (err) {
|
|
7831
|
+
setError(err instanceof Error ? err.message : "Could not start bootstrap");
|
|
7832
|
+
} finally {
|
|
7833
|
+
setStarting(false);
|
|
7834
|
+
}
|
|
7835
|
+
};
|
|
7836
|
+
return /* @__PURE__ */ jsx20(Card, { children: /* @__PURE__ */ jsxs14(CardContent, { className: "pt-6 space-y-3", children: [
|
|
7837
|
+
/* @__PURE__ */ jsx20("p", { className: "text-sm font-medium", children: "Start company bootstrap" }),
|
|
7838
|
+
/* @__PURE__ */ jsx20("p", { className: "text-xs text-muted-foreground", children: "Once the hires are approved, start the CEO to carry out the bootstrap task." }),
|
|
7839
|
+
/* @__PURE__ */ jsxs14(Button, { size: "sm", disabled: starting || started, onClick: () => void start(), children: [
|
|
7840
|
+
starting ? /* @__PURE__ */ jsx20(LoaderCircle, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ jsx20(Play, { className: "h-4 w-4" }),
|
|
7841
|
+
starting ? "Starting\u2026" : started ? "Bootstrap queued" : "Start bootstrap"
|
|
7842
|
+
] }),
|
|
7843
|
+
error && /* @__PURE__ */ jsx20("p", { className: "text-xs text-red-600 wrap-break-word", role: "alert", children: error }),
|
|
7844
|
+
message && /* @__PURE__ */ jsx20("p", { className: "text-xs text-muted-foreground", role: "status", children: message }),
|
|
7845
|
+
warnings.map((warning) => /* @__PURE__ */ jsx20("p", { className: "text-xs text-amber-600 wrap-break-word", children: warning }, warning))
|
|
7846
|
+
] }) });
|
|
7847
|
+
}
|
|
7562
7848
|
function StepDone() {
|
|
7563
7849
|
const state = useWizard();
|
|
7564
7850
|
const dispatch = useWizardDispatch();
|
|
@@ -7612,6 +7898,23 @@ function StepDone() {
|
|
|
7612
7898
|
/* @__PURE__ */ jsx20("p", { className: "font-mono text-xs", children: result.companyId })
|
|
7613
7899
|
] })
|
|
7614
7900
|
] }) }),
|
|
7901
|
+
result?.companyId && (result.pendingApprovalIds?.length ?? 0) > 0 && /* @__PURE__ */ jsx20(
|
|
7902
|
+
PendingHires,
|
|
7903
|
+
{
|
|
7904
|
+
companyId: result.companyId,
|
|
7905
|
+
approvalIds: result.pendingApprovalIds
|
|
7906
|
+
},
|
|
7907
|
+
`${result.companyId}:${result.pendingApprovalIds.join(",")}`
|
|
7908
|
+
),
|
|
7909
|
+
result?.companyId && result.bootstrapIssueId && result.agentIds.ceo && /* @__PURE__ */ jsx20(
|
|
7910
|
+
BootstrapStart,
|
|
7911
|
+
{
|
|
7912
|
+
companyId: result.companyId,
|
|
7913
|
+
agentId: result.agentIds.ceo,
|
|
7914
|
+
issueId: result.bootstrapIssueId
|
|
7915
|
+
},
|
|
7916
|
+
result.bootstrapIssueId
|
|
7917
|
+
),
|
|
7615
7918
|
/* @__PURE__ */ jsxs14("div", { className: "flex gap-3", children: [
|
|
7616
7919
|
/* @__PURE__ */ jsxs14(Button, { variant: "outline", onClick: () => dispatch({ type: "RESET" }), children: [
|
|
7617
7920
|
/* @__PURE__ */ jsx20(RotateCcw, { className: "h-4 w-4" }),
|
|
@@ -7698,13 +8001,13 @@ function StepIndicator() {
|
|
|
7698
8001
|
function WizardShell() {
|
|
7699
8002
|
const state = useWizard();
|
|
7700
8003
|
const dispatch = useWizardDispatch();
|
|
7701
|
-
const restoredFromHistory =
|
|
7702
|
-
const seededHistory =
|
|
8004
|
+
const restoredFromHistory = useRef9(false);
|
|
8005
|
+
const seededHistory = useRef9(false);
|
|
7703
8006
|
const StepComponent = STEP_COMPONENTS[state.step];
|
|
7704
|
-
|
|
8007
|
+
useEffect10(() => {
|
|
7705
8008
|
window.scrollTo({ top: 0 });
|
|
7706
8009
|
}, [state.step]);
|
|
7707
|
-
|
|
8010
|
+
useEffect10(() => {
|
|
7708
8011
|
const handlePopState = (event) => {
|
|
7709
8012
|
const historyState = readWizardHistoryState(event.state);
|
|
7710
8013
|
if (!historyState?.step) return;
|
|
@@ -7718,7 +8021,7 @@ function WizardShell() {
|
|
|
7718
8021
|
window.addEventListener("popstate", handlePopState);
|
|
7719
8022
|
return () => window.removeEventListener("popstate", handlePopState);
|
|
7720
8023
|
}, [dispatch]);
|
|
7721
|
-
|
|
8024
|
+
useEffect10(() => {
|
|
7722
8025
|
if (!seededHistory.current) {
|
|
7723
8026
|
seededHistory.current = true;
|
|
7724
8027
|
window.history.replaceState(
|
|
@@ -7897,12 +8200,14 @@ lucide-react/dist/esm/icons/loader-circle.js:
|
|
|
7897
8200
|
lucide-react/dist/esm/icons/lock.js:
|
|
7898
8201
|
lucide-react/dist/esm/icons/message-square.js:
|
|
7899
8202
|
lucide-react/dist/esm/icons/pencil.js:
|
|
8203
|
+
lucide-react/dist/esm/icons/play.js:
|
|
7900
8204
|
lucide-react/dist/esm/icons/refresh-cw.js:
|
|
7901
8205
|
lucide-react/dist/esm/icons/rocket.js:
|
|
7902
8206
|
lucide-react/dist/esm/icons/rotate-ccw.js:
|
|
7903
8207
|
lucide-react/dist/esm/icons/send.js:
|
|
7904
8208
|
lucide-react/dist/esm/icons/settings-2.js:
|
|
7905
8209
|
lucide-react/dist/esm/icons/settings.js:
|
|
8210
|
+
lucide-react/dist/esm/icons/shield-check.js:
|
|
7906
8211
|
lucide-react/dist/esm/icons/shield.js:
|
|
7907
8212
|
lucide-react/dist/esm/icons/sparkles.js:
|
|
7908
8213
|
lucide-react/dist/esm/icons/target.js:
|