JSFiddle - React, Tailwind, and code Playground

HTML

<script src="http://jeasyui.com/easyui/jquery.easyui.min.js"></script>
<link rel="stylesheet" href="http://jeasyui.com/easyui/themes/default/easyui.css">
<link rel="stylesheet" href="http://jeasyui.com/easyui/themes/icon.css">
<div>
<textarea class="easyui-textbox valuetip" multiline="true" style="height:50px">First Line
Second Line
Third Line
Fourth Line
</textarea>
<div style="margin-top:20px">
<input id="test" class="easyui-textbox valuetip">
<div style="margin-top:20px">
<input class="easyui-textbox valuetip">

JavaScript

$('.valuetip').css('text-overflow','ellipsis').each(function(){
    $(this).textbox({icons:[{iconCls:'icon-ok'}]}).textbox('getIcon',0).tooltip({
        content: $(this).val().replace(/(\r\n|\n|\r)/g,"<br />"),
        showEvent: $(this).val() ? 'mouseenter' : 'none'
    });
})

setTimeout(function(){
    $('#test').textbox('setValue','Hello World');    
},1000)