Skip to content

Truly independent web browser

LibWeb: Grey out the text of disabled text fields

Andreas Klingf56967f1fa9b
diff --git a/Libraries/LibWeb/CSS/Default.css b/Libraries/LibWeb/CSS/Default.css
index f74259da846..52bd2cff634 100644
--- a/Libraries/LibWeb/CSS/Default.css
+++ b/Libraries/LibWeb/CSS/Default.css
@@ -41,6 +41,10 @@ input:not([type=submit], input[type=button], input[type=image], input[type=reset
background-color: Field;
color: FieldText;
+
+ &:disabled {
+ color: GrayText;
+ }
}
textarea {
diff --git a/Tests/LibWeb/Text/expected/css/style-engine/live-state-facts.txt b/Tests/LibWeb/Text/expected/css/style-engine/live-state-facts.txt
index 38786948825..414d160fe59 100644
--- a/Tests/LibWeb/Text/expected/css/style-engine/live-state-facts.txt
+++ b/Tests/LibWeb/Text/expected/css/style-engine/live-state-facts.txt
@@ -4,8 +4,8 @@ make progress determinate: [div, progress-subject]
make progress indeterminate: []
make text input read-only: [read-only-subject, read-write-subject]
make text input read-write: []
-disable text input: [read-only-subject, read-write-subject]
-enable text input: []
+disable text input: [text, read-only-subject, read-write-subject]
+enable text input: [text]
make subtree editable: [editable-subject]
make subtree non-editable: [editable-subject]
design mode makes elements read-write: rgb(0, 128, 0)