mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 07:22:23 -04:00

* Move remove-prohibited-tags logic from PlainTextInput * Make CodeMirror export a promise * Offer lifecycle hooks for PlainTextInput for easily accessing code mirror instance * Fix </> breaking Mathjax * remove debug statement (dae)
21 lines
602 B
Svelte
21 lines
602 B
Svelte
<!--
|
|
Copyright: Ankitects Pty Ltd and contributors
|
|
License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|
-->
|
|
<script context="module" lang="ts">
|
|
import { CustomElementArray } from "../editable/decorated";
|
|
import contextProperty from "../sveltelib/context-property";
|
|
|
|
const decoratedElements = new CustomElementArray();
|
|
|
|
const key = Symbol("decoratedElements");
|
|
const [context, setContextProperty] = contextProperty<CustomElementArray>(key);
|
|
|
|
export { context };
|
|
</script>
|
|
|
|
<script lang="ts">
|
|
setContextProperty(decoratedElements);
|
|
</script>
|
|
|
|
<slot />
|