249
}
250
}
252
>
// Fallback: try `<cmd>:<sub>` if a prompt with that combined name exists.
253
>
// Supports the space-form subcommand grammar (e.g. `/chronicle tips` resolves to
254
>
// the `chronicle:tips` prompt) so users don't need to type the colon separator.
255
>
// Checked before bare-command interpretation because `isValidSlashCommandName` is
256
>
// syntactic only — bare `<cmd>` always passes, so we must commit to the longer
257
>
// match here when the discovered prompt list contains it.
258
>
const afterSlash = remainingMessage.slice(full.length);
259
>
const subMatch = afterSlash.match(/^[ \t]+([\p{L}\d_\-\.]+)/u);
260
>
if (subMatch) {
261
const candidate = `${command}:${subMatch[1]}`;
262
if (this.promptsService.hasPromptSlashCommand(candidate)) {