Commit graph

109 commits

Author SHA1 Message Date
Ayman Bagabas
ceab368db0
docs(readme): updates for v2 (#1589)
Co-authored-by: Christian Rocha <christian@rocha.is>
2026-02-23 17:36:26 -05:00
Copilot
ed050cd108
refactor: extract terminal capability detection into helper function (#1543)
Co-authored-by: aymanbagabas <3187948+aymanbagabas@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
2025-11-14 14:25:54 -05:00
bashbunni
a806274f62 docs: tidy 2025-05-24 19:39:40 -04:00
Christian Rocha
b152063fd2 fix(tutorials): update basics tutorial per v2 tea.Model changes 2025-05-16 12:26:18 -04:00
Ayman Bagabas
598ccb5639
chore: upgrade dependencies 2025-05-16 12:10:40 -04:00
Ayman Bagabas
6d9c955952
chore: tutorials: bump x/input 2025-05-09 10:44:40 -04:00
Carlos Alexandro Becker
e6e72e5510
docs: fix tutorial 2025-03-25 15:50:35 -03:00
Carlos Alexandro Becker
325865a05d
chore(deps): update lipgloss
Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2025-03-25 15:49:44 -03:00
Carlos Alexandro Becker
15ce054a43 feat: updating x/ansi (#1235)
* feat: updating x/ansi

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* fix: enable/disable mode

* fix: execute in private mode, fix tests

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* fix: update deps

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* fix: test

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* feat: update cellbuf

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

* all the updates

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>

---------

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2024-11-21 14:12:16 -05:00
Ayman Bagabas
265650c299
chore: merge branch 'v2-exp' into v2-renderer 2024-11-04 14:14:20 -05:00
Ayman Bagabas
31762e35f2
chore: bump ansi to v0.4.3 2024-11-04 14:12:42 -05:00
Ayman Bagabas
fc554e5972
chore: merge branch 'v2-exp' into v2-renderer 2024-10-30 12:39:19 -04:00
Ayman Bagabas
d7790f3007
chore: bump ansi to v0.4.2 2024-10-29 16:41:40 -04:00
Ayman Bagabas
250def3880
chore: merge branch 'v2-exp' into v2-renderer 2024-10-29 14:55:42 -04:00
Ayman Bagabas
95aa2ca675
chore: merge branch 'main' into v2-exp 2024-10-29 14:51:29 -04:00
Carlos Alexandro Becker
9f015c50fa
chore(deps): update lipgloss
Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2024-10-28 09:22:18 -03:00
Christian Rocha
3274e41ecb
docs(tutorials): upgrade tuts to v2 (#1155) 2024-09-18 14:36:52 -04:00
Ayman Bagabas
1678d85ce2
feat: use bubbles/v2 and bubbletea/v2 in examples and tutorials 2024-09-18 14:21:14 -04:00
Ayman Bagabas
88141ed31e
chore: update tutorials to use v2-exp 2024-09-12 11:43:59 -04:00
Ayman Bagabas
c86cd34294
Merge branch 'main' into v2-exp 2024-09-12 11:43:13 -04:00
Carlos Alexandro Becker
2dd30e5eb3
chore(deps): bump golang.org/x/sys from 0.24.0 to 0.25.0
Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2024-09-12 11:59:58 -03:00
Ayman Bagabas
537c80b936
Merge branch 'main' into v2-exp 2024-08-30 09:34:21 -04:00
Christian Rocha
17443d8d12
chore(deps): go mod tidy 2024-08-22 13:18:16 -04:00
Ayman Bagabas
13ffcad06c
refactor: reimplement the event loop with a sequence parser
Currently, Bubble Tea uses a simple lookup table to detect input events.
Here, we're introducing an actual input sequence parser instead of
simply using a lookup table. This will allow Bubble Tea programs to read
all sorts of input events such Kitty keyboard, background color, mode
report, and all sorts of ANSI sequence input events.

Supersedes: https://github.com/charmbracelet/bubbletea/pull/1079
Supersedes: https://github.com/charmbracelet/bubbletea/issues/1014
Related: https://github.com/charmbracelet/bubbletea/issues/869
Related: https://github.com/charmbracelet/bubbletea/issues/163
Related: https://github.com/charmbracelet/bubbletea/issues/918
Related: https://github.com/charmbracelet/bubbletea/issues/850
Related: https://github.com/charmbracelet/bubbletea/issues/207
2024-08-12 17:33:51 -04:00
Ayman Bagabas
cb801d8f2c
refactor: use x/term and x/ansi for renderer sequences (#962)
* refactor: use x/exp/term for renderer sequences

This replaces termenv.Output with raw sequences and a bytes.Buffer to
handle vt screen and cursor events.

* chore: update dependencies

* refactor: use x/term
2024-05-21 14:46:11 -04:00
Ayman Bagabas
46241068da
feat: reduce console/term dependencies (#897)
Replace mattn/isatty and containerd/console with golang.org/x/term.

This mostly affects Windows. On Windows, unlike Unix, the console (TTY)
has different handles for input/output. Using the Console API, we need
to enable VT input on the input handle (CONIN) and VT processing on the
output handle (CONOUT). Doing so enables processing VT sequences on
Windows i.e. ANSI colors, mouse sequences, cursor movements, etc.

We already handle enabling VT processing for the program output using
Termenv `EnableVirtualTerminalProcessing`. For the input side, we enable
VT input right before setting the console to raw.

By doing this, we can drop both containerd/console and mattn/isatty.
2024-03-01 15:53:09 -05:00
Christian Rocha
9253d68525 chore(deps): bump deps for tuts and examples 2024-03-01 13:00:31 -05:00
Ayman Bagabas
1993fc20c2
chore(deps): bump golang.org/x/{sys,term} 2024-02-28 12:59:18 -05:00
Ayman Bagabas
75966e8578
feat: support windows console input buffer (#878)
This adds support to the Windows Console Input Buffer API which access
the console API directly without the need for virtual terminal input
(i.e. the current mode that emulates unix inputs).
Since this uses the console input api, we can finally read window size
events.

This is mearly based on the awesome work of @erikgeiser in #140.

Fixes: https://github.com/charmbracelet/bubbletea/issues/538
Fixes: https://github.com/charmbracelet/bubbletea/issues/121
2024-02-27 14:21:42 -05:00
Carlos Alexandro Becker
da49e8f86a
feat: update bubbles, use go 1.18 (#916) 2024-02-05 14:54:10 +01:00
dependabot[bot]
e88b618205
chore(deps): bump golang.org/x/term from 0.9.0 to 0.16.0 (#898)
* feat(deps): bump golang.org/x/term from 0.9.0 to 0.16.0

Bumps [golang.org/x/term](https://github.com/golang/term) from 0.9.0 to 0.16.0.
- [Commits](https://github.com/golang/term/compare/v0.9.0...v0.16.0)

---
updated-dependencies:
- dependency-name: golang.org/x/term
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* chore(deps): go mod tidy

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Christian Rocha <christian@rocha.is>
2024-01-10 16:31:35 -05:00
Carlos Alexandro Becker
c6cb2b199e
feat(deps): update dependencies (#858)
* feat(deps): update dependencies

* chore(deps): update bubbles to v0.17.1 in examples

---------

Co-authored-by: Christian Rocha <christian@rocha.is>
2024-01-09 17:16:42 -05:00
Kevin Goslar
6ff6405ae4 Fix grammar in README 2024-01-09 08:42:36 -05:00
Ayman Bagabas
2bcb0af2e2
feat: add set-window-title command (#611)
Set the terminal window title using termenv.

Fixes: https://github.com/charmbracelet/bubbletea/issues/610
2023-12-04 11:50:27 -05:00
Carlos Alexandro Becker
cd63c32c73
feat(deps): update termenv (#768) 2023-06-28 16:40:08 +02:00
Carlos Alexandro Becker
b80eb8303b
docs: fix lint issues in examples and tutorials (#759)
Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
2023-06-09 13:33:53 -03:00
Christian Muehlhaeuser
6eb0209d13 chore: bump termenv, lipgloss, x/term 2023-04-04 13:27:12 +02:00
Christian Muehlhaeuser
35c31f2168 chore: bump console dep 2023-03-13 18:09:44 +01:00
dependabot[bot]
388c67d573
feat(deps): bump golang.org/x/text from 0.3.7 to 0.3.8 (#674) 2023-02-23 16:29:25 +00:00
Glenn Gonda
4880cf2a09 docs: fix typos and clean up comments 2023-02-19 08:45:22 -05:00
Christian Rocha
1ad9f9c15c chore(deps): bump termenv and go-isatty
Also bump various deps in tutorials and examples
2023-02-08 10:04:56 -05:00
Christoffer Åström
e95e1a0db5 feat: sequence support BatchMsg 2023-02-07 10:06:46 -05:00
BoilingSoup
d7bc683260 fix typo 2023-02-06 10:24:24 -05:00
Martin Dosch
2d10416631 [codespell]: Fix typos. 2022-11-03 12:55:31 -04:00
Christian Muehlhaeuser
39381647f1 docs: new readme footer 2022-10-24 10:13:38 +02:00
Benjamin DeCoste
aba3cec050
docs: fix code in commands tutorial (#501) 2022-10-12 05:45:51 +02:00
Christian Muehlhaeuser
6b77c8fc10 chore: rename StartReturningModel to Run
Added aliases for the old functions, but deprecated them.
2022-10-08 01:34:17 +02:00
Christian Muehlhaeuser
22d15efad7 chore: clean up linter errors in examples 2022-10-08 00:56:56 +02:00
Christian Muehlhaeuser
6c449e55bf feat: use Termenv.Output to write to tty 2022-09-27 02:49:36 +02:00
freddysilber
5c4218e5f6
chore: fix typos in tutorials/commands/README.md
* chore: fixes typos in `tutorials/commands/README.md`
2022-09-26 15:58:52 -04:00