I have a css class that looks like the following:
.max-3-lines {
overflow: hidden;
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
}
I’m using it to limit the number of lines of text that a div shows. This has worked well until I upgraded to Ionic 2.2.0. Now, however, the div doesn’t limit lines anymore. After looking into it I found that one of the properties needed to make it work is missing. In the Chrome inspector, the class looks like this:
.max-3-lines {
overflow: hidden;
display: -webkit-box;
-webkit-line-clamp: 3;
}
Ionic is apparently removing the -webkit-box-orient
property during transpiling. I can add the property back inside the Chrome inspector, and then the div behaves as expected.
Why would this property be getting removed? Is this a bug in Ionic 2.2.0? And is there a workaround?
Thanks