Video wird geladen...
Video konnte nicht geladen werden
OpenTUI Keymap is a host agnostic key/cmd engine for DOM like apps. It allows extreme customisation of a generic core, from key stroke syntax parsing to to command resolution and dispatch behaviour. It composes layers of bindings and commands into a single adaptive dispatch model. Demo link in the... show more
91,447 Aufrufe • vor 5 Monaten •via X (Twitter)
35 Kommentare

Here is the HTML adapter demo, which is also in the OpenTUI repository along with demos for core/react/solid. Full docs are on the opentui website.

what the fuck why are you guys casually building some of the coolest primitives??? like, stop making me want to build for the terminal wtfff

Come to the terminal side harhar!

Attention to detail on another level! This is sick!

Art!

this ever get released? would love to use it

yep it's here and maintained, used by opencode as well

wen rust bindings for opentui Hint: The right answer is “wen u make them nerd”

We'll just rewrite the native core in rust anyway.

Like actually orrrrrr…? I’m trying to rewrite the Turborepo TUI, what’s a young man to do?

Eventually. Opentui has a proper CLI mode now, courtesy of @simonklee. Many other improvements on the way over the coming weeks.

this looks amazing. can we implement app-level modes with this too? like insert/normal? or do we have keep that state separately and manually update the keymapper state? im on my phone, will take a look at the source in a bit.

Will this work on opentui/core ?

The demo in the video is core only. Works with opentui core, solid, and react.

Lfg I was looking for exactly this tbh. Been building this from weeks and was running outta keybinds... seems like this is a perfect fit!!

Not exactly the same but I've been working on this issue for a while. Interesting to see a different approach though.

Cool stuff, I like that it can also bind mouse events.

We'll know if it is really extensible if I can make Emacs keystrokes work 🙂

I have experimented with that, there is a sample addon to for emacs chords. It's far from complete, but should be possible to do everything needed to make it complete as addon.

As someone who's also coming from Vim and has implemented keyboard shortcuts in my apps, this is lovely.

love the animation! 🖤

Plugin layer composition is clean in theory — two plugins shadowing the same key is where dispatch state matters. Claude Code runs every matched hook and you trade it for double-firing footguns.

track name?

Atlas - Camo & Krooked & Christian Kolonovits - Red Bull Symphonic Johann Strauss 2025 Edition

ah, it was familiar somehow. loved that show. thanks

Cool

very cool! bug report: if you press e.g. "space h" while typing in a text box, it triggers the global binding. hopefully that's an easy fix since that's plagued me in opentui before

I actually kept it like that in the demo to test and show fall through when a keystroke cancels a pending sequence, so pressing space twice inserts the space. I can see the confusion though. A production app would not do that and it can be easily controlled.

Ahh gotcha! Ideally there'd be a different way to showcase that since the spacebar acting normally in a text box is a pretty fundamental interaction. Glad to hear it's easily controlled though!

How do you deal with so many different terminals eating random keys? Unified user experience across all that wild west?

very cool of you my guy

wen rust?

I wonder how do use graphics protocol in open tui? Didn't see any example on GitHub. Did you use sixel or other technology in this demo?

The first part of the demo is html in the browser, the second part only uses the renderable tree and some block chars and bg/fg colors, no actual graphics involved.

Nice colors
