Polymeric - color floating paper mark
How can I change the color of a focused float in a polymer?
Thanks for answers.
+3
Václav Pavlíček
source
to share
4 answers
The only way I managed to get around this issue was as follows:
paper-input-decorator[focused] /deep/ .floating-label,
paper-input-decorator[focused] /deep/ .label-text {
/* floating label color when the input is focused */
color: orange !important;
}
Note how the document-decorator-decorator was to be printed [focused] / deep / twice
+2
nephthyes white
source
to share
You can also use main style to do this, if you don't want to use / deep / selectors it will look something like this (untested):
<core-style id="paper-input-decorator">
.floating-label, .label-text {
color: orange;
}
</core-style>
+2
Jake macdonald
source
to share
You can set the following polymer type variable: -paper-input-container-focus-color, for example
#myInput{
--paper-input-container-focus-color: red;
}
+1
ManGI1
source
to share
For information:
To change any label style or floating label inside paper entry use the code below.
paper-input {
--paper-input-container-label: {
color: red;
font-size: 14px;
};
--paper-input-container-label-floating: {
color: red;
font-size: 14px;
};
}
0
vishnu
source
to share