1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 07:27:45 +00:00

LibWeb: Render text inside <input type=password> as asterisks (*)

This makes it possible to enter passwords while recording YouTube
videos. :^)
This commit is contained in:
Andreas Kling 2022-11-05 17:19:00 +01:00
parent b33a2eb9b1
commit 5839ef2ed8
3 changed files with 14 additions and 0 deletions

View file

@ -31,6 +31,9 @@ public:
WebIDL::ExceptionOr<JS::NonnullGCPtr<Text>> split_text(size_t offset);
bool is_password_input() const { return m_is_password_input; }
void set_is_password_input(Badge<HTML::HTMLInputElement>, bool b) { m_is_password_input = b; }
protected:
Text(Document&, String const&);
Text(Document&, NodeType, String const&);
@ -41,6 +44,7 @@ private:
JS::GCPtr<HTML::HTMLInputElement> m_owner_input_element;
bool m_always_editable { false };
bool m_is_password_input { false };
};
template<>