diff --git a/src/cli/components/ApprovalDialogRich.tsx b/src/cli/components/ApprovalDialogRich.tsx index aeba33e..dd05214 100644 --- a/src/cli/components/ApprovalDialogRich.tsx +++ b/src/cli/components/ApprovalDialogRich.tsx @@ -82,6 +82,23 @@ const DynamicPreview: React.FC = ({ ); } + if (t === "ls") { + const pathVal = parsedArgs?.path; + const path = typeof pathVal === "string" ? pathVal : "(current directory)"; + const ignoreVal = parsedArgs?.ignore; + const ignore = + Array.isArray(ignoreVal) && ignoreVal.length > 0 + ? ` (ignoring: ${ignoreVal.join(", ")})` + : ""; + + return ( + + List files in: {path} + {ignore ? {ignore} : null} + + ); + } + // File edit previews: write/edit/multi_edit if ((t === "write" || t === "edit" || t === "multiedit") && parsedArgs) { try {