mirror of
https://github.com/ankitects/anki.git
synced 2025-09-25 17:26:36 -04:00
Move PlainTextBadge between editing inputs
where it belongs :)
This commit is contained in:
parent
26c5fbc367
commit
1280372129
1 changed files with 11 additions and 14 deletions
|
@ -359,22 +359,19 @@ the AddCards dialog) should be implemented in the user of this component.
|
||||||
>
|
>
|
||||||
<ImageHandle maxWidth={250} maxHeight={125} />
|
<ImageHandle maxWidth={250} maxHeight={125} />
|
||||||
<MathjaxHandle />
|
<MathjaxHandle />
|
||||||
|
|
||||||
<svelte:fragment slot="plain-text-badge">
|
|
||||||
<PlainTextBadge
|
|
||||||
bind:off={plainTextsHidden[index]}
|
|
||||||
on:toggle={() => {
|
|
||||||
plainTextsHidden[index] =
|
|
||||||
!plainTextsHidden[index];
|
|
||||||
|
|
||||||
if (!plainTextsHidden[index]) {
|
|
||||||
plainTextInputs[index].api.refocus();
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</svelte:fragment>
|
|
||||||
</RichTextInput>
|
</RichTextInput>
|
||||||
|
|
||||||
|
<PlainTextBadge
|
||||||
|
bind:off={plainTextsHidden[index]}
|
||||||
|
on:toggle={() => {
|
||||||
|
plainTextsHidden[index] = !plainTextsHidden[index];
|
||||||
|
|
||||||
|
if (!plainTextsHidden[index]) {
|
||||||
|
plainTextInputs[index].api.refocus();
|
||||||
|
}
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
|
||||||
<PlainTextInput
|
<PlainTextInput
|
||||||
hidden={plainTextsHidden[index]}
|
hidden={plainTextsHidden[index]}
|
||||||
on:focusout={() => {
|
on:focusout={() => {
|
||||||
|
|
Loading…
Reference in a new issue