MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / HelpV2

Function HelpV2

source code/components/HelpV2/HelpV2.tsx:22–185  ·  view source on GitHub ↗
(t0)

Source from the content-addressed store, hash-verified

20 commands: Command[];
21};
22export function HelpV2(t0) {
23 const $ = _c(44);
24 const {
25 onClose,
26 commands
27 } = t0;
28 const {
29 rows,
30 columns
31 } = useTerminalSize();
32 const maxHeight = Math.floor(rows / 2);
33 const insideModal = useIsInsideModal();
34 let t1;
35 if ($[0] !== onClose) {
36 t1 = () => onClose("Help dialog dismissed", {
37 display: "system"
38 });
39 $[0] = onClose;
40 $[1] = t1;
41 } else {
42 t1 = $[1];
43 }
44 const close = t1;
45 let t2;
46 if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
47 t2 = {
48 context: "Help"
49 };
50 $[2] = t2;
51 } else {
52 t2 = $[2];
53 }
54 useKeybinding("help:dismiss", close, t2);
55 const exitState = useExitOnCtrlCDWithKeybindings(close);
56 const dismissShortcut = useShortcutDisplay("help:dismiss", "Help", "esc");
57 let antOnlyCommands;
58 let builtinCommands;
59 let t3;
60 if ($[3] !== commands) {
61 const builtinNames = builtInCommandNames();
62 builtinCommands = commands.filter(cmd => builtinNames.has(cmd.name) && !cmd.isHidden);
63 let t4;
64 if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
65 t4 = [];
66 $[7] = t4;
67 } else {
68 t4 = $[7];
69 }
70 antOnlyCommands = t4;
71 t3 = commands.filter(cmd_2 => !builtinNames.has(cmd_2.name) && !cmd_2.isHidden);
72 $[3] = commands;
73 $[4] = antOnlyCommands;
74 $[5] = builtinCommands;
75 $[6] = t3;
76 } else {
77 antOnlyCommands = $[4];
78 builtinCommands = $[5];
79 t3 = $[6];

Callers

nothing calls this directly

Calls 6

useTerminalSizeFunction · 0.85
useIsInsideModalFunction · 0.85
useKeybindingFunction · 0.85
useShortcutDisplayFunction · 0.85
hasMethod · 0.45

Tested by

no test coverage detected