Commit Graph

469 Commits

Author SHA1 Message Date
Carlos A Becker e8289143a5 test: logging test
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-12 14:21:02 -04:00
Carlos A Becker 350b13cba7 test: key tests
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-12 14:21:02 -04:00
Carlos A Becker cfb871c5ca test: cmds
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-12 14:21:02 -04:00
Carlos A Becker 7934b60e21 test: logging
Signed-off-by: Carlos A Becker <caarlos0@gmail.com>
2021-10-12 14:21:02 -04:00
Christian Rocha 0b4539170b Set ENABLE_VIRTUAL_TERMINAL_INPUT on Windows 2021-10-02 21:13:03 -04:00
Christian Rocha ab60d776f1 Add missing Go 1.17 build tags in Windows files 2021-10-02 21:13:03 -04:00
Christian Rocha 0e7cd09bf6 Tidy up comments 2021-09-28 14:00:29 -04:00
Christian Rocha 860f623112 Remove reundant "if ...; err != nil" check 2021-09-28 14:00:29 -04:00
Erik G e402e8b567
Cancelable reads (#120)
This commit implements cancelable reads, which allows Bubble Tea programs to run in succession in a single application. It also makes sure all goroutines terminate before `Program.Start()` returns.

Closes #24.
2021-09-28 13:30:11 -04:00
Christian Rocha 7396e37f3f Fix a performance rendering size miscalculation in the pager example 2021-09-17 16:39:02 -04:00
Christian Rocha d1fb02c39d Use the hot, new Go 1.17 build tags syntax 2021-09-07 16:13:48 -04:00
Christian Rocha 9d0e1db101 Tidy up tutorials 2021-09-07 15:38:47 -04:00
Christian Rocha ad19c664fe Condense/scope init cmd 2021-09-07 15:37:14 -04:00
Christian Rocha c5ed2b4a01 Add missing GoDocs 2021-09-07 15:37:14 -04:00
Christian Rocha 749e48df11 Update animated progress bar example per its current API 2021-09-07 14:16:55 -04:00
Carlos Alexandro Becker 60ddf33992
fix: avoid global state (#126)
Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
2021-09-04 13:48:46 -03:00
Christian Rocha 59e5d8e2c9 Add sqlite-tui to the list of things built with Bubble Tea 2021-09-02 16:01:13 -04:00
Christian Muehlhaeuser 3930519979
Fix typos 2021-08-23 23:18:00 +02:00
Christian Muehlhaeuser 27ba7e7aa1 Add list examples 2021-08-23 22:18:28 +02:00
Christian Rocha 1b8495ed21 Add help bubble example 2021-08-23 22:05:20 +02:00
Christian Rocha 2792304416 Add Harmonica, AT CLI, and Canard to the README 2021-08-02 13:05:52 -04:00
Christian Rocha ea0550121e Don't close the msgs channel on shutdown 2021-08-02 10:50:04 -04:00
Christian Rocha 5f41a91e02 Fix Windows stuff related to the refactor at 49a5d16 2021-08-02 10:50:04 -04:00
Christian Rocha 67625b480e Bump deps in commands to fix builds 2021-08-02 10:50:04 -04:00
Christian Rocha 4bfad658ad Simplify how we listen for window resizes 2021-08-02 10:50:04 -04:00
Christian Rocha 01dd88fd1d Always hide and show the cursor during startup and shutdown 2021-08-02 10:50:04 -04:00
Christian Rocha e1ca585c16 Simplify how we enable ANSI colors on Windows 2021-08-02 10:50:04 -04:00
Christian Rocha 8574b87a44 Bump containerd/console in examples 2021-08-02 10:50:04 -04:00
Christian Rocha 30fd7a8f20 Better logic in input checks 2021-08-02 10:50:04 -04:00
Christian Rocha 9f9b3aea96 Read input regardless of whether or not it's a TTY
This commit also contains some refactors:

* Refactor away inputStatus type
* Refactor away program.inputIsTTY member
* Simplify how we setup and restore input when it's a TTY
2021-08-02 10:50:04 -04:00
Christian Rocha 9826251f08 Add WithInputTTY ProgramOption 2021-08-02 10:50:04 -04:00
Christian Rocha e87344b791 Move ProgramOptions into a separate file 2021-08-02 10:50:04 -04:00
Christian Rocha 863e2ad74e Bump containerd/console to v1.0.2 2021-08-02 10:50:04 -04:00
Christian Rocha 3a9ede46f6 Condense a scoped if-statement 2021-08-02 10:50:04 -04:00
Christian Rocha 8f03848f54 Split progress bar example into static and animated versions 2021-07-26 12:50:53 -04:00
Christian Muehlhaeuser facc87217f Update linter config 2021-07-12 03:07:05 +02:00
Christian Rocha 0886ee26b0 Msgs can now be sent to Programs with Program.Send(Msg) 2021-07-01 11:06:21 -04:00
Christian Rocha b957c32c18 Fix a bug where explicitly ignored lines weren't honored by the renderer 2021-06-22 13:06:55 -04:00
Christian Rocha b2c726a182 Make README footer more consistent with newer Charm READMEs 2021-06-07 20:59:16 -04:00
Christian Rocha 22244e0af4 Add Slides and Typer to stuff built with Bubble Tea 2021-06-07 20:59:16 -04:00
Christian Rocha 6547773a3f Clear output and render "nothing" when a view returns the empty string
Closes #100.
2021-06-02 14:49:54 -04:00
Christian Rocha 1f773e8f20 Fix a race where artifacts could print when exiting a program
This commit also consolidates the exit operations for consistency's
sake, and adds a kill() method to renderers for stopping them without
performing any final rendering.
2021-06-02 14:49:54 -04:00
Christian Rocha 85ab476698 Add ProgramOptions for entering the altscreen and enabling the mouse
Because they run ansyncronously, the analogous commands, when run in
a Model's Init() function, could fire after the renderer has starting
writing to output, rendering artifacts to the commandline.
2021-06-02 14:49:54 -04:00
Christian Rocha ec2fbf024b Cycle through cursor modes in textinputs example per Bubbles v0.8.0 2021-06-02 12:44:32 -04:00
Christian Rocha 035d2abd3e Properly cast inputStatus types + mark related linter false positive 2021-05-31 10:43:31 -04:00
Christian Rocha 3e98f55adf Add linter ignore rule for windows-related false positive on unix 2021-05-31 10:43:31 -04:00
Christian Rocha 955ce5c82c Extract magic number in X10 mouse parser 2021-05-31 10:43:31 -04:00
Christian Rocha 3256fae4d4 Force a full repaint when resizing the window
v0.13.4 introduced a regression where lines weren't always cleared when
resizing the window resulting in the presence of rendering artifacts.
This commit fixes that.
2021-05-31 10:37:32 -04:00
Ilya Revenko 29b7de4b7c
Fix more typos in examples (#102) 2021-05-28 19:45:17 +02:00
irevenko da9e8ee75a Fix typo in examples/result 2021-05-26 16:47:01 -04:00