chore: update module github.com/charmbracelet/bubbles to v0.21.0 #47

Merged
smark merged 1 commit from renovate/github.com-charmbracelet-bubbles-0.x into main 2025-04-15 05:38:45 +00:00
Owner

This PR contains the following updates:

Package Type Update Change
github.com/charmbracelet/bubbles require minor v0.20.0 -> v0.21.0

See https://eol301.grasky.net/github.com/charmbracelet/bubbles for EOL dates and support lifecycles.


Release Notes

charmbracelet/bubbles (github.com/charmbracelet/bubbles)

v0.21.0

Compare Source

Viewport improvements

Finally, viewport finally has horizontal scrolling ![^v1]
To enable it, use SetHorizontalStep (default in v2 will be 6).

You can also scroll manually with ScrollLeft and ScrollRight, and use
SetXOffset to scroll to a specific position (or 0 to reset):

vp := viewport.New()
vp.SetHorizontalStep(10) // how many columns to scroll on each key press
vp.ScrollRight(30)       // pan 30 columns to the right!
vp.ScrollLeft(10)        // pan 10 columns to the left!
vp.SetXOffset(0)         // back to the left edge

To make the API more consistent, vertical scroll functions were also renamed,
and the old ones were deprecated (and will be removed in v2):

// Scroll n lines up/down:
func (m Model) LineUp(int)     // deprecated
func (m Model) ScrollUp(int)   // new!
func (m Model) LineDown(int)   // deprecated
func (m Model) ScrollDown(int) // new!

// Scroll half page up/down:
func (m Model) HalfViewUp() []string   // deprecated
func (m Model) HalfPageUp() []string   // new!
func (m Model) HalfViewDown() []string // deprecated
func (m Model) HalfPageDown() []string // new!

// Scroll a full page up/down:
func (m Model) ViewUp(int) []string   // deprecated
func (m Model) PageUp(int) []string   // new!
func (m Model) ViewDown(int) []string // deprecated
func (m Model) PageDown(int) []string // new!

[!NOTE]
In v2, these functions will not return lines []string anymore, as it is no
longer needed due to HighPerformanceRendering being deprecated as well.

Other improvements

The list bubble got a couple of new functions: SetFilterText,
SetFilterState, and GlobalIndex - which you can use to get the index of the
item in the unfiltered, original item list.

On textinput, you can now get the matched suggestions and more with
MatchedSuggestions and CurrentSuggestionIndex.

To put the cherry on top, this release also includes numerous bug fixes.
You can read about each of them in the linked commits/PRs below.

[^v1]: It is disabled by default in v1, but will be enabled in v2.

Changelog

New Features
Bug fixes
Dependency updates
Documentation updates
Other work

The Charm logo

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


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot.

This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [github.com/charmbracelet/bubbles](https://github.com/charmbracelet/bubbles) | require | minor | `v0.20.0` -> `v0.21.0` | :hourglass: See https://eol301.grasky.net/github.com/charmbracelet/bubbles for EOL dates and support lifecycles. --- ### Release Notes <details> <summary>charmbracelet/bubbles (github.com/charmbracelet/bubbles)</summary> ### [`v0.21.0`](https://github.com/charmbracelet/bubbles/releases/tag/v0.21.0) [Compare Source](https://github.com/charmbracelet/bubbles/compare/v0.20.0...v0.21.0) #### Viewport improvements Finally, `viewport` finally has *horizontal scrolling* ✨!\[^v1] To enable it, use `SetHorizontalStep` (default in v2 will be `6`). You can also scroll manually with `ScrollLeft` and `ScrollRight`, and use `SetXOffset` to scroll to a specific position (or `0` to reset): ```go vp := viewport.New() vp.SetHorizontalStep(10) // how many columns to scroll on each key press vp.ScrollRight(30) // pan 30 columns to the right! vp.ScrollLeft(10) // pan 10 columns to the left! vp.SetXOffset(0) // back to the left edge ``` To make the API more consistent, vertical scroll functions were also renamed, and the old ones were deprecated (and will be removed in v2): ```go // Scroll n lines up/down: func (m Model) LineUp(int) // deprecated func (m Model) ScrollUp(int) // new! func (m Model) LineDown(int) // deprecated func (m Model) ScrollDown(int) // new! // Scroll half page up/down: func (m Model) HalfViewUp() []string // deprecated func (m Model) HalfPageUp() []string // new! func (m Model) HalfViewDown() []string // deprecated func (m Model) HalfPageDown() []string // new! // Scroll a full page up/down: func (m Model) ViewUp(int) []string // deprecated func (m Model) PageUp(int) []string // new! func (m Model) ViewDown(int) []string // deprecated func (m Model) PageDown(int) []string // new! ``` > \[!NOTE] > In v2, these functions will not return `lines []string` anymore, as it is no > longer needed due to `HighPerformanceRendering` being deprecated as well. #### Other improvements The `list` bubble got a couple of new functions: `SetFilterText`, `SetFilterState`, and `GlobalIndex` - which you can use to get the index of the item in the unfiltered, original item list. On `textinput`, you can now get the matched suggestions and more with `MatchedSuggestions` and `CurrentSuggestionIndex`. To put the cherry on top, this release also includes numerous bug fixes. You can read about each of them in the linked commits/PRs below. \[^v1]: It is disabled by default in v1, but will be enabled in v2. #### Changelog ##### New Features - [`d019ed3`](https://github.com/charmbracelet/bubbles/commit/d019ed3cc97e07dfe5e7b30ec15159033fbe6826): feat(list): add SetFilterText and SetFilterState ([#&#8203;335](https://github.com/charmbracelet/bubbles/issues/335)) ([@&#8203;taigrr](https://github.com/taigrr)) - [`171a9d6`](https://github.com/charmbracelet/bubbles/commit/171a9d61a0ce4fff88db8e16d03c3bac3f35f264): feat(list): implement GlobalIndex helper ([#&#8203;574](https://github.com/charmbracelet/bubbles/issues/574)) ([@&#8203;nobe4](https://github.com/nobe4)) - [`4382fdf`](https://github.com/charmbracelet/bubbles/commit/4382fdf1c6cfe18d34615c1e8b94b068022a461a): feat(textinput): expose matched suggestions and index ([@&#8203;luevano](https://github.com/luevano)) - [`2d53a61`](https://github.com/charmbracelet/bubbles/commit/2d53a618a93c9cf2d3dd066d1b913fc6f46084cc): feat(viewport): horizontal scroll ([#&#8203;240](https://github.com/charmbracelet/bubbles/issues/240)) ([@&#8203;tty2](https://github.com/tty2)) - [`ea344ab`](https://github.com/charmbracelet/bubbles/commit/ea344ab907bddf5e8f71cd73b9583b070e8f1b2f): feat(viewport): horizontal scroll with mouse wheel ([#&#8203;761](https://github.com/charmbracelet/bubbles/issues/761)) ([@&#8203;UnseenBook](https://github.com/UnseenBook)) ##### Bug fixes - [`f2434c3`](https://github.com/charmbracelet/bubbles/commit/f2434c374bd0f55ac0d5b3e8261161b97ea41a30): Revert "fix(viewport): normalize method names" ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`8101a34`](https://github.com/charmbracelet/bubbles/commit/8101a3462fd57e0fb9409da787e10aa50341f67a): fix(ci): add lint and lint-sync workflows and update golangci.yml ([#&#8203;651](https://github.com/charmbracelet/bubbles/issues/651)) ([@&#8203;aymanbagabas](https://github.com/aymanbagabas)) - [`54f28b6`](https://github.com/charmbracelet/bubbles/commit/54f28b650198f96080f16c0cba1e480f4457ec0a): fix(filepicker): properly scrolling filepicker ([#&#8203;753](https://github.com/charmbracelet/bubbles/issues/753)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`81d444a`](https://github.com/charmbracelet/bubbles/commit/81d444a207009d0621988c9e08e827aa803ee04e): fix(help): wrong full help sep rendering ([@&#8203;luevano](https://github.com/luevano)) - [`f439d83`](https://github.com/charmbracelet/bubbles/commit/f439d83043fc1aa8a0903429d9901c302b28e654): fix(textarea): max height should not determine max lines ([@&#8203;meowgorithm](https://github.com/meowgorithm)) - [`8b55efb`](https://github.com/charmbracelet/bubbles/commit/8b55efb2944ed8eb81df685f8dcfabbbf8897698): fix(textarea): placeholder with chinese chars ([#&#8203;767](https://github.com/charmbracelet/bubbles/issues/767)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`8624776`](https://github.com/charmbracelet/bubbles/commit/8624776d4572078ae6ff098d454c719047f9eb83): fix(textinput): slicing outside cap ([#&#8203;532](https://github.com/charmbracelet/bubbles/issues/532)) ([@&#8203;MikaelFangel](https://github.com/MikaelFangel)) - [`c7f889e`](https://github.com/charmbracelet/bubbles/commit/c7f889e364e15dc5b08a8c799e80164031847ab9): fix(viewport): normalize method names ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`39668ec`](https://github.com/charmbracelet/bubbles/commit/39668ec6291e1fc3e574f30c650e1ba0801e1f6d): fix(viewport): normalize method names ([#&#8203;763](https://github.com/charmbracelet/bubbles/issues/763)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`7ab08fb`](https://github.com/charmbracelet/bubbles/commit/7ab08fb438e4fa1f7968a00a345399de30d1684c): fix(viewport): scroll to last line when borders ([#&#8203;706](https://github.com/charmbracelet/bubbles/issues/706)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`730f5a2`](https://github.com/charmbracelet/bubbles/commit/730f5a29e29b13ed9d4f9f67acb1722425708524): fix: debounce stopwatch and timer ([@&#8203;meowgorithm](https://github.com/meowgorithm)) - [`bd2a5b0`](https://github.com/charmbracelet/bubbles/commit/bd2a5b0c6a7abc66b8a009d2aded233e6ba02fa4): fix: golangci-lint 2 fixes ([#&#8203;769](https://github.com/charmbracelet/bubbles/issues/769)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`9589cbc`](https://github.com/charmbracelet/bubbles/commit/9589cbc16c537db95188cf65d64bf1825dba3d10): fix: lint issues and disable predeclared linter ([#&#8203;614](https://github.com/charmbracelet/bubbles/issues/614)) ([@&#8203;aymanbagabas](https://github.com/aymanbagabas)) - [`398e92c`](https://github.com/charmbracelet/bubbles/commit/398e92c5ae72b738cd6336a48c85bc21039b8cf8): fix: remove default character limit ([@&#8203;meowgorithm](https://github.com/meowgorithm)) - [`1bdd4c6`](https://github.com/charmbracelet/bubbles/commit/1bdd4c6fb3653943cb6941304c2c74354c4af519): fix: stopwatch.Start() ([#&#8203;707](https://github.com/charmbracelet/bubbles/issues/707)) ([@&#8203;bevicted](https://github.com/bevicted)) - [`9a262e9`](https://github.com/charmbracelet/bubbles/commit/9a262e9b0fc34b27b4f7cf7e60e2c48a7c310696): fix: use atomic for ids ([#&#8203;634](https://github.com/charmbracelet/bubbles/issues/634)) ([@&#8203;caarlos0](https://github.com/caarlos0)) ##### Dependency updates - [`1797ac2`](https://github.com/charmbracelet/bubbles/commit/1797ac268d77f1273ba1bc6bd833f3327ce92c0f): feat(deps): bump github.com/charmbracelet/bubbletea from 1.1.0 to 1.1.1 ([#&#8203;611](https://github.com/charmbracelet/bubbles/issues/611)) ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) - [`a9b780a`](https://github.com/charmbracelet/bubbles/commit/a9b780a96c9796826dcad68ea14f5050d613b1cf): feat(deps): bump github.com/charmbracelet/lipgloss from 0.13.0 to 0.13.1 ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) - [`db3514c`](https://github.com/charmbracelet/bubbles/commit/db3514caa70d35517e566e6b15beaa2c8f3fdb8c): feat(deps): bump github.com/charmbracelet/lipgloss from 0.13.1 to 1.0.0 ([#&#8203;655](https://github.com/charmbracelet/bubbles/issues/655)) ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) - [`43aa82c`](https://github.com/charmbracelet/bubbles/commit/43aa82c87e638221a3e00affd35f300cb2901eac): feat(deps): bump github.com/charmbracelet/x/ansi ([#&#8203;716](https://github.com/charmbracelet/bubbles/issues/716)) ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) - [`c1199d7`](https://github.com/charmbracelet/bubbles/commit/c1199d7be61f7c9224759e9de6d3fc241b91d10c): feat(deps): bump github.com/charmbracelet/x/ansi from 0.2.3 to 0.3.0 ([#&#8203;613](https://github.com/charmbracelet/bubbles/issues/613)) ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) - [`d3ac47d`](https://github.com/charmbracelet/bubbles/commit/d3ac47df46a7801611741e2bde7ff3422e6a8d4c): feat(deps): bump github.com/charmbracelet/x/ansi from 0.3.0 to 0.3.1 ([#&#8203;615](https://github.com/charmbracelet/bubbles/issues/615)) ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) - [`ed14316`](https://github.com/charmbracelet/bubbles/commit/ed14316c61e956ab460707a5db7775696fb477ef): feat(deps): bump github.com/charmbracelet/x/ansi from 0.3.1 to 0.3.2 ([#&#8203;618](https://github.com/charmbracelet/bubbles/issues/618)) ([@&#8203;dependabot](https://github.com/dependabot)\[bot]) ##### Documentation updates - [`cf3f46a`](https://github.com/charmbracelet/bubbles/commit/cf3f46ab316fc263a88a0dfd368011f8868101f5): docs(list): fix grammar in doc comment and README ([#&#8203;627](https://github.com/charmbracelet/bubbles/issues/627)) ([@&#8203;oahshtsua](https://github.com/oahshtsua)) - [`9e5365e`](https://github.com/charmbracelet/bubbles/commit/9e5365e0ec0c4005efc7a3cc47f67941840e4144): docs: add example for ValidateFunc ([#&#8203;705](https://github.com/charmbracelet/bubbles/issues/705)) ([@&#8203;bashbunni](https://github.com/bashbunni)) - [`87a4e45`](https://github.com/charmbracelet/bubbles/commit/87a4e45a58fa5bdad06c03c831aff90b6fe8ab25): docs: additional bubbles ([#&#8203;583](https://github.com/charmbracelet/bubbles/issues/583)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`e3ce11a`](https://github.com/charmbracelet/bubbles/commit/e3ce11a65f9191b02d7606bd222e3b0705737167): docs: update charm & friends blurb ([#&#8203;703](https://github.com/charmbracelet/bubbles/issues/703)) ([@&#8203;bashbunni](https://github.com/bashbunni)) - [`178590b`](https://github.com/charmbracelet/bubbles/commit/178590b4469b2386726cff8da7c479615a746a94): docs: update contributing guidelines ([#&#8203;640](https://github.com/charmbracelet/bubbles/issues/640)) ([@&#8203;bashbunni](https://github.com/bashbunni)) ##### Other work - [`0f9e38c`](https://github.com/charmbracelet/bubbles/commit/0f9e38c9a7217bcd3d04b87c725c20047bc6aa64): Don't render suggestions when textinput is not focused. ([@&#8203;elProxy](https://github.com/elProxy)) - [`e5296a2`](https://github.com/charmbracelet/bubbles/commit/e5296a2b0fd6b4b7db8cb54cc15b99b681b7d949): ci: fix goreleaser config ([#&#8203;668](https://github.com/charmbracelet/bubbles/issues/668)) ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`76433f7`](https://github.com/charmbracelet/bubbles/commit/76433f714329061315a81c98362468def335c1dd): ci: fix linting on windows ([@&#8203;andreynering](https://github.com/andreynering)) - [`d91c9aa`](https://github.com/charmbracelet/bubbles/commit/d91c9aa894a6d861f0c139839593b53cd2b2f729): ci: rm .golangci-soft.yml ([@&#8203;caarlos0](https://github.com/caarlos0)) - [`2f49443`](https://github.com/charmbracelet/bubbles/commit/2f4944346fafb64706fb83d9bfdefea8e22e430c): ci: sync dependabot config ([#&#8203;734](https://github.com/charmbracelet/bubbles/issues/734)) ([@&#8203;charmcli](https://github.com/charmcli)) - [`7a6b190`](https://github.com/charmbracelet/bubbles/commit/7a6b190840c8193adddce23afa79824aac6f3442): ci: sync dependabot config ([#&#8203;736](https://github.com/charmbracelet/bubbles/issues/736)) ([@&#8203;charmcli](https://github.com/charmcli)) - [`d58217b`](https://github.com/charmbracelet/bubbles/commit/d58217bded070d5dba742eccfa9dfe2523f71ee1): ci: sync golangci-lint config ([#&#8203;750](https://github.com/charmbracelet/bubbles/issues/750)) ([@&#8203;github-actions](https://github.com/github-actions)\[bot]) - [`cce8481`](https://github.com/charmbracelet/bubbles/commit/cce848148cbea9e1bc5ca7d2c3d1ef89702db0e4): ci: sync golangci-lint config ([#&#8203;770](https://github.com/charmbracelet/bubbles/issues/770)) ([@&#8203;github-actions](https://github.com/github-actions)\[bot]) - [`0305695`](https://github.com/charmbracelet/bubbles/commit/0305695768261fac9cf3d55a3ac0b79542552c64): ci: test on oldstable and stable go versions, automerge dependabot ([#&#8203;755](https://github.com/charmbracelet/bubbles/issues/755)) ([@&#8203;caarlos0](https://github.com/caarlos0)) *** <a href="https://charm.sh/"><img alt="The Charm logo" src="https://stuff.charm.sh/charm-badge.jpg" width="400"></a> Thoughts? Questions? We love hearing from you. Feel free to reach out on [Twitter](https://twitter.com/charmcli), [The Fediverse](https://mastodon.technology/@&#8203;charm), or on [Discord](https://charm.sh/chat). </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMSIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
renovate-bot added 1 commit 2025-04-10 02:01:36 +00:00
Author
Owner

ℹ Artifact update notice

File name: go.mod

In order to perform the update(s) described in the table above, Renovate ran the go get command, which resulted in the following additional change(s):

  • 1 additional dependency was updated

Details:

Package Change
github.com/charmbracelet/lipgloss v1.0.0 -> v1.1.0
### ℹ Artifact update notice ##### File name: go.mod In order to perform the update(s) described in the table above, Renovate ran the `go get` command, which resulted in the following additional change(s): - 1 additional dependency was updated Details: | **Package** | **Change** | | :---------------------------------- | :------------------- | | `github.com/charmbracelet/lipgloss` | `v1.0.0` -> `v1.1.0` |
smark merged commit 473bc1b334 into main 2025-04-15 05:38:45 +00:00
smark deleted branch renovate/github.com-charmbracelet-bubbles-0.x 2025-04-15 05:38:45 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: pomodoro/ChronoTomato#47
No description provided.