MCPcopy Create free account
hub / github.com/OpenHands/OpenHands / commitMidKeypress

Function commitMidKeypress

__tests__/components/chat/chat-interface.test.tsx:1517–1523  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1515 // shortcut, and the browser commits the composer's keydown update between
1516 // listeners. Commit a re-render at that point.
1517 const commitMidKeypress = () => {
1518 flushSync(() => {
1519 useConversationStore.setState({
1520 planContent: "# Plan\n\n- step one\n- step two",
1521 });
1522 });
1523 };
1524 document.addEventListener("keydown", commitMidKeypress, { once: true });
1525 renderInterface();
1526 const composer = screen.getByTestId("chat-input");

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected