blob: ebd2a2ecd20d113ee495c74075369a7ee123330c [file] [log] [blame]
<!DOCTYPE html>
<html>
<body>
<p>
This tests that clicking in a contenteditable div will set the caret in the right position for RTL text in a RTL block.
To test manually, click the right of the text. The caret should be on the right edge.
</p>
<div style="font-size: 20px; width: 20ex; border: solid thin black; padding: 10px;" contenteditable>&#x05e9;&#x05d3;&#x05d4; &#x05d1;&#x05d5;&#x05e8;</div>
<script src="resources/caret-edge-shared.js"></script>
<script>
var clickOn = 'right';
var expectedOffset = 7;
if (window.internals && internals.runtimeFlags.bidiCaretAffinityEnabled) {
// When bidi caret affinity is enabled, carets are shown at different visual
// locations. Use the changed test expectations in this case.
expectedOffset = 0;
}
runTest();
</script>
</body>
</html>