mirror of
https://github.com/anomalyco/opentui.git
synced 2026-04-25 13:06:00 +03:00
[PR #14] [MERGED] chore(input): implement get/set #220
Labels
No labels
bug
core
documentation
feature
good first issue
help wanted
pull-request
question
react
solid
tmux
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/opentui#220
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/anomalyco/opentui/pull/14
Author: @msmps
Created: 8/14/2025
Status: ✅ Merged
Merged: 8/14/2025
Merged by: @kommander
Base:
main← Head:feat/add-setters-20250814212158📝 Commits (1)
32d1aaechore(input): implement get/set📊 Changes
3 files changed (+127 additions, -108 deletions)
View changed files
📝
src/examples/input-demo.ts(+9 -9)📝
src/examples/input-select-layout-demo.ts(+1 -1)📝
src/renderables/Input.ts(+117 -98)📄 Description
Description
New setters:
backgroundColor- Sets the background color with automatic color parsingtextColor- Sets the text color with automatic color parsingfocusedBackgroundColor- Sets the focused background colorfocusedTextColor- Sets the focused text colorplaceholderColor- Sets the placeholder text colorcursorColor- Sets the cursor colormaxLength- Sets the max lengthplaceholder- Sets the placeholder textConverted to get/set:
value- getValue()/setValue() → get/set valuecursorPosition- getCursorPosition()/setCursorPosition() → get/set cursorPositionRemoved unused getters (for now):
placeholder- getPlaceholder()maxLength- getMaxLength()Implementation Details:
_backgroundColor)this.needsUpdate()to trigger re-rendering when properties changeparseColor()to handle different color input formats🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.