import { XOPC_TUI_HOTKEY_ORDER } from "./xopc-tui-keybindings.js";
import { getTuiKeybindingsPath } from "./tui-keybindings-file.js";
//#region src/tui/format-tui-hotkeys.ts
function formatKeyIds(manager, id) {
	const keys = manager.getKeys(id);
	if (keys.length === 0) return "(not bound)";
	return keys.join(" · ");
}
/** Human-readable shortcut list for `/hotkeys` (resolved keys, pi-style). */
function formatXopcTuiHotkeys(manager) {
	const lines = ["Keyboard shortcuts (resolved):"];
	for (const id of XOPC_TUI_HOTKEY_ORDER) {
		const desc = manager.getDefinition(id).description ?? id;
		lines.push(`  ${formatKeyIds(manager, id)} — ${desc}`);
	}
	lines.push("", `Customize in ${getTuiKeybindingsPath()} (/reload-keybindings to apply).`);
	return lines.join("\n");
}
//#endregion
export { formatXopcTuiHotkeys };

//# sourceMappingURL=format-tui-hotkeys.js.map