Conversation
…t and update into_terminal_frame signature.
There was a problem hiding this comment.
Pull Request Overview
This PR switches the terminal handling from the crossterm library to tuinix. The key changes include:
- Updating widget modules (search result, legend, command editor) to use tuinix types and functions.
- Removing the legacy terminal module and associated crossterm dependencies.
- Refactoring the canvas module to replace TokenStyle/TokenPosition with TerminalStyle/TerminalPosition and providing a new API for converting canvas frames.
Reviewed Changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/widget_search_result.rs | Updated terminal API usage from crossterm to tuinix. |
| src/widget_legend.rs | Replaced styling and position types with their tuinix equivalents. |
| src/widget_command_editor.rs | Adapted key input handling and styling to use tuinix API. |
| src/terminal.rs | Entirely removed as terminal handling shifts to tuinix. |
| src/lib.rs | Removed reference to the removed terminal module. |
| src/canvas.rs | Refactored to use tuinix types; removed dirty_lines and TokenPosition. |
| src/app.rs | Adjusted event handling and key input management to reflect new APIs. |
| Cargo.toml | Removed crossterm dependency and added tuinix. |
| .cargo/config.toml | Added a development alias. |
Comments suppressed due to low confidence (2)
src/canvas.rs:278
- The usage of 'TokenPosition' in the tests still remains even though it has been replaced by 'TerminalPosition'. Please update the test code accordingly.
canvas.draw_at(TokenPosition::row(0), Token::new("hello"));
src/canvas.rs:284
- The tests are referencing the removed 'dirty_lines' function on the frame. Please update the tests to use the new 'into_terminal_frame' API or adjust the test logic.
assert_eq!(frame2.dirty_lines(&frame1).count(), 2);
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.