mirror of https://github.com/jlelse/teleposter
Fix editor and make it faster
This commit is contained in:
parent
6f4e211085
commit
8e946f6f38
|
@ -4,17 +4,19 @@
|
|||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
|
||||
rel="stylesheet">
|
||||
<link href="https://rawgit.com/summernote/summernote/master/dist/summernote.css"
|
||||
rel="stylesheet">
|
||||
<style> * { max-width: 100%; height: auto; word-break: break-all; word-break: break-word; }</style>
|
||||
<link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css"
|
||||
rel="stylesheet">
|
||||
<script src="http://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js"></script>
|
||||
<link href="http://cdnjs.cloudflare.com/ajax/libs/summernote/0.8.9/summernote.css"
|
||||
rel="stylesheet">
|
||||
<script src="http://cdnjs.cloudflare.com/ajax/libs/summernote/0.8.9/summernote.js"></script>
|
||||
<style> * { max-width: 100%; height: auto; word-break: break-all; word-break: break-word; }
|
||||
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="summernote" style="width:100%;height:100%"></div>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
|
||||
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
|
||||
<script src="https://rawgit.com/summernote/summernote/master/dist/summernote.min.js"></script>
|
||||
<script>
|
||||
function domToNode(domNode) {
|
||||
if (domNode.nodeType == domNode.TEXT_NODE) {
|
||||
|
@ -47,6 +49,7 @@
|
|||
function getNodeJson() {
|
||||
window.android.getText(JSON.stringify(domToNode(document.getElementsByClassName('note-editable')[0]).children));
|
||||
}
|
||||
|
||||
</script>
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
|
@ -69,6 +72,7 @@
|
|||
}
|
||||
});
|
||||
});
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
Loading…
Reference in New Issue