Repository navigation
fix(tui): add KeyEvent type to useKeyboard callback (#7441) - #7443
Closed
CasualDeveloper wants to merge 1 commit into
Closed
CasualDeveloper wants to merge 1 commit into
CasualDeveloper wants to merge 1 commit into
Conversation
Contributor
|
The following comment was made by an LLM, it may be inaccurate: No duplicate PRs found |
This was referenced Jan 9, 2026
CasualDeveloper
force-pushed
the
fix/keyevent-stoppropagation-type
branch
8 times, most recently
from
January 14, 2026 08:44
d5492e8 to
1afc9f0
Compare
Contributor
Author
|
@adamdotdevin another quick fix you can merge 👀 |
CasualDeveloper
force-pushed
the
fix/keyevent-stoppropagation-type
branch
5 times, most recently
from
January 17, 2026 10:15
b73fed0 to
3ea6e63
Compare
The useKeyboard callback in dialog.tsx uses evt.stopPropagation(), but TypeScript couldn't verify the method exists because @opentui/solid's jsx-runtime.d.ts imports from ./dist which has loosely typed auto-generated declarations (callback: any). Import KeyEvent from @opentui/core and explicitly annotate the callback parameter to restore proper type checking. Fixes anomalyco#7441
CasualDeveloper
force-pushed
the
fix/keyevent-stoppropagation-type
branch
from
January 17, 2026 10:46
3ea6e63 to
ca303b3
Compare
Contributor
Author
|
Closing as obsolete: confirmed on origin/dev that bun turbo typecheck passes without this change. |
Contributor
Author
|
Closing as obsolete: can’t reproduce on origin/dev anymore; bun turbo typecheck is clean; no action needed. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
KeyEventtype import from@opentui/coreuseKeyboardcallback parameter withKeyEventtype to fix TypeScript errorProblem
The
useKeyboardcallback indialog.tsxusesevt.stopPropagation(), but TypeScript reports:This happens because
@opentui/solid'sjsx-runtime.d.tsimports from./distwhich contains auto-generated declarations withcallback: any, shadowing the properly-typed exports.Solution
Import
KeyEventfrom@opentui/core(which has proper type definitions) and explicitly annotate the callback parameter:Test Plan
bun turbo typecheckpassesFixes #7441