Commit 8800406
committed
feat(ai-chat): support SDK classifier-driven Auto permission mode
Companion to the phoenix-pro change adding a 4th permission mode,
'auto', which routes tool-call approval through the Claude Agent
SDK's own model classifier instead of a blanket accept-all. The SDK
(pinned ^0.2.126, installed 0.2.141) already supports this — no SDK
upgrade needed.
- src-node/claude-code-agent.js: default permission mode changed from
acceptEdits to auto (matches the browser default); comments updated
— no functional hook changes required, since the existing
PreToolUse hooks already defer to the SDK for any mode they don't
specifically handle.
- strings.js: new AI_CHAT_MODE_AUTO / AI_CHAT_MODE_INFO_AUTO strings;
renamed 'Full Auto' to 'Allow Everything' throughout (label, consent
dialog title/body/button) to stay distinct from the new Auto mode.
- Extn-AIChatPanel.less: new mode-classifier dot color for Auto;
permission dropdown popup capped against the viewport (90vh)
instead of inheriting the shared widget's 160px max-height, which
forced an unnecessary scrollbar for 4 two-line items.1 parent ab41a33 commit 8800406
3 files changed
Lines changed: 35 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
111 | 114 | | |
112 | 115 | | |
113 | 116 | | |
| |||
661 | 664 | | |
662 | 665 | | |
663 | 666 | | |
664 | | - | |
| 667 | + | |
665 | 668 | | |
666 | 669 | | |
667 | 670 | | |
| |||
758 | 761 | | |
759 | 762 | | |
760 | 763 | | |
761 | | - | |
| 764 | + | |
762 | 765 | | |
763 | 766 | | |
764 | 767 | | |
| |||
901 | 904 | | |
902 | 905 | | |
903 | 906 | | |
904 | | - | |
| 907 | + | |
905 | 908 | | |
906 | 909 | | |
907 | 910 | | |
| |||
1288 | 1291 | | |
1289 | 1292 | | |
1290 | 1293 | | |
1291 | | - | |
1292 | | - | |
1293 | | - | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
1294 | 1297 | | |
1295 | | - | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
| 1301 | + | |
| 1302 | + | |
1296 | 1303 | | |
1297 | 1304 | | |
1298 | 1305 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2660 | 2660 | | |
2661 | 2661 | | |
2662 | 2662 | | |
2663 | | - | |
2664 | | - | |
2665 | | - | |
| 2663 | + | |
| 2664 | + | |
| 2665 | + | |
2666 | 2666 | | |
2667 | 2667 | | |
2668 | 2668 | | |
| |||
2699 | 2699 | | |
2700 | 2700 | | |
2701 | 2701 | | |
2702 | | - | |
| 2702 | + | |
| 2703 | + | |
2703 | 2704 | | |
2704 | 2705 | | |
| 2706 | + | |
2705 | 2707 | | |
2706 | 2708 | | |
2707 | 2709 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
454 | 454 | | |
455 | 455 | | |
456 | 456 | | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
457 | 463 | | |
458 | 464 | | |
459 | 465 | | |
| |||
2726 | 2732 | | |
2727 | 2733 | | |
2728 | 2734 | | |
| 2735 | + | |
| 2736 | + | |
| 2737 | + | |
| 2738 | + | |
2729 | 2739 | | |
2730 | 2740 | | |
2731 | 2741 | | |
| |||
0 commit comments