github charmbracelet/bubbles v0.17.0

latest releases: v2.0.0-alpha.2, v2.0.0-alpha.1, v0.20.0...
11 months ago

Text input autocompletions and various improvements

Autocompletion in Text Input

So @toadle wanted textinputs to support autocompletion in a ghost-text kind of a way. Rather than wait for us to do it he did what any dedicated open source developer would: he sent a PR! And now we can all benefit from his hard work.

Autocompletion is super easy to use:

ti := textinput.New()
ti.SetSuggestions([]string{"meow", "purr"})

By default you can press ctrl+n and ctrl+p to cycle through suggestions, but those keybindings can be changed as you, the application developer, see fit. For details check out textinput.SetSuggestions and the corresponding KeyMap in the docs.

Is the progress bar done yet?

@yrashk acutely noticed that to nicely transition from one state to another after an animated progress bar fills up it's helpful to know when the animated has finished animating before transitioning. To solve for this he added an IsAnimating method to the progress model. Thanks, @yrashk!

Changelog

New!

  • Support suggestions and autocompletion in textinput by @toadle in #407
  • Add method for determining if progress bar is animating by @yrashk in #386

Improved

Fixed

Full Changelog: v0.16.1...v0.17.0

New Contributors


The Charm logo

Thoughts? Questions? We love hearing from you. Feel free to reach out on Twitter, The Fediverse, or on Discord.

Don't miss a new bubbles release

NewReleases is sending notifications on new releases.