/**
 * Slash-menu UI labels — i18n is the host's job. Pass overrides via
 * the `<SlashMenu labels={...}>` prop. Strings are kept short so the
 * empty-state line stays on one row in narrow composers.
 */

export interface SlashMenuLabels {
  /** Empty-state line. `{query}` is replaced with the user's filter. */
  emptyState: string;
}

export const DEFAULT_SLASH_LABELS: SlashMenuLabels = {
  emptyState: 'No commands match "{query}"',
};

/** Substitute `{query}` placeholders in a label template. */
export function formatEmptyState(template: string, query: string): string {
  return template.replace('{query}', query);
}
