| <!DOCTYPE html> |
| <html> |
| <head> |
| <script src="resources/dump-attributed-string.js"></script> |
| <script> |
| shouldAutoDump = false; |
| </script> |
| </head> |
| <body> |
| |
| <div id="editor" style="color: rgba(23, 45, 56, 0.4);" contenteditable>Some text here</div> |
| |
| <script type="text/javascript"> |
| |
| document.getElementById("editor").focus(); |
| getSelection().setPosition(editor, 0); |
| |
| if (window.testRunner) { |
| var attribString = textInputController.attributedStringForTyping() |
| var serialized = serializeAttributedString(attribString); |
| |
| var pre = document.createElement('pre'); |
| pre.textContent = 'Input:\n' + editor.outerHTML.trim() + '\n\nOutput:\n' + serialized; |
| |
| document.body.appendChild(pre); |
| } |
| |
| </script> |
| |
| </body> |
| </html> |