rviscomi / trunk8

jQuery Truncation Plugin -- THIS PROJECT IS NO LONGER MAINTAINED
MIT License
703 stars 95 forks source link

trunk8 does not reproduce cleared element #46

Open sergeychernyshev opened 10 years ago

sergeychernyshev commented 10 years ago

I'm having an issue with truncating an element that clears parent with "clear: both". Basically, when placeholder "i" is inserted, it does not behave the same way as original element does and therefore innerHeight() is measured on element that didn't clear making the compared height too high.

sergeychernyshev commented 10 years ago

Here's the gist illustrating markup https://gist.github.com/sergeychernyshev/900adc87806925cab133

rviscomi commented 10 years ago

I tried to reproduce the issue using your markup in this JSFiddle: http://jsfiddle.net/NaHr7/

Is that close to what you're seeing?

sergeychernyshev commented 10 years ago

Yes, I believe that's it.

My temporary work-around is to insert an empty div with clear:both on it above the text.