Is there a way to remove the dashed border from a read-only TextField in Vaadin 14, similar to the one shown below?
https://i.sstatic.net/NpIRm.png
I am aiming to eliminate the dashed border for specific TextFields by targeting those with a special CSS classname. I have created a file named textfieldstyles.css within [projekt]/frontend/styles/ containing the following code:
[part="input-field"]::after {
border-style: none;
border-width: 0px;
border-color: white;
/* does not change anything: border: 0px none white; */
}
In addition, I included an annotation in my Vaadin Java component as follows:
@CssImport(value = "./styles/textfieldstyles.css", themeFor = "vaadin-text-field")
Despite these efforts, the outcome is not entirely satisfactory. Although my CSS code is applied to the element’s style successfully, it appears after the dashing style, resulting in a continued presence of the dashed border. The Firefox inspector screenshot below illustrates this issue:
https://i.sstatic.net/ruv7E.png
Now, the question remains – how can I prioritize my styles over the default Vaadin styles?