ace editor

This commit is contained in:
Jan Prochazka
2021-03-11 08:17:06 +01:00
parent c193955fbe
commit a93aff1bb7
5 changed files with 21 additions and 3 deletions

View File

@@ -3,6 +3,7 @@
import { closeModal } from './modalTools';
import clickOutside from '../utility/clickOutside';
import keycodes from '../utility/keycodes';
import { onMount } from 'svelte';
export let fullScreen = false;
export let noPadding = false;
@@ -17,6 +18,13 @@
closeModal(modalId);
}
}
onMount(() => {
const oldFocus = document.activeElement;
return () => {
if (oldFocus) oldFocus.focus();
};
});
</script>
<!-- The Modal -->