MCPcopy Create free account
hub / github.com/Linen-dev/linen.dev / selectNextThread

Function selectNextThread

apps/web/ui/ChannelView/index.tsx:143–152  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

141 }
142
143 function selectNextThread() {
144 const index = threads.findIndex(
145 (thread) => thread.id === currentThreadId
146 );
147 if (index < threads.length - 1) {
148 const threadId = threads[index + 1].id;
149 setCurrentThreadId(threadId);
150 scrollToBottomThread(threadId);
151 }
152 }
153
154 if (currentThreadId && (event.key === 'ArrowUp' || event.key === 'k')) {
155 selectPreviousThread();

Callers 1

onKeyUpFunction · 0.85

Calls 1

scrollToBottomThreadFunction · 0.85

Tested by

no test coverage detected