()
| 940 | Background(lipgloss.Color("237")) |
| 941 | |
| 942 | func (m harness) View() string { |
| 943 | if m.state == stateAwaitingApproval && m.approvalDetail != "" { |
| 944 | return m.viewApprovalModal() |
| 945 | } |
| 946 | if m.debugMode == debugDetail && debug.Enabled() { |
| 947 | return m.viewDebugModal() |
| 948 | } |
| 949 | parts := []string{m.viewport.View()} |
| 950 | if debug.Enabled() { |
| 951 | boxStyle := debugBoxStyle |
| 952 | if m.debugFocus { |
| 953 | boxStyle = debugBoxFocusedStyle |
| 954 | } |
| 955 | parts = append(parts, boxStyle.Width(max(m.width-2, 20)).Render(m.debugView.View())) |
| 956 | } |
| 957 | parts = append(parts, m.inputArea()) |
| 958 | return lipgloss.JoinVertical(lipgloss.Left, parts...) |
| 959 | } |
| 960 | |
| 961 | // viewApprovalModal renders the full-screen modal that takes over while |
| 962 | // the user is reviewing a write_file proposal. Same shape as the debug |
no test coverage detected