184
*/
185
export function formatGuardianDenialNotification(summary: IGuardianActionSummary, rationale: string | null): string {
187
>
const header = '**Auto-review denied**';
188
>
const lines: string[] = [
189
>
detail
190
>
? `⚠️ ${header} — ${summary.title}: ${inlineCode(detail)}`
191
>
: `⚠️ ${header} — ${summary.title}`,
192
>
];
193
>
const reason = rationale?.trim();
194
>
if (reason) {
195
>
lines.push('', ...reason.split('\n'));
196
>
}
197
>
const quoted = lines.map(line => (line ? `> ${line}` : '>')).join('\n');
198
>
// Leading blank line separates the blockquote from any preceding Markdown
199
>
// part; trailing newline keeps subsequent model output on its own block.
200
>
return `\n\n${quoted}\n`;
201
>
}