fix: 百科全书退出后按键失效

This commit is contained in:
unanmed 2023-11-20 20:05:54 +08:00
parent c423750885
commit a2639e63db

View File

@ -18,7 +18,7 @@
</template>
<script lang="ts" setup>
import { computed, ref } from 'vue';
import { computed, onUnmounted, ref } from 'vue';
import desc from '../data/desc.json';
import { splitText } from '../plugin/utils';
import Colomn from '../components/colomn.vue';
@ -59,6 +59,10 @@ gameKey
.realize('desc', () => {
exit();
});
onUnmounted(() => {
gameKey.dispose(props.ui.symbol);
});
</script>
<style lang="less" scoped>