jqxlayout and angular
asdf
HTML
<link rel="stylesheet" href="http://www.jqwidgets.com/jquery-widgets-demo/jqwidgets/styles/jqx.base.css">
<script src="https://jqwidgets.com/public/jqwidgets/jqx-all.js"></script>
<div contenteditable="false" style="margin-top: 100px; background-color: white; width: 400px; height: 300px;" id="editor">
</div>
<p style="color: blue; font-size: 18px;">
Hi, I'm formatted text.
</p>
<button id="button">Content</button>
<button id="btn">Set</button>
TypeScript
$("#editor").jqxEditor({
editable: true,
pasteMode: "html"
});
var pasteMode = $('#editor').jqxEditor('pasteMode');
console.log(pasteMode);
$('#editor').jqxEditor('setMode', true);
$('#button').click(function () {
console.log($('#editor').jqxEditor('val'));
});
$('#btn').click(function () {
var text = `<p style="color: blue; font-size: 18px;">
Hi, I'm formatted text.
</p>`;
console.log($('#editor').jqxEditor('val', text));
});