Switch back to clearing MathJax preview on blur
This means two clicks are required again, but that's the lesser of two evils: https://forums.ankiweb.net/t/anki-2-1-55-beta-mathjax-preview/23529/8 Better fixes welcome :-)
This commit is contained in:
parent
29b2a2b35c
commit
e14f87ba99
@ -99,7 +99,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
||||
{configuration}
|
||||
bind:api={codeMirror}
|
||||
on:change={({ detail: mathjaxText }) => code.set(mathjaxText)}
|
||||
on:tab
|
||||
on:blur
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
@ -192,10 +192,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
||||
placeHandle(true);
|
||||
await resetHandle();
|
||||
}}
|
||||
on:tab={async () => {
|
||||
// Instead of resetting on blur, we reset on tab
|
||||
// Otherwise, when clicking from Mathjax element to another,
|
||||
// the user has to click twice (focus is called before blur?)
|
||||
on:blur={async () => {
|
||||
await resetHandle();
|
||||
}}
|
||||
let:editor={mathjaxEditor}
|
||||
|
Loading…
Reference in New Issue
Block a user