@strands-agents/cli 0.1.2 → 0.1.4

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 (83) hide show
  1. package/README.md +11 -8
  2. package/dist/src/cli/arguments.js +40 -1
  3. package/dist/src/cli/arguments.js.map +1 -1
  4. package/dist/src/cli/run.js +7 -9
  5. package/dist/src/cli/run.js.map +1 -1
  6. package/dist/src/cli/update.js +67 -0
  7. package/dist/src/cli/update.js.map +1 -0
  8. package/dist/src/tui/agent-configuration.js +30 -38
  9. package/dist/src/tui/agent-configuration.js.map +1 -1
  10. package/dist/src/tui/builtin-tools.js +29 -0
  11. package/dist/src/tui/builtin-tools.js.map +1 -1
  12. package/dist/src/tui/chat/commands.js +2 -1
  13. package/dist/src/tui/chat/commands.js.map +1 -1
  14. package/dist/src/tui/chat/controller.js +81 -87
  15. package/dist/src/tui/chat/controller.js.map +1 -1
  16. package/dist/src/tui/chat/help.js +1 -0
  17. package/dist/src/tui/chat/help.js.map +1 -1
  18. package/dist/src/tui/chat/panels.js +21 -11
  19. package/dist/src/tui/chat/panels.js.map +1 -1
  20. package/dist/src/tui/chat/types.js.map +1 -1
  21. package/dist/src/tui/npm.js +32 -0
  22. package/dist/src/tui/npm.js.map +1 -0
  23. package/dist/src/tui/permissions/policy.js +1 -9
  24. package/dist/src/tui/permissions/policy.js.map +1 -1
  25. package/dist/src/tui/permissions/settings.js +9 -8
  26. package/dist/src/tui/permissions/settings.js.map +1 -1
  27. package/dist/src/tui/project/export.js +19 -2
  28. package/dist/src/tui/project/export.js.map +1 -1
  29. package/dist/src/tui/project/python.js +1 -1
  30. package/dist/src/tui/project/python.js.map +1 -1
  31. package/dist/src/tui/project/worker.py +56 -7
  32. package/dist/src/tui/provider/aws-client.js +3 -3
  33. package/dist/src/tui/provider/aws-client.js.map +1 -1
  34. package/dist/src/tui/run.js +5 -12
  35. package/dist/src/tui/run.js.map +1 -1
  36. package/dist/src/tui/runtime.js +8 -7
  37. package/dist/src/tui/runtime.js.map +1 -1
  38. package/dist/src/tui/session/context.js +23 -13
  39. package/dist/src/tui/session/context.js.map +1 -1
  40. package/dist/src/tui/session/conversations.js +21 -3
  41. package/dist/src/tui/session/conversations.js.map +1 -1
  42. package/dist/src/tui/strands-backend.js +46 -15
  43. package/dist/src/tui/strands-backend.js.map +1 -1
  44. package/dist/src/tui/update-check.js +37 -0
  45. package/dist/src/tui/update-check.js.map +1 -0
  46. package/dist/src/tui/view/app.js +33 -20
  47. package/dist/src/tui/view/app.js.map +1 -1
  48. package/dist/src/tui/view/chat-root.js +38 -29
  49. package/dist/src/tui/view/chat-root.js.map +1 -1
  50. package/dist/src/tui/view/chat-view.js +4 -39
  51. package/dist/src/tui/view/chat-view.js.map +1 -1
  52. package/dist/src/tui/view/frog-intro-renderer.js +14 -84
  53. package/dist/src/tui/view/frog-intro-renderer.js.map +1 -1
  54. package/dist/src/tui/view/help-footer.js +19 -13
  55. package/dist/src/tui/view/help-footer.js.map +1 -1
  56. package/dist/src/tui/view/interaction.js +1 -1
  57. package/dist/src/tui/view/interaction.js.map +1 -1
  58. package/dist/src/tui/view/mcp-trust-prompt.js +17 -0
  59. package/dist/src/tui/view/mcp-trust-prompt.js.map +1 -0
  60. package/dist/src/tui/view/panels.js +24 -14
  61. package/dist/src/tui/view/panels.js.map +1 -1
  62. package/dist/src/tui/view/rename-panel.js +11 -0
  63. package/dist/src/tui/view/rename-panel.js.map +1 -0
  64. package/dist/src/tui/view/setup-wizard/index.js +90 -123
  65. package/dist/src/tui/view/setup-wizard/index.js.map +1 -1
  66. package/dist/src/tui/view/setup-wizard/opening-menu.js +2 -2
  67. package/dist/src/tui/view/setup-wizard/opening-menu.js.map +1 -1
  68. package/dist/src/tui/view/setup-wizard/progress.js +1 -2
  69. package/dist/src/tui/view/setup-wizard/progress.js.map +1 -1
  70. package/dist/src/tui/view/setup-wizard/providers.js +2 -1
  71. package/dist/src/tui/view/setup-wizard/providers.js.map +1 -1
  72. package/dist/src/tui/view/setup-wizard/steps.js +60 -46
  73. package/dist/src/tui/view/setup-wizard/steps.js.map +1 -1
  74. package/dist/src/tui/view/startup-view.js +4 -2
  75. package/dist/src/tui/view/startup-view.js.map +1 -1
  76. package/dist/src/tui/view/transcript.js +1 -1
  77. package/package.json +4 -2
  78. package/dist/src/tui/agent-setup.js +0 -80
  79. package/dist/src/tui/agent-setup.js.map +0 -1
  80. package/dist/src/tui/setup/questions.js +0 -277
  81. package/dist/src/tui/setup/questions.js.map +0 -1
  82. package/dist/src/tui/view/setup-question.js +0 -90
  83. package/dist/src/tui/view/setup-question.js.map +0 -1
@@ -11,7 +11,6 @@ import { emptyEditor, graphemes, reduceInputSequence } from '../../terminal/comp
11
11
  import { errorMessage, sanitizeTerminalText } from '../../terminal/sanitize.js';
12
12
  import { canChooseDirectory, chooseAgentProject, chooseDirectory } from '../../terminal/directory-picker.js';
13
13
  import { setTerminalMouseMotion } from '../../terminal/terminal.js';
14
- import { renderSetupGuideTransitionFrame, SETUP_GUIDE_TRANSITION_DURATION_MS, setupGuideLayout, } from '../frog-intro-renderer.js';
15
14
  import { elementAtMouse, elementContainsMouse, registerElement, mouseScrollDirection, scrollPanelViewport, revealPanelSelection, sliderOptionAtMouse, } from '../interaction.js';
16
15
  import { wrapLines } from '../presentation.js';
17
16
  import { Text, ThemeProvider, useTheme } from '../theme.js';
@@ -21,7 +20,7 @@ import { Fade, mixHexColors, useFadeTransition } from '../fade-in.js';
21
20
  import { PROVIDERS, compatibleProfile, exaWebSearchActive, providerSupportsWebSearch, providerAssessment, providerFromModel, quickstartDraft, } from './providers.js';
22
21
  import { EXA_WEB_SEARCH_WARNING } from '../../builtin-tools.js';
23
22
  import { memoryForDir } from './profile-fields.js';
24
- import { APPEARANCE_STEP, appearanceSettings, MANUAL_STEPS, OPENING_CHOICES, rowsForStep, setupStepProgress, wizardSettingsRows, } from './steps.js';
23
+ import { APPEARANCE_STEP, appearanceSettings, CUSTOMIZE_STEPS, OPENING_CHOICES, rowsForStep, setupStepProgress, wizardSettingsRows, } from './steps.js';
25
24
  import { useBrandAnimation } from '../startup-view.js';
26
25
  import { SetupBrand, setupBrandFrame } from './brand.js';
27
26
  import { OpeningMenu } from './opening-menu.js';
@@ -31,11 +30,12 @@ import { ProviderList } from '../provider-list.js';
31
30
  import { useProviderDiscovery, useProviderDiscoveryEffects } from './use-provider-discovery.js';
32
31
  import { importPathCompletions } from './path-completion.js';
33
32
  import { SetupProgress } from './progress.js';
33
+ import { availableCliUpdate } from '../../update-check.js';
34
34
  export function SetupWizard(props) {
35
35
  const [appearance, setAppearance] = useState(() => appearanceSettings({ ...props.config.snapshot().settings, ...props.initialSettings }));
36
36
  return (_jsx(ThemeProvider, { settings: appearance, children: _jsx(SetupWizardContent, { ...props, appearance: appearance, setAppearance: setAppearance }) }));
37
37
  }
38
- function SetupWizardContent({ appearance, setAppearance, config, deferred = false, appearanceOnly = false, onComplete, onCancel, onAgentSetup, initialSettings, }) {
38
+ function SetupWizardContent({ appearance, setAppearance, config, deferred = false, appearanceOnly = false, onComplete, onCancel, initialSettings, checkForUpdate = availableCliUpdate, }) {
39
39
  const { stdout } = useStdout();
40
40
  const { columns, rows: terminalRows } = useWindowSize();
41
41
  const [flow, setFlow] = useState();
@@ -79,12 +79,12 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
79
79
  },
80
80
  };
81
81
  });
82
- const [setupTarget, setSetupTarget] = useState();
83
82
  const [profileBaseDir] = useState(() => config.snapshot().profileBaseDir);
84
83
  const [importPath, setImportPath] = useState('');
85
84
  const [editing, setEditing] = useState();
86
85
  const [pathCompletionIndex, setPathCompletionIndex] = useState(-1);
87
86
  const [error, setError] = useState();
87
+ const [availableUpdate, setAvailableUpdate] = useState();
88
88
  const [saving, setSaving] = useState(false);
89
89
  const [choosingDirectory, setChoosingDirectory] = useState(false);
90
90
  const choosingDirectoryRef = useRef(false);
@@ -102,9 +102,6 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
102
102
  const [quickstartProvider, setQuickstartProvider] = useState('bedrock');
103
103
  const [selecting, setSelecting] = useState();
104
104
  const [frogAnimationId, setFrogAnimationId] = useState();
105
- const [agentHandoff, setAgentHandoff] = useState();
106
- const [agentHandoffElapsedMs, setAgentHandoffElapsedMs] = useState(0);
107
- const agentHandoffDelivered = useRef(false);
108
105
  const rowElements = useRef(new Map());
109
106
  const directoryElements = useRef(new Map());
110
107
  const pathCompletionElements = useRef(new Map());
@@ -118,33 +115,6 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
118
115
  const pressedElement = useRef(undefined);
119
116
  const width = Math.max(1, columns);
120
117
  const height = Math.max(1, terminalRows);
121
- useEffect(() => {
122
- if (!agentHandoff || !onAgentSetup) {
123
- return;
124
- }
125
- const duration = appearance.animations ? SETUP_GUIDE_TRANSITION_DURATION_MS : 0;
126
- const startedAt = Date.now();
127
- const finish = () => {
128
- if (!agentHandoffDelivered.current) {
129
- agentHandoffDelivered.current = true;
130
- onAgentSetup(agentHandoff);
131
- }
132
- };
133
- setAgentHandoffElapsedMs(duration === 0 ? SETUP_GUIDE_TRANSITION_DURATION_MS : 0);
134
- if (duration === 0) {
135
- finish();
136
- return;
137
- }
138
- const timer = setInterval(() => {
139
- const elapsed = Math.min(duration, Date.now() - startedAt);
140
- setAgentHandoffElapsedMs(elapsed);
141
- if (elapsed >= duration) {
142
- clearInterval(timer);
143
- finish();
144
- }
145
- }, 32);
146
- return () => clearInterval(timer);
147
- }, [agentHandoff, appearance.animations, onAgentSetup]);
148
118
  const navigationHeight = width < 32 ? 2 : 3;
149
119
  const accent = palette.accent;
150
120
  const pathEditing = editing?.field === 'importPath' ? editing : undefined;
@@ -159,6 +129,20 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
159
129
  useEffect(() => {
160
130
  setPathCompletionIndex(-1);
161
131
  }, [pathEditing?.value]);
132
+ useEffect(() => {
133
+ if (appearanceOnly) {
134
+ return;
135
+ }
136
+ let active = true;
137
+ void checkForUpdate().then((version) => {
138
+ if (active) {
139
+ setAvailableUpdate(version);
140
+ }
141
+ });
142
+ return () => {
143
+ active = false;
144
+ };
145
+ }, [appearanceOnly, checkForUpdate]);
162
146
  const isAppearance = step === APPEARANCE_STEP;
163
147
  const isSettings = isAppearance && settingsReturn !== undefined;
164
148
  const progress = appearanceOnly || isSettings ? undefined : setupStepProgress(flow, step);
@@ -203,13 +187,13 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
203
187
  },
204
188
  }));
205
189
  }, [setAppearance]);
206
- const isProviderSetup = (flow === 'quickstart' || flow === 'manual' || flow === 'agent') && step === 1;
207
- const isTools = (flow === 'quickstart' && step === 2) || (flow === 'manual' && step === 3);
208
- const isPlugins = (flow === 'quickstart' && step === 3) || (flow === 'manual' && step === 4);
190
+ const isProviderSetup = (flow === 'quickstart' || flow === 'customize') && step === 1;
191
+ const isTools = flow === 'customize' && step === 3;
192
+ const isPlugins = flow === 'customize' && step === 4;
209
193
  const isCapabilities = isTools || isPlugins;
210
- const isPermissions = flow === 'manual' && step === 6;
194
+ const isPermissions = flow === 'customize' && step === 6;
211
195
  const isImport = flow === 'import' && step === 1;
212
- const hasExternalActions = !isSettings && (isProviderSetup || isImport || isCapabilities || isAppearance || flow === 'manual');
196
+ const hasExternalActions = !isSettings && (isProviderSetup || isImport || isCapabilities || isAppearance || flow === 'customize');
213
197
  const bubbleWidth = Math.max(1, Math.min(isProviderSetup ? 144 : 112, width - 2));
214
198
  const lockupWidth = Math.max(1, width - 2);
215
199
  const brandFrame = setupBrandFrame(lockupWidth, height);
@@ -219,7 +203,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
219
203
  const openingColumns = lockupWidth >= 64 ? 2 : 1;
220
204
  const openingRows = Math.ceil(OPENING_CHOICES.length / openingColumns);
221
205
  const openingRowGap = openingColumns === 2 ? 2 : 1;
222
- const openingContentHeight = height - brandHeight - navigationHeight - Number(error !== undefined);
206
+ const openingContentHeight = height - brandHeight - navigationHeight - (error ? 2 : 0);
223
207
  const openingTopGap = openingContentHeight >= openingRows * (openingColumns === 2 ? 9 : 5) + (openingRows - 1) * openingRowGap + 3
224
208
  ? 3
225
209
  : openingContentHeight >= openingRows * (openingColumns === 2 ? 8 : 5) + (openingRows - 1) * openingRowGap + 2
@@ -243,7 +227,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
243
227
  ? 1
244
228
  : isPermissions
245
229
  ? 2
246
- : flow === 'manual'
230
+ : flow === 'customize'
247
231
  ? step === 2
248
232
  ? 5
249
233
  : step === 5
@@ -335,6 +319,9 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
335
319
  : undefined;
336
320
  const warning = keyCredentialProvider ? undefined : inspectedAssessment?.warning;
337
321
  const assessmentFacts = inspectedAssessment?.facts ?? [];
322
+ const quickstartExaSearchActive = flow === 'quickstart' && step === 1 && exaWebSearchActive(draft.profile);
323
+ const quickstartWebSearchOffered = rows.some((row) => row.id === 'quickstart-web-search');
324
+ const canShowQuickstartOptionsPanel = splitQuickstart && quickstartDetailColumnWidth >= 62;
338
325
  const bannerWarning = warning
339
326
  ? assessmentFacts.length > 0
340
327
  ? [
@@ -344,7 +331,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
344
331
  warning,
345
332
  ].join('\n')
346
333
  : `${PROVIDER_LABELS[inspectedProvider]}: ${warning}`
347
- : isTools && exaWebSearchActive(draft.profile)
334
+ : isTools || quickstartExaSearchActive
348
335
  ? EXA_WEB_SEARCH_WARNING
349
336
  : undefined;
350
337
  const bannerWarningStatus = warning ? inspectedAssessment.status : 'warning';
@@ -355,10 +342,12 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
355
342
  const bannerLines = (text) => wrapLines(`⚠ ${text}`, Math.max(1, bubbleWidth - 4)).slice(0, Math.max(0, availableBubbleHeight - rowHeight - 1 - Number(error !== undefined)));
356
343
  const warningLines = bannerWarning && !splitQuickstart ? bannerLines(bannerWarning) : [];
357
344
  // Reserve the Exa banner's space whether or not web_search is on, so toggling it doesn't resize the panel.
358
- const warningHeight = isTools && !warning && !providerSupportsWebSearch(draft.profile.model)
345
+ const warningHeight = (isTools || (quickstartWebSearchOffered && !splitQuickstart)) &&
346
+ !warning &&
347
+ !providerSupportsWebSearch(draft.profile.model)
359
348
  ? bannerLines(EXA_WEB_SEARCH_WARNING).length
360
349
  : warningLines.length;
361
- const warningGap = isCapabilities && warningHeight > 0 ? 1 : 0;
350
+ const warningGap = (isCapabilities || flow === 'quickstart') && warningHeight > 0 ? 1 : 0;
362
351
  const extraRows = Number(error !== undefined) + warningGap + warningHeight;
363
352
  const capabilityContentHeight = Math.max(0, rows.length - 1) * rowHeight + 2;
364
353
  const bubbleHeight = isImport
@@ -369,10 +358,10 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
369
358
  ? Math.min(9 + Math.max(0, rows.length - 3) * rowHeight + extraRows, availableBubbleHeight)
370
359
  : isAppearance
371
360
  ? availableBubbleHeight
372
- : flow === 'manual' && !isProviderSetup
361
+ : flow === 'customize' && !isProviderSetup
373
362
  ? Math.min(rows.length * rowHeight + 3 + extraRows, availableBubbleHeight)
374
363
  : availableBubbleHeight;
375
- const panelChromeHeight = isProviderSetup || isCapabilities ? 0 : isAppearance || flow === 'manual' ? 2 : 4;
364
+ const panelChromeHeight = isProviderSetup || isCapabilities ? 0 : isAppearance || flow === 'customize' ? 2 : 4;
376
365
  const rowCapacity = isAppearance
377
366
  ? settingsCategory === 'Appearance' && bubbleHeight < 18
378
367
  ? 1
@@ -383,7 +372,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
383
372
  const visibleRows = rows.slice(viewportStart, viewportStart + rowCapacity);
384
373
  const hiddenRowsBefore = viewportStart;
385
374
  const hiddenRowsAfter = Math.max(0, rows.length - viewportStart - visibleRows.length);
386
- const manualOverflowLabel = [
375
+ const customizeOverflowLabel = [
387
376
  hiddenRowsBefore > 0 ? `↑ ${hiddenRowsBefore} previous` : '',
388
377
  hiddenRowsAfter > 0 ? `↓ ${hiddenRowsAfter} more` : '',
389
378
  ]
@@ -420,8 +409,11 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
420
409
  ...(reasoningRow.disabled ? { disabled: true } : {}),
421
410
  }
422
411
  : undefined;
423
- const showReasoningPanel = modelPanelVisible && reasoningSlider !== undefined && quickstartDetailColumnWidth >= 62;
424
- const readyProviderControlRows = providerConfigurationRows.filter((row) => row.id !== 'thinking' || (reasoningRow !== undefined && !showReasoningPanel));
412
+ const webSearchRow = providerConfigurationRows.find((row) => row.id === 'quickstart-web-search');
413
+ const showModelOptionsPanel = modelPanelVisible && canShowQuickstartOptionsPanel && (reasoningSlider !== undefined || webSearchRow !== undefined);
414
+ const showReasoningPanel = showModelOptionsPanel && reasoningSlider !== undefined;
415
+ const readyProviderControlRows = providerConfigurationRows.filter((row) => (row.id !== 'thinking' || (reasoningRow !== undefined && !showReasoningPanel)) &&
416
+ (row.id !== 'quickstart-web-search' || !showModelOptionsPanel));
425
417
  const directoryRows = new Map(rows.flatMap((row, index) => canChooseDirectory() && !row.disabled && (row.field === 'memoryDir' || row.field === 'skills')
426
418
  ? [[index, row.field]]
427
419
  : []));
@@ -500,6 +492,20 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
500
492
  const editable = row.input === true;
501
493
  return (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), height: quickstartFieldRowHeight, flexShrink: 0, flexDirection: "column", backgroundColor: credential && editable ? undefined : rowBackground(index), children: [_jsx(Text, { bold: true, ...(index === selection ? { color: accent } : {}), wrap: "truncate-end", children: row.label }), editable ? (_jsxs(_Fragment, { children: [_jsx(Box, { width: fieldWidth, height: 3, paddingX: 1, alignItems: "center", backgroundColor: rowBackground(index) ?? COMMAND_DECK_BACKGROUND, children: _jsx(EditableText, { value: activeEditing?.value ?? (row.selectOptions ? row.description : ''), cursor: activeEditing?.cursor ?? graphemes(activeEditing?.value ?? '').length, width: Math.max(1, fieldWidth - 4), active: Boolean(activeEditing), animate: appearance.animations, masked: credential }) }), credential ? (_jsx(Text, { dimColor: true, wrap: "truncate-end", children: row.description })) : null] })) : row.choices?.length ? (renderChoices(row.choices, index)) : activeEditing ? (_jsx(EditableText, { value: activeEditing.value, cursor: activeEditing.cursor ?? graphemes(activeEditing.value).length, width: Math.max(1, fieldWidth - 4), active: true, animate: appearance.animations })) : (_jsx(Text, { dimColor: true, children: row.description || ' ' }))] }, row.id));
502
494
  };
495
+ // The note keeps a fixed height so toggling Exa never resizes the panel.
496
+ const renderQuickstartWebSearch = (row, panel) => {
497
+ const index = rows.indexOf(row);
498
+ const focused = focusedAction === undefined && !modelSearchFocused && index === selection && !saving;
499
+ return (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), ...(panel ? {} : { height: quickstartFieldRowHeight }), flexShrink: 0, flexDirection: "column", children: [_jsx(Text, { bold: true, ...(panel || focused ? { color: accent } : {}), children: row.label }), _jsx(Box, { flexShrink: 0, alignSelf: "flex-start", backgroundColor: focused ? PANEL_SELECTION : COMMAND_DECK_BACKGROUND, children: row.choices?.map((choice, choiceIndex) => {
500
+ const target = `choice:${index}:${choiceIndex}`;
501
+ const background = choice.active
502
+ ? nextHoverBackground
503
+ : hoveredControl === target && !saving
504
+ ? PANEL_SELECTION
505
+ : undefined;
506
+ return (_jsx(Box, { ref: (element) => registerElement(choiceElements.current, target, element), paddingX: 2, backgroundColor: background, children: _jsx(Text, { bold: choice.active, ...(choice.active ? { color: accent } : { dimColor: true }), children: choice.label }) }, choice.label));
507
+ }) }), quickstartExaSearchActive ? (_jsxs(_Fragment, { children: [_jsx(Text, { color: palette.warning, wrap: "truncate-end", children: "\u26A0 Third-party search via Exa" }), _jsx(Text, { dimColor: true, wrap: "truncate-end", children: "https://exa.ai/privacy-policy" })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { dimColor: true, wrap: "truncate-end", children: row.description }), _jsx(Text, { children: " " })] }))] }, row.id));
508
+ };
503
509
  const renderProviderSelect = (state) => {
504
510
  const capacity = Math.max(1, quickstartBodyHeight - middleDetailHeight - 3);
505
511
  const start = Math.max(0, Math.min(state.selection - capacity + 1, state.options.length - capacity));
@@ -619,9 +625,10 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
619
625
  setStep(1);
620
626
  setError(undefined);
621
627
  if (nextFlow !== 'import') {
622
- if (nextFlow === 'agent')
623
- setSetupTarget(draft);
624
628
  const provider = providerFromModel(draft.profile.model) ?? 'bedrock';
629
+ if (nextFlow === 'quickstart') {
630
+ setDraft(quickstartDraft(provider, effectiveEnvironment));
631
+ }
625
632
  setQuickstartProvider(provider);
626
633
  setSelection(PROVIDER_IDS.indexOf(provider));
627
634
  }
@@ -631,6 +638,17 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
631
638
  }
632
639
  });
633
640
  }
641
+ function chooseOpeningChoice(choice) {
642
+ if (choice !== 'resume') {
643
+ chooseFlow(choice);
644
+ return;
645
+ }
646
+ if (config.needsSetup()) {
647
+ setError('No harness is ready to resume yet. Choose Quickstart or Customize to create one, or Import your own.');
648
+ return;
649
+ }
650
+ onCancel?.(0);
651
+ }
634
652
  function completeSetup(completedDraft = draft, agentProject) {
635
653
  let saved;
636
654
  setSaving(true);
@@ -684,7 +702,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
684
702
  return;
685
703
  }
686
704
  if (step === 0) {
687
- chooseFlow(OPENING_CHOICES[selection].id);
705
+ chooseOpeningChoice(OPENING_CHOICES[selection].id);
688
706
  return;
689
707
  }
690
708
  if (isAppearance) {
@@ -705,30 +723,6 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
705
723
  setError('Select a provider with detected credentials; follow the provider setup instructions.');
706
724
  return;
707
725
  }
708
- if (flow === 'agent') {
709
- if (!onAgentSetup || !setupTarget) {
710
- setError('Agent Q&A is not available in this setup session.');
711
- return;
712
- }
713
- agentHandoffDelivered.current = false;
714
- setAgentHandoffElapsedMs(0);
715
- setAgentHandoff({
716
- model: draft.profile.model,
717
- effort: compatibleProfile(draft.profile).effort,
718
- configuration: {
719
- profile: setupTarget.profile,
720
- permissionMode: setupTarget.permissionMode,
721
- allowedTools: setupTarget.customPermissions || setupTarget.permissionMode === 'bypassPermissions'
722
- ? setupTarget.allowedTools
723
- : [],
724
- providers: [...new Set([...setupTarget.providers, ...readyProviders])],
725
- providerEnvironment,
726
- settings: setupTarget.settings,
727
- ...(profileBaseDir !== undefined ? { profileBaseDir } : {}),
728
- },
729
- });
730
- return;
731
- }
732
726
  if (flow === 'quickstart') {
733
727
  const provider = providerFromModel(draft.profile.model);
734
728
  if (!provider || !readyProviders.includes(provider)) {
@@ -741,21 +735,10 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
741
735
  providers: [provider, ...draft.providers.filter((candidate) => candidate !== provider)],
742
736
  };
743
737
  setDraft(completedDraft);
744
- if (step >= 3) {
745
- completeSetup(completedDraft);
746
- return;
747
- }
748
- panelTransition.transition(() => {
749
- setStep(step + 1);
750
- setSelection(0);
751
- setFocusedAction(undefined);
752
- if (step === 1) {
753
- setModelSearchFocused(false);
754
- }
755
- });
738
+ completeSetup(completedDraft);
756
739
  return;
757
740
  }
758
- if (step < MANUAL_STEPS.length) {
741
+ if (step < CUSTOMIZE_STEPS.length) {
759
742
  panelTransition.transition(() => {
760
743
  setStep((current) => current + 1);
761
744
  setFocusedAction(undefined);
@@ -804,8 +787,6 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
804
787
  return;
805
788
  }
806
789
  panelTransition.transition(() => {
807
- if (flow === 'agent' && setupTarget)
808
- setDraft(setupTarget);
809
790
  setFlow(undefined);
810
791
  setStep(0);
811
792
  setSelection(0);
@@ -904,7 +885,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
904
885
  }
905
886
  function activateRow(index) {
906
887
  if (step === 0) {
907
- chooseFlow(OPENING_CHOICES[index].id);
888
+ chooseOpeningChoice(OPENING_CHOICES[index].id);
908
889
  return;
909
890
  }
910
891
  if (isImport && index === 1) {
@@ -953,7 +934,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
953
934
  if (editing && editing.field === row.field) {
954
935
  return;
955
936
  }
956
- if (flow === 'manual' && step === MANUAL_STEPS.length) {
937
+ if (flow === 'customize' && step === CUSTOMIZE_STEPS.length) {
957
938
  const destination = [1, 2, 1, 3, 4, 5, 6][index];
958
939
  panelTransition.transition(() => {
959
940
  setStep(destination);
@@ -1029,7 +1010,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1029
1010
  }, [awsDiscovery.credentialStatus, config, effectiveEnvironment, isProviderSetup, ollamaDiscovery, readyProviders]);
1030
1011
  const frogElapsedMs = useBrandAnimation(frogAnimationId);
1031
1012
  useInput((input, key) => {
1032
- if (agentHandoff || appearanceOpen || panelTransition.transitioning)
1013
+ if (appearanceOpen || panelTransition.transitioning)
1033
1014
  return;
1034
1015
  const mouse = parseMouseInput(input);
1035
1016
  if (mouse) {
@@ -1039,7 +1020,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1039
1020
  if (isProviderSetup && modelListElement.current && elementContainsMouse(modelListElement.current, mouse)) {
1040
1021
  setModelViewportStart((start) => scrollPanelViewport(start, scroll, filteredProviderModels.length, quickstartModelCapacity));
1041
1022
  }
1042
- else if (isCapabilities || isAppearance || flow === 'manual') {
1023
+ else if (isCapabilities || isAppearance || flow === 'customize') {
1043
1024
  setFocusedAction(undefined);
1044
1025
  setSelection((current) => scrollPanelViewport(current, scroll, rows.length, 1));
1045
1026
  }
@@ -1497,8 +1478,8 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1497
1478
  }
1498
1479
  });
1499
1480
  const isSetupCompletion = isAppearance ||
1500
- (flow === 'quickstart' && step === 3) ||
1501
- (flow === 'manual' && step === MANUAL_STEPS.length) ||
1481
+ (flow === 'quickstart' && step === 1) ||
1482
+ (flow === 'customize' && step === CUSTOMIZE_STEPS.length) ||
1502
1483
  (flow === 'import' && step === 1);
1503
1484
  const primaryLabel = saving
1504
1485
  ? 'Saving...'
@@ -1506,9 +1487,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1506
1487
  ? deferred || !config.needsSetup()
1507
1488
  ? 'Save and Launch'
1508
1489
  : 'Launch Strands harness'
1509
- : flow === 'agent'
1510
- ? 'Start Q&A'
1511
- : 'Continue';
1490
+ : 'Continue';
1512
1491
  const escapeAction = editing || selecting ? 'cancel' : step === 0 ? 'exit' : 'back';
1513
1492
  const navigationHints = editing
1514
1493
  ? [
@@ -1540,23 +1519,9 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1540
1519
  }, width: 11, height: 1, paddingX: 1, flexShrink: 0, alignItems: "center", justifyContent: "center", backgroundColor: settingsBackHovered
1541
1520
  ? backHoverBackground
1542
1521
  : (controlBackground('settings', focusedAction === 'settings') ?? COMMAND_DECK_BACKGROUND), children: _jsx(Text, { color: settingsBackHovered ? palette.muted : focusedAction === 'settings' ? accent : palette.muted, children: isSettings ? 'Back' : 'Settings' }) })) : null;
1543
- if (agentHandoff) {
1544
- const canvasHeight = Math.max(12, height - 2);
1545
- const guideHeight = Math.max(4, height - 4);
1546
- const { wide, frogWidth, frogHeight, contentWidth } = setupGuideLayout(lockupWidth, guideHeight);
1547
- const landingX = wide
1548
- ? Math.max(frogWidth / 2, Math.floor((lockupWidth - contentWidth) / 2) + frogWidth / 2)
1549
- : lockupWidth / 2;
1550
- const landingY = Math.max(7, guideHeight + frogHeight - 16);
1551
- return (_jsx(Box, { width: width, height: height, paddingX: 1, paddingTop: 2, overflow: "hidden", backgroundColor: palette.background, children: _jsx(Text, { children: renderSetupGuideTransitionFrame(lockupWidth, canvasHeight, agentHandoffElapsedMs / SETUP_GUIDE_TRANSITION_DURATION_MS, agentHandoffElapsedMs, landingX, true, appearance.frogTheme, {
1552
- colorMode: palette.mode,
1553
- customBase: appearance.customTheme.base,
1554
- ...(appearance.frogTheme === 'custom' ? { frogColor: palette.frog } : {}),
1555
- }, landingY) }) }));
1556
- }
1557
1522
  return (_jsxs(Box, { width: width, height: height, paddingX: 1, flexDirection: "column", overflow: "hidden", backgroundColor: palette.background, children: [showBrand ? (_jsx(SetupBrand, { frame: brandFrame, appearance: appearance, animationId: frogAnimationId, elapsedMs: frogElapsedMs, onFrogElement: (element) => {
1558
1523
  frogElement.current = element ?? undefined;
1559
- } })) : null, step === 0 ? (_jsx(Fade, { background: palette.background, progress: panelTransition.progress, children: _jsx(OpeningMenu, { width: lockupWidth, buttonHeight: openingButtonHeight, selection: selection, showSelection: openingSelectionVisible, ...(typeof hoveredControl === 'number' ? { hovered: hoveredControl } : {}), topGap: openingTopGap, animate: appearance.animations, ...(error ? { error } : {}), onRowElement: (index, element) => registerElement(rowElements.current, index, element) }) })) : null, step === 0 ? null : (_jsx(Fade, { background: palette.background, progress: panelTransition.progress, children: _jsxs(Box, { flexGrow: 1, alignItems: "center", justifyContent: "center", flexDirection: "column", overflow: "hidden", children: [progress ? (_jsxs(Box, { width: bubbleWidth, marginBottom: 1, alignItems: "center", flexDirection: "column", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, wrap: "truncate-end", children: progress.instruction }), _jsx(SetupProgress, { current: progress.current, total: progress.total, width: Math.min(bubbleWidth, 48), animate: appearance.animations })] })) : null, _jsxs(Box, { width: bubbleWidth, height: bubbleHeight, flexDirection: "column", overflow: "hidden", backgroundColor: PANEL_BACKGROUND, children: [!isAppearance && flow === 'manual' && !isProviderSetup && !isCapabilities ? (_jsxs(Box, { paddingX: 1, marginBottom: 1, justifyContent: "space-between", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, children: isSettings ? 'Settings' : isAppearance ? 'Appearance' : MANUAL_STEPS[step - 1] }), manualOverflowLabel ? _jsx(Text, { dimColor: true, children: manualOverflowLabel }) : null] })) : null, isCapabilities ? (_jsxs(_Fragment, { children: [_jsxs(Box, { paddingX: 1, marginBottom: 1, justifyContent: "space-between", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, children: isTools ? 'Tools' : 'Plugins & features' }), _jsx(Box, { ref: (element) => registerElement(rowElements.current, 0, element), paddingX: 1, backgroundColor: rowBackground(0) ?? COMMAND_DECK_BACKGROUND, children: _jsx(Text, { bold: true, children: rows[0].label }) })] }), renderCapabilityRows(visibleCapabilityRows)] })) : isImport ? (_jsxs(Box, { flexGrow: 1, paddingX: 2, paddingY: 1, flexDirection: "column", overflow: "hidden", children: [_jsx(Text, { bold: true, wrap: "truncate-end", children: "Import an agent" }), _jsx(Box, { marginTop: 1, children: _jsx(Text, { bold: true, ...(selection === 0 ? { color: accent } : {}), wrap: "truncate-end", children: "Path to ZIP, file, or folder" }) }), _jsxs(Box, { height: 3, flexDirection: "row", children: [_jsx(Box, { ref: (element) => registerElement(rowElements.current, 0, element), flexGrow: 1, paddingX: 1, flexDirection: "column", justifyContent: "center", backgroundColor: rowBackground(0) ?? COMMAND_DECK_BACKGROUND, children: _jsx(EditableText, { value: editing?.field === 'importPath' ? editing.value : importPath, cursor: editing?.field === 'importPath'
1524
+ } })) : null, step === 0 ? (_jsx(Fade, { background: palette.background, progress: panelTransition.progress, children: _jsx(OpeningMenu, { width: lockupWidth, buttonHeight: openingButtonHeight, selection: selection, showSelection: openingSelectionVisible, ...(typeof hoveredControl === 'number' ? { hovered: hoveredControl } : {}), topGap: openingTopGap, animate: appearance.animations, ...(error ? { error } : {}), ...(availableUpdate ? { availableUpdate } : {}), onRowElement: (index, element) => registerElement(rowElements.current, index, element) }) })) : null, step === 0 ? null : (_jsx(Fade, { background: palette.background, progress: panelTransition.progress, children: _jsxs(Box, { flexGrow: 1, alignItems: "center", justifyContent: "center", flexDirection: "column", overflow: "hidden", children: [progress ? (_jsxs(Box, { width: bubbleWidth, marginBottom: 1, alignItems: "center", flexDirection: "column", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, wrap: "truncate-end", children: progress.instruction }), _jsx(SetupProgress, { current: progress.current, total: progress.total, ...(progress.label ? { label: progress.label } : {}), width: Math.min(bubbleWidth, 48), animate: appearance.animations })] })) : null, _jsxs(Box, { width: bubbleWidth, height: bubbleHeight, flexDirection: "column", overflow: "hidden", backgroundColor: PANEL_BACKGROUND, children: [!isAppearance && flow === 'customize' && !isProviderSetup && !isCapabilities ? (_jsxs(Box, { paddingX: 1, marginBottom: 1, justifyContent: "space-between", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, children: isSettings ? 'Settings' : isAppearance ? 'Appearance' : CUSTOMIZE_STEPS[step - 1] }), customizeOverflowLabel ? _jsx(Text, { dimColor: true, children: customizeOverflowLabel }) : null] })) : null, isCapabilities ? (_jsxs(_Fragment, { children: [_jsxs(Box, { paddingX: 1, marginBottom: 1, justifyContent: "space-between", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, children: isTools ? 'Tools' : 'Plugins & features' }), _jsx(Box, { ref: (element) => registerElement(rowElements.current, 0, element), paddingX: 1, backgroundColor: rowBackground(0) ?? COMMAND_DECK_BACKGROUND, children: _jsx(Text, { bold: true, children: rows[0].label }) })] }), renderCapabilityRows(visibleCapabilityRows)] })) : isImport ? (_jsxs(Box, { flexGrow: 1, paddingX: 2, paddingY: 1, flexDirection: "column", overflow: "hidden", children: [_jsx(Text, { bold: true, wrap: "truncate-end", children: "Import an agent" }), _jsx(Box, { marginTop: 1, children: _jsx(Text, { bold: true, ...(selection === 0 ? { color: accent } : {}), wrap: "truncate-end", children: "Path to ZIP, file, or folder" }) }), _jsxs(Box, { height: 3, flexDirection: "row", children: [_jsx(Box, { ref: (element) => registerElement(rowElements.current, 0, element), flexGrow: 1, paddingX: 1, flexDirection: "column", justifyContent: "center", backgroundColor: rowBackground(0) ?? COMMAND_DECK_BACKGROUND, children: _jsx(EditableText, { value: editing?.field === 'importPath' ? editing.value : importPath, cursor: editing?.field === 'importPath'
1560
1525
  ? (editing.cursor ?? graphemes(editing.value).length)
1561
1526
  : graphemes(importPath).length, width: Math.max(1, bubbleWidth - (canChooseDirectory() ? 17 : 6)), active: editing?.field === 'importPath', animate: appearance.animations }) }), canChooseDirectory() ? (_jsx(Box, { ref: (element) => registerElement(rowElements.current, 1, element), width: 12, marginLeft: 1, alignItems: "center", justifyContent: "center", backgroundColor: controlBackground(1, focusedAction === undefined && selection === 1, choosingDirectory) ??
1562
1527
  COMMAND_DECK_BACKGROUND, children: _jsx(Text, { bold: true, ...(selection === 1 && !choosingDirectory ? { color: accent } : {}), dimColor: choosingDirectory, children: choosingDirectory ? 'Opening...' : 'Browse' }) })) : null] }), pathEditing && importCompletionCapacity > 0 ? (_jsxs(Box, { flexDirection: "column", flexShrink: 0, children: [_jsx(Box, { paddingX: 1, height: 1, flexShrink: 0, children: _jsx(Text, { dimColor: true, wrap: "truncate-end", children: "Suggestions \u00B7 \u2191\u2193 choose \u00B7 Tab complete" }) }), pathCompletions.slice(0, importCompletionCapacity).map((completion, index) => (_jsx(Box, { ref: (element) => registerElement(pathCompletionElements.current, index, element), height: 1, paddingX: 1, flexShrink: 0, backgroundColor: pathCompletionIndex === index || hoveredControl === `completion:${index}`
@@ -1572,7 +1537,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1572
1537
  ? { hovered: PROVIDER_IDS[hoveredControl] }
1573
1538
  : {}), onElement: (id, element) => registerElement(rowElements.current, PROVIDER_IDS.indexOf(id), element) }) }), _jsx(Box, { flexGrow: 1 }), refreshRow ? renderRefreshButton(refreshRow, quickstartProviderColumnWidth - 2, true) : null] }), _jsx(Box, { width: quickstartDetailColumnWidth, flexGrow: 1, flexShrink: 0, paddingX: 1, flexDirection: "column", overflow: "hidden", children: showProviderConfiguration ? (_jsxs(_Fragment, { children: [middleFacts.length > 0 || middleWarningLines.length > 0 ? (_jsxs(Box, { paddingX: 1, marginBottom: middleFieldGap, flexShrink: 0, flexDirection: "column", children: [middleFacts.map((fact) => (_jsxs(Box, { children: [_jsxs(Text, { dimColor: true, children: [fact.label, ": "] }), _jsx(Text, { bold: true, color: palette[fact.status], children: fact.value })] }, fact.label))), middleWarningLines.length > 0 ? (_jsx(Box, { marginTop: middleFacts.length > 0 ? 1 : 0, children: _jsx(Text, { color: palette[providerWarningStatus], children: middleWarningLines.join('\n') }) })) : null] })) : null, selecting
1574
1539
  ? renderProviderSelect(selecting)
1575
- : visibleProviderFieldRows.map((row) => renderProviderField(row, quickstartDetailColumnWidth - 3))] })) : (_jsxs(Box, { flexGrow: 1, flexDirection: showReasoningPanel ? 'row' : 'column', overflow: "hidden", children: [_jsxs(Box, { ref: modelListElement, flexGrow: 1, flexDirection: "column", overflow: "hidden", children: [_jsx(Box, { flexShrink: 0, children: _jsx(Text, { bold: true, color: accent, children: "Models" }) }), _jsx(Box, { ref: modelSearchElement, marginBottom: 1, flexShrink: 0, backgroundColor: controlBackground('search', modelSearchFocused), children: _jsx(Text, { wrap: "truncate-end", children: modelSearchFocused ? (_jsxs(_Fragment, { children: [modelQuery, _jsx(BlinkingCursor, { animate: appearance.animations })] })) : (_jsxs(Text, { dimColor: true, children: ["/ ", modelQuery || 'Search models'] })) }) }), showModelPagination ? (_jsx(Box, { ref: modelPreviousElement, width: "100%", height: 1, paddingX: 1, flexShrink: 0, backgroundColor: controlBackground('models-previous', false) ?? COMMAND_DECK_BACKGROUND, children: _jsxs(Text, { ...(previousModelCount > 0
1540
+ : visibleProviderFieldRows.map((row) => renderProviderField(row, quickstartDetailColumnWidth - 3))] })) : (_jsxs(Box, { flexGrow: 1, flexDirection: showModelOptionsPanel ? 'row' : 'column', overflow: "hidden", children: [_jsxs(Box, { ref: modelListElement, flexGrow: 1, flexDirection: "column", overflow: "hidden", children: [_jsx(Box, { flexShrink: 0, children: _jsx(Text, { bold: true, color: accent, children: "Models" }) }), _jsx(Box, { ref: modelSearchElement, marginBottom: 1, flexShrink: 0, backgroundColor: controlBackground('search', modelSearchFocused), children: _jsx(Text, { wrap: "truncate-end", children: modelSearchFocused ? (_jsxs(_Fragment, { children: [modelQuery, _jsx(BlinkingCursor, { animate: appearance.animations })] })) : (_jsxs(Text, { dimColor: true, children: ["/ ", modelQuery || 'Search models'] })) }) }), showModelPagination ? (_jsx(Box, { ref: modelPreviousElement, width: "100%", height: 1, paddingX: 1, flexShrink: 0, backgroundColor: controlBackground('models-previous', false) ?? COMMAND_DECK_BACKGROUND, children: _jsxs(Text, { ...(previousModelCount > 0
1576
1541
  ? {
1577
1542
  color: hoveredControl === 'models-previous' ? accent : palette.muted,
1578
1543
  bold: hoveredControl === 'models-previous',
@@ -1587,18 +1552,20 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1587
1552
  const highlighted = focused || hovered;
1588
1553
  const harnessDefault = model.id === quickstartDefaultModel;
1589
1554
  const modelSpecifier = `${quickstartProvider}/${model.id}`;
1590
- return (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), width: "100%", height: quickstartModelRowHeight, paddingX: 1, flexShrink: 0, overflow: "hidden", backgroundColor: rowBackground(index) ?? (active ? COMMAND_DECK_BACKGROUND : undefined), children: [_jsx(Box, { width: 2, flexShrink: 0, children: _jsx(Text, { ...(active || highlighted ? { color: accent, bold: true } : {}), children: active ? '✓ ' : highlighted ? '› ' : ' ' }) }), _jsx(Box, { ...(showReasoningPanel
1555
+ return (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), width: "100%", height: quickstartModelRowHeight, paddingX: 1, flexShrink: 0, overflow: "hidden", backgroundColor: rowBackground(index) ?? (active ? COMMAND_DECK_BACKGROUND : undefined), children: [_jsx(Box, { width: 2, flexShrink: 0, children: _jsx(Text, { ...(active || highlighted ? { color: accent, bold: true } : {}), children: active ? '✓ ' : highlighted ? '› ' : ' ' }) }), _jsx(Box, { ...(showModelOptionsPanel
1591
1556
  ? { flexGrow: 1 }
1592
- : { width: quickstartModelNameWidth, flexShrink: 0 }), overflow: "hidden", children: _jsxs(Text, { ...(active || highlighted ? { color: accent, bold: true } : {}), wrap: "truncate-end", children: [model.name, harnessDefault ? _jsx(Text, { color: accent, children: " \u2605" }) : null] }) }), !showReasoningPanel ? (_jsxs(_Fragment, { children: [_jsx(Box, { width: 1, flexShrink: 0 }), _jsx(Box, { width: quickstartModelIdWidth, flexShrink: 0, overflow: "hidden", children: _jsx(Text, { dimColor: true, wrap: "truncate-end", children: modelSpecifier }) })] })) : null] }, model.id));
1557
+ : { width: quickstartModelNameWidth, flexShrink: 0 }), overflow: "hidden", children: _jsxs(Text, { ...(active || highlighted ? { color: accent, bold: true } : {}), wrap: "truncate-end", children: [model.name, harnessDefault ? _jsx(Text, { color: accent, children: " \u2605" }) : null] }) }), !showModelOptionsPanel ? (_jsxs(_Fragment, { children: [_jsx(Box, { width: 1, flexShrink: 0 }), _jsx(Box, { width: quickstartModelIdWidth, flexShrink: 0, overflow: "hidden", children: _jsx(Text, { dimColor: true, wrap: "truncate-end", children: modelSpecifier }) })] })) : null] }, model.id));
1593
1558
  }) })) }), showModelPagination ? (_jsx(Box, { ref: modelNextElement, width: "100%", height: 1, paddingX: 1, flexShrink: 0, backgroundColor: controlBackground('models-next', false) ?? COMMAND_DECK_BACKGROUND, children: _jsxs(Text, { ...(nextModelCount > 0
1594
1559
  ? {
1595
1560
  color: hoveredControl === 'models-next' ? accent : palette.muted,
1596
1561
  bold: hoveredControl === 'models-next',
1597
1562
  }
1598
- : { dimColor: true }), children: ["\u2193 Next", nextModelCount > 0 ? ` · ${nextModelCount} more` : ''] }) })) : null, readyProviderControlRows.length > 0 ? (_jsx(Box, { flexShrink: 0, flexDirection: "column", children: readyProviderControlRows.map((row) => renderProviderField(row, quickstartDetailColumnWidth - (showReasoningPanel ? 36 : 3))) })) : null] }), showReasoningPanel ? (_jsxs(Box, { width: 32, marginLeft: 1, paddingLeft: 1, flexDirection: "column", flexShrink: 0, children: [_jsx(Text, { bold: true, color: accent, children: "Reasoning" }), _jsx(EffortSlider, { slider: reasoningSlider, width: 26, compact: false, pressed: false, focused: reasoningRowIndex === selection, onElement: (element) => {
1599
- setupEffortSliderElement.current = element;
1600
- registerElement(rowElements.current, reasoningRowIndex, element);
1601
- } })] })) : null] })) })] })) : isAppearance ? (_jsx(SetupSettingsPanel, { rows: visibleRows, category: settingsCategory, settings: { ...panelSettings, ...draft.settings, ...appearance }, start: viewportStart, selected: selection, width: bubbleWidth, height: bubbleHeight, ...(typeof hoveredControl === 'string' ? { hoveredControl } : {}), onRowElement: (index, element) => registerElement(rowElements.current, index, element), onChoiceElement: (target, element) => registerElement(choiceElements.current, target, element) })) : isPermissions ? (_jsxs(Box, { flexGrow: 1, paddingX: 1, flexDirection: "column", overflow: "hidden", children: [_jsx(Box, { height: 7, flexShrink: 0, children: rows.slice(0, 3).map((row, index) => (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), flexGrow: 1, flexBasis: 0, height: 7, marginRight: index < 2 ? 1 : 0, paddingX: 1, borderStyle: "single", borderColor: index === selection ? accent : row.active ? palette.success : palette.muted, flexDirection: "column", justifyContent: "center", backgroundColor: rowBackground(index), children: [_jsxs(Text, { bold: true, color: row.active || index === selection ? accent : palette.foreground, children: [row.active ? '◆ ' : '', row.label] }), _jsx(Text, { dimColor: true, wrap: "wrap", children: row.description })] }, row.id))) }), draft.customPermissions ? (_jsxs(Box, { marginTop: 1, flexGrow: 1, flexDirection: "column", overflow: "hidden", children: [_jsxs(Box, { justifyContent: "space-between", flexShrink: 0, children: [_jsx(Text, { bold: true, children: "Per-tool behavior" }), _jsxs(Text, { dimColor: true, children: [permissionViewportStart > 3 ? `↑ ${permissionViewportStart - 3} ` : '', permissionViewportStart + visiblePermissionTools.length < rows.length
1563
+ : { dimColor: true }), children: ["\u2193 Next", nextModelCount > 0 ? ` · ${nextModelCount} more` : ''] }) })) : null, readyProviderControlRows.length > 0 ? (_jsx(Box, { flexShrink: 0, flexDirection: "column", children: readyProviderControlRows.map((row) => row.id === 'quickstart-web-search'
1564
+ ? renderQuickstartWebSearch(row, false)
1565
+ : renderProviderField(row, quickstartDetailColumnWidth - (showModelOptionsPanel ? 36 : 3))) })) : null] }), showModelOptionsPanel ? (_jsxs(Box, { width: 32, marginLeft: 1, paddingLeft: 1, flexDirection: "column", flexShrink: 0, overflow: "hidden", children: [showReasoningPanel ? (_jsxs(_Fragment, { children: [_jsx(Text, { bold: true, color: accent, children: "Reasoning" }), _jsx(EffortSlider, { slider: reasoningSlider, width: 26, compact: false, pressed: false, focused: reasoningRowIndex === selection, onElement: (element) => {
1566
+ setupEffortSliderElement.current = element;
1567
+ registerElement(rowElements.current, reasoningRowIndex, element);
1568
+ } })] })) : null, webSearchRow ? (_jsx(Box, { marginTop: showReasoningPanel ? 1 : 0, flexShrink: 0, children: renderQuickstartWebSearch(webSearchRow, true) })) : null] })) : null] })) })] })) : isAppearance ? (_jsx(SetupSettingsPanel, { rows: visibleRows, category: settingsCategory, settings: { ...panelSettings, ...draft.settings, ...appearance }, start: viewportStart, selected: selection, width: bubbleWidth, height: bubbleHeight, ...(typeof hoveredControl === 'string' ? { hoveredControl } : {}), onRowElement: (index, element) => registerElement(rowElements.current, index, element), onChoiceElement: (target, element) => registerElement(choiceElements.current, target, element) })) : isPermissions ? (_jsxs(Box, { flexGrow: 1, paddingX: 1, flexDirection: "column", overflow: "hidden", children: [_jsx(Box, { height: 7, flexShrink: 0, children: rows.slice(0, 3).map((row, index) => (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), flexGrow: 1, flexBasis: 0, height: 7, marginRight: index < 2 ? 1 : 0, paddingX: 1, borderStyle: "single", borderColor: index === selection ? accent : row.active ? palette.success : palette.muted, flexDirection: "column", justifyContent: "center", backgroundColor: rowBackground(index), children: [_jsxs(Text, { bold: true, color: row.active || index === selection ? accent : palette.foreground, children: [row.active ? '◆ ' : '', row.label] }), _jsx(Text, { dimColor: true, wrap: "wrap", children: row.description })] }, row.id))) }), draft.customPermissions ? (_jsxs(Box, { marginTop: 1, flexGrow: 1, flexDirection: "column", overflow: "hidden", children: [_jsxs(Box, { justifyContent: "space-between", flexShrink: 0, children: [_jsx(Text, { bold: true, children: "Per-tool behavior" }), _jsxs(Text, { dimColor: true, children: [permissionViewportStart > 3 ? `↑ ${permissionViewportStart - 3} ` : '', permissionViewportStart + visiblePermissionTools.length < rows.length
1602
1569
  ? `↓ ${rows.length - permissionViewportStart - visiblePermissionTools.length}`
1603
1570
  : ''] })] }), visiblePermissionTools.map((row, visibleIndex) => {
1604
1571
  const index = permissionViewportStart + visibleIndex;
@@ -1619,7 +1586,7 @@ function SetupWizardContent({ appearance, setAppearance, config, deferred = fals
1619
1586
  ], selected: quickstartProvider, width: bubbleWidth, rowHeight: rowHeight, selectedBackground: true, ...(hoveredControl === index ? { hovered: row.id } : {}), onElement: (_, element) => registerElement(rowElements.current, index, element) }, row.id));
1620
1587
  }
1621
1588
  const activeEditing = editing?.field === row.field ? editing : undefined;
1622
- return (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), paddingX: row.field ? 0 : 1, height: rowHeight, flexShrink: 0, flexDirection: "column", backgroundColor: row.field ? undefined : rowBackground(index), children: [_jsxs(Box, { paddingX: row.field ? 1 : 0, justifyContent: "space-between", flexShrink: 0, children: [_jsxs(Text, { bold: row.field !== undefined, ...(!row.disabled && index === selection ? { color: accent } : {}), dimColor: row.disabled === true, wrap: "truncate-end", children: [row.status ? (_jsx(Text, { color: palette[row.status], children: "\u25CF " })) : row.field ? ('') : row.active === undefined ? ('') : row.active ? ('☑ ') : ('☐ '), row.label, flow === 'manual' && step === MANUAL_STEPS.length ? ' →' : ''] }), directoryRows.has(index) ? (_jsx(Box, { ref: (element) => registerElement(directoryElements.current, index, element), paddingX: 1, flexShrink: 0, backgroundColor: controlBackground(`browse:${index}`, focusedAction === `browse:${index}`) ??
1589
+ return (_jsxs(Box, { ref: (element) => registerElement(rowElements.current, index, element), paddingX: row.field ? 0 : 1, height: rowHeight, flexShrink: 0, flexDirection: "column", backgroundColor: row.field ? undefined : rowBackground(index), children: [_jsxs(Box, { paddingX: row.field ? 1 : 0, justifyContent: "space-between", flexShrink: 0, children: [_jsxs(Text, { bold: row.field !== undefined, ...(!row.disabled && index === selection ? { color: accent } : {}), dimColor: row.disabled === true, wrap: "truncate-end", children: [row.status ? (_jsx(Text, { color: palette[row.status], children: "\u25CF " })) : row.field ? ('') : row.active === undefined ? ('') : row.active ? ('☑ ') : ('☐ '), row.label, flow === 'customize' && step === CUSTOMIZE_STEPS.length ? ' →' : ''] }), directoryRows.has(index) ? (_jsx(Box, { ref: (element) => registerElement(directoryElements.current, index, element), paddingX: 1, flexShrink: 0, backgroundColor: controlBackground(`browse:${index}`, focusedAction === `browse:${index}`) ??
1623
1590
  COMMAND_DECK_BACKGROUND, children: _jsx(Text, { bold: true, children: choosingDirectory && focusedAction === `browse:${index}` ? 'Opening...' : 'Browse' }) })) : null] }), row.choices?.length ? (renderChoices(row.choices, index)) : row.field ? (_jsx(Box, { flexGrow: 1, paddingX: 1, flexDirection: "column", justifyContent: row.field === 'instructions' ? 'flex-start' : 'center', backgroundColor: rowBackground(index) ?? COMMAND_DECK_BACKGROUND, children: _jsx(EditableText, { value: activeEditing?.value ?? row.description, cursor: activeEditing
1624
1591
  ? (activeEditing.cursor ?? graphemes(activeEditing.value).length)
1625
1592
  : graphemes(row.description).length, width: Math.max(1, bubbleWidth - 4), maxRows: row.field === 'instructions' ? rowHeight - 2 : 1, active: Boolean(activeEditing), animate: appearance.animations }) })) : (_jsx(Text, { ...(row.descriptionColor