Skip to content

Use promkit-widgets v0.3.0 - #107

Merged
ynqa merged 11 commits into
v0.7.0/devfrom
promkit-widgets
Feb 26, 2026
Merged

Use promkit-widgets v0.3.0#107
ynqa merged 11 commits into
v0.7.0/devfrom
promkit-widgets

Conversation

@ynqa

@ynqa ynqa commented Feb 25, 2026

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings February 25, 2026 11:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the application to the promkit-widgets v0.3.0 API, including migrating widget state/config usage and aligning the project’s TOML configuration schema and documentation with the new upstream config types.

Changes:

  • Refactor Listbox/Text/TextEditor/JsonStream state initialization to use the new config-centric APIs in promkit-widgets v0.3.0.
  • Simplify src/config.rs by embedding promkit_widgets::{text_editor,jsonstream,listbox}::Config directly and remove now-unneeded custom serde glue.
  • Update default.toml and README configuration examples to the new table structure (e.g., [editor.on_focus], [json.stream], [completion.listbox]).

Reviewed changes

Copilot reviewed 10 out of 11 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/search.rs Update listbox usage to new API (state.config.lines, Listbox::from).
src/prompt.rs Migrate text::State styling to text::Config { style: Some(...) }.
src/main.rs Wire listbox::Config, text_editor::Config, and jsonstream::Config from the loaded config into widget states/providers.
src/json.rs Switch JSON stream formatting from RowFormatter to jsonstream::Config, and update text styling to config-based API.
src/editor.rs Replace per-field theme application with swapping entire text_editor::Config; update word break / mode access.
src/config/text_editor.rs Remove custom serde for editor mode (no longer needed).
src/config.rs Restructure config types to directly use promkit-widgets config structs and keep keybind serde via event_set_serde.
default.toml Update config schema to match new embedded config structs and termcfg notation examples.
README.md Update documented config example to new schema and wrap settings in a <details> block.
Cargo.toml Bump promkit-widgets to v0.3.0 (currently via local path override).
Cargo.lock Lockfile updates reflecting the dependency change (currently consistent with path-based resolution).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Cargo.toml Outdated
@ynqa
ynqa merged commit 0e8e2af into v0.7.0/dev Feb 26, 2026
7 checks passed
@ynqa
ynqa deleted the promkit-widgets branch February 26, 2026 00:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants