use isolation characters instead of direction markers in cloze handling
https://anki.tenderapp.com/discussions/ankidesktop/40443-improper-location-of-c1foo-on-ltr-text-in-an-rtl-cloze-field
This commit is contained in:
parent
0c5f22f4ae
commit
e838769d02
@ -295,8 +295,8 @@ function wrapIntoText(front, back) {
|
|||||||
|
|
||||||
function wrapInternal(front, back, plainText) {
|
function wrapInternal(front, back, plainText) {
|
||||||
if (currentField.dir === "rtl") {
|
if (currentField.dir === "rtl") {
|
||||||
front = "‫" + front + "‬";
|
front = "⁨" + front + "⁩";
|
||||||
back = "‫" + back + "‬";
|
back = "⁨" + back + "⁩";
|
||||||
}
|
}
|
||||||
const s = window.getSelection();
|
const s = window.getSelection();
|
||||||
let r = s.getRangeAt(0);
|
let r = s.getRangeAt(0);
|
||||||
|
Loading…
Reference in New Issue
Block a user