import React from 'react' import { Box, Text, useApp } from 'ink' import { Surface } from '../ui/Surface.js' import { Select } from '../ui/Select.js' import { theme } from '../ui/theme.js' import { Logo } from '../identity/manager/shared/components/Logo.js' import type { ResetPlan } from '../storage/reset.js' export const ResetConfirmView: React.FC<{ plan: ResetPlan onDone: (confirmed: boolean) => void }> = ({ plan, onDone }) => { const { exit } = useApp() const finish = (confirmed: boolean) => { onDone(confirmed) exit() } return (
options={[ { value: 'confirm', label: 'Reset everything', hint: 'Clears local data', bold: true }, { value: 'cancel', label: 'Cancel', hint: 'Leave everything as is' }, ]} hintLayout="inline" initialIndex={1} onSubmit={choice => finish(choice === 'confirm')} onCancel={() => finish(false)} /> ) } const Section: React.FC<{ title: string; color: string; lines: string[] }> = ({ title, color, lines }) => ( {title} {lines.map((line, i) => ( · {line} ))} )