Friday, April 28, 2017

[CSS / Trick] Readonly Input Text

Message for the future me: this is a small CSS trick to make an input text like an output label using CSS:

.inputDisabled{
   pointer-events: none;
   cursor: default;
   background-color: white;
   border: none;
   font: inherit;
}

This is an example: