-
Notifications
You must be signed in to change notification settings - Fork 9
Component PasswordInput
MeowLynxSea edited this page Jan 25, 2026
·
5 revisions
A password input field.
This component provides a secure text input experience (masking characters) and standard editing behavior.
use gpui::ElementId;
use yororen_ui::component::password_input;
let view = password_input()
.key(("settings", "password"))
.placeholder("Password")
.on_change(|value, _window, _cx| {
// ...
});- Password fields and secret inputs
-
password_input(): constructor -
id(...) / key(...): stable identity placeholder("...")disabled(bool)-
allow_copy(bool): allow copying selected text to clipboard (default:false) -
allow_cut(bool): allow cutting selected text to clipboard (default:false) -
on_change(|value, window, cx| ...): fired on content change - Styling:
bg/border/focus_border/text_color/height
- Height:
36px - Placeholder: empty string
- Requires one-time registration via
yororen_ui::component::init(cx). - By default, copy/cut are disabled to reduce the risk of accidentally leaking secrets via the clipboard.
Yororen UI v0.3.0 · repository · Apache-2.0 · This wiki documents Yororen UI v0.3.0.
This wiki documents Yororen UI v0.3.0 — the headless-core, swappable-renderer build.