49 lines
858 B
HTML
49 lines
858 B
HTML
<html>
|
|
<head>
|
|
|
|
<style>
|
|
body {
|
|
font-size: 24px;
|
|
}
|
|
.editing {
|
|
border: 2px solid red;
|
|
padding: 12px;
|
|
}
|
|
div {
|
|
border: 2px solid blue;
|
|
padding: 12px;
|
|
}
|
|
|
|
</style>
|
|
<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
|
|
|
|
<script>
|
|
|
|
function editingTest() {
|
|
for (i = 0; i < 7; i++)
|
|
moveSelectionForwardByCharacterCommand();
|
|
insertParagraphCommand();
|
|
}
|
|
|
|
</script>
|
|
|
|
<title>Editing Test</title>
|
|
</head>
|
|
<body contenteditable id="root">
|
|
|
|
Test inserting paragraphs: should see two blue boxes, where the second blue box starts with an empty line.
|
|
|
|
<div style="border: none; height: 12px"></div>
|
|
|
|
<div>
|
|
<div class="editing" id="test">baz</div>bar<div class="editing">foo</div>
|
|
<div class="editing"><br class="khtml-block-placeholder"></div>
|
|
</div>
|
|
|
|
<script>
|
|
runEditingTest();
|
|
</script>
|
|
|
|
</body>
|
|
</html>
|