Skip to content

Reworked the EditableTextPrompt to better handle long values#73

Merged
karl-sjogren merged 4 commits into
developfrom
feature/prompt-wrapping-issue
Feb 18, 2026
Merged

Reworked the EditableTextPrompt to better handle long values#73
karl-sjogren merged 4 commits into
developfrom
feature/prompt-wrapping-issue

Conversation

@karl-sjogren
Copy link
Copy Markdown
Owner

No description provided.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Reworks EditableTextPrompt to support horizontal scrolling for long inputs so editing remains usable within narrow console widths.

Changes:

  • Add horizontal scrolling window logic with left/right scroll indicators in EditableTextPrompt.Render().
  • Update render call sites to pass strings (instead of the StringBuilder) and introduce helper methods for windowing/cursor rendering.
  • Add new prompt tests that exercise long-input editing scenarios under a narrow console width.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.

File Description
src/Karls.BetterSecretsTool/Prompts/EditableTextPrompt.cs Implements horizontal scrolling and new rendering/windowing logic for long text inputs.
test/Karls.BetterSecretsTool.Tests/Prompts/EditableTextPromptTests.cs Adds new long-text prompt interaction tests under constrained console width.

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

Comment thread src/Karls.BetterSecretsTool/Prompts/EditableTextPrompt.cs
Comment thread src/Karls.BetterSecretsTool/Prompts/EditableTextPrompt.cs Outdated
Comment thread test/Karls.BetterSecretsTool.Tests/Prompts/EditableTextPromptTests.cs Outdated
Comment thread src/Karls.BetterSecretsTool/Prompts/EditableTextPrompt.cs
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.

When editing a value that needs to linebreak the prompt control repeats

2 participants