Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(68)

Unified Diff: third_party/polymer/components/paper-input/paper-input-container.html

Issue 3010683002: Update Polymer components. (Closed)
Patch Set: Rebase Created 3 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/polymer/components/paper-input/paper-input-container.html
diff --git a/third_party/polymer/components/paper-input/paper-input-container.html b/third_party/polymer/components/paper-input/paper-input-container.html
index 1c6e00712a4accac1d828dc0c77479b521c581ce..2ef06efa53af5c05654fe105081bd7188471374f 100644
--- a/third_party/polymer/components/paper-input/paper-input-container.html
+++ b/third_party/polymer/components/paper-input/paper-input-container.html
@@ -90,7 +90,11 @@ Custom property | Description | Default
`--paper-input-container-label-focus` | Mixin applied to the label when the input is focused | `{}`
`--paper-input-container-label-floating` | Mixin applied to the label when floating | `{}`
`--paper-input-container-input` | Mixin applied to the input | `{}`
+`--paper-input-container-input-focus` | Mixin applied to the input when focused | `{}`
+`--paper-input-container-input-invalid` | Mixin applied to the input when invalid | `{}`
`--paper-input-container-input-webkit-spinner` | Mixin applied to the webkit spinner | `{}`
+`--paper-input-container-input-webkit-clear` | Mixin applied to the webkit clear button | `{}`
+`--paper-input-container-ms-clear` | Mixin applied to the Internet Explorer clear button | `{}`
`--paper-input-container-underline` | Mixin applied to the underline | `{}`
`--paper-input-container-underline-focus` | Mixin applied to the underline when the input is focused | `{}`
`--paper-input-container-underline-disabled` | Mixin applied to the underline when the input is disabled | `{}`
@@ -277,6 +281,20 @@ This element is `display:block` by default, but you can set the `inline` attribu
@apply(--paper-input-container-input);
}
+ .input-content.focused ::content input,
+ .input-content.focused ::content textarea,
+ .input-content.focused ::content iron-autogrow-textarea,
+ .input-content.focused ::content .paper-input-input {
+ @apply(--paper-input-container-input-focus);
+ }
+
+ .input-content.is-invalid ::content input,
+ .input-content.is-invalid ::content textarea,
+ .input-content.is-invalid ::content iron-autogrow-textarea,
+ .input-content.is-invalid ::content .paper-input-input {
+ @apply(--paper-input-container-input-invalid);
+ }
+
.input-content ::content input::-webkit-outer-spin-button,
.input-content ::content input::-webkit-inner-spin-button {
@apply(--paper-input-container-input-webkit-spinner);
@@ -594,11 +612,20 @@ This element is `display:block` by default, but you can set the `inline` attribu
if (label) {
this.$.labelAndInputContainer.style.position = 'relative';
}
+ if (invalid) {
+ cls += ' is-invalid';
+ }
}
} else {
if (_inputHasContent) {
cls += ' label-is-hidden';
}
+ if (invalid) {
+ cls += ' is-invalid';
+ }
+ }
+ if (focused) {
+ cls += ' focused';
}
return cls;
},

Powered by Google App Engine
This is Rietveld 408576698