feat: quick bottom home screen setup
This commit is contained in:
@@ -20,5 +20,10 @@ const showStats = ref(false);
|
||||
<Stats v-if="showStats" />
|
||||
</TopScreen>
|
||||
</div>
|
||||
<div>
|
||||
<HomeBottomScreen>
|
||||
<Stats v-if="showStats" />
|
||||
</HomeBottomScreen>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
BIN
app/assets/home-screen_bottom_background.png
Normal file
BIN
app/assets/home-screen_bottom_background.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 145 KiB |
17
app/components/Home/BottomScreen/Background.vue
Normal file
17
app/components/Home/BottomScreen/Background.vue
Normal file
@@ -0,0 +1,17 @@
|
||||
<script setup lang="ts">
|
||||
const backgroundImage = useTemplateRef("backgroundImage");
|
||||
|
||||
useRender((ctx) => {
|
||||
if (!backgroundImage.value) return;
|
||||
|
||||
ctx.drawImage(backgroundImage.value, 0, 0);
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<img
|
||||
ref="backgroundImage"
|
||||
src="/assets/home-screen_bottom_background.png"
|
||||
hidden
|
||||
/>
|
||||
</template>
|
||||
7
app/components/Home/BottomScreen/BottomScreen.vue
Normal file
7
app/components/Home/BottomScreen/BottomScreen.vue
Normal file
@@ -0,0 +1,7 @@
|
||||
<template>
|
||||
<Screen>
|
||||
<HomeBottomScreenBackground />
|
||||
|
||||
<slot />
|
||||
</Screen>
|
||||
</template>
|
||||
Reference in New Issue
Block a user