fix(deps): update module github.com/charmbracelet/bubbles to v0.16.1 - autoclosed
This MR contains the following updates:
Package | Type | Update | Change |
---|---|---|---|
github.com/charmbracelet/bubbles | require | minor |
v0.15.0 -> v0.16.1
|
Release Notes
charmbracelet/bubbles
v0.16.1
📁 🫧
File Picker Bubble This release introduces a brand new filepicker
bubble, new features, and a tonne of bugfixes.
Let us know what you think, ask questions, or just say hello in our Discord.
For a quick start on how to use this bubble, take a look at the Example code.
Getting Started
Create a new file picker and add it to your Bubble Tea model.
picker := filepicker.New()
picker.CurrentDirectory, err = os.UserHomeDir()
if err != nil {
// ...
}
m := model{
picker: picker,
// ...
}
Initialize the file picker in your Model
's Init
function.
func (m model) Init() tea.Cmd {
return tea.Batch(
m.picker.Init(),
// ...
)
}
Update the filepicker as any other bubble in the Update
function.
After the picker.Update
, use the DidSelectFile(msg tea.Msg)
function to perform an action when the user selects a valid file.
You may allow only certain file types to be selected with the AllowedTypes
property and allow directories to be selected with the DirAllowed
property. To see the currently selected file/directory use the Path
property.
var cmd tea.Cmd
m.picker, cmd = m.picker.Update(msg)
// Did the user select a file?
if didSelect, path := m.picker.DidSelectFile(msg); didSelect {
// Get the path of the selected file.
return m, tea.Println("You selected: " + selectedPath)
}
return m, cmd
For the full example on how to use this bubble, take a look at the Example code.
New
- Filepicker: new bubble by @maaslalani in https://github.com/charmbracelet/bubbles/pull/343
- Textarea: max width/height configurable by @knz in https://github.com/charmbracelet/bubbles/pull/370
- Spinner: periods of ellipsis by @meowgorithm in https://github.com/charmbracelet/bubbles/pull/375
- List: infinite scrolling by @jon4hz in https://github.com/charmbracelet/bubbles/pull/316
Fixed
- app would crash if
deleteWordRight
was called at the end of line by @infastin in https://github.com/charmbracelet/bubbles/pull/313 - support pastes that end with a newline character by @knz in https://github.com/charmbracelet/bubbles/pull/314
- data corruption after multi-line input by @knz in https://github.com/charmbracelet/bubbles/pull/318
- Remove unused
BackgroundStyle
in TextInput by @savannahostrowski in https://github.com/charmbracelet/bubbles/pull/341 - add bounds checking to the
SelectedRow
by @MikaelFangel in https://github.com/charmbracelet/bubbles/pull/351 - fix(progress): last gradient color off by one by @residualmind in https://github.com/charmbracelet/bubbles/pull/338
- deprecate
CursorStyle
in favour ofCursor.Style
by @maaslalani in https://github.com/charmbracelet/bubbles/pull/365 - Reset blink only when
CursorBlink
by @remiposo in https://github.com/charmbracelet/bubbles/pull/378
New Contributors
- @infastin made their first contribution in https://github.com/charmbracelet/bubbles/pull/313
- @gzipChrist made their first contribution in https://github.com/charmbracelet/bubbles/pull/332
- @savannahostrowski made their first contribution in https://github.com/charmbracelet/bubbles/pull/341
- @MikaelFangel made their first contribution in https://github.com/charmbracelet/bubbles/pull/351
- @stefanbildl made their first contribution in https://github.com/charmbracelet/bubbles/pull/339
- @residualmind made their first contribution in https://github.com/charmbracelet/bubbles/pull/338
- @bashbunni made their first contribution in https://github.com/charmbracelet/bubbles/pull/359
- @squrki made their first contribution in https://github.com/charmbracelet/bubbles/pull/373
- @remiposo made their first contribution in https://github.com/charmbracelet/bubbles/pull/378
Full Changelog: https://github.com/charmbracelet/bubbles/compare/v0.15.0...v0.16.0
Thoughts? Questions? We love hearing from you. Feel free to reach out on Twitter, The Fediverse, or on Discord.
v0.16.0
Configuration
-
If you want to rebase/retry this MR, check this box
This MR has been generated by Renovate Bot.