32 lines
822 B
Vue
32 lines
822 B
Vue
<script setup lang="ts">
|
|
const ed = useEditor()
|
|
|
|
onMounted(() => {
|
|
const stop = ed.startLoop()
|
|
onBeforeUnmount(stop)
|
|
try {
|
|
if (!localStorage.getItem('logigate:help-seen')) ed.showHelp.value = true
|
|
} catch {}
|
|
})
|
|
</script>
|
|
|
|
<template>
|
|
<div class="app">
|
|
<EditorToolbar />
|
|
<div class="workspace">
|
|
<EditorPalette />
|
|
<main class="stage">
|
|
<EditorCanvas />
|
|
</main>
|
|
<EditorInspector />
|
|
</div>
|
|
<Transition name="fade">
|
|
<div v-if="ed.notice.value" class="toast" :class="ed.notice.value.kind">{{ ed.notice.value.text }}</div>
|
|
</Transition>
|
|
<div v-if="ed.placing.value" class="placing-hint">
|
|
Click on the canvas to place. <kbd>Shift</kbd> places several, <kbd>Esc</kbd> stops.
|
|
</div>
|
|
<EditorHelp v-if="ed.showHelp.value" />
|
|
</div>
|
|
</template>
|