Originally built by Kenji Abe (STAR-ZERO)
Multiple-line interactive truncation.
Fit one line (default behaviour)
$('#target').ellipsis();
Fit on two lines in the case of two or more lines
$('#target').ellipsis(2);
Change ellipsis character
$('#target').ellipsis(2, '**');
Whenever you want to reflow the element, just call it the same way, and it'll restore its old text, if you change the text, remember to change the data-ellipsis attribute as well.
jquery-ellipsis-interactive is available under the terms of the MIT License.