mirror of
https://codeberg.org/SafeTwitch/safetwitch.git
synced 2025-01-09 06:10:07 -05:00
Add version footer
This commit is contained in:
parent
8b78363784
commit
87ca3b79d6
4 changed files with 24 additions and 3 deletions
|
@ -9,7 +9,7 @@
|
||||||
<link rel="manifest" href="/site.webmanifest">
|
<link rel="manifest" href="/site.webmanifest">
|
||||||
<title>SafeTwitch</title>
|
<title>SafeTwitch</title>
|
||||||
</head>
|
</head>
|
||||||
<body class="bg-ctp-base">
|
<body class="bg-ctp-base flex flex-col">
|
||||||
<div id="app"></div>
|
<div id="app"></div>
|
||||||
<script type="module" src="/src/main.ts"></script>
|
<script type="module" src="/src/main.ts"></script>
|
||||||
</body>
|
</body>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "test",
|
"name": "test",
|
||||||
"version": "0.0.0",
|
"version": "1.1.3",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "run-p type-check build-only",
|
"build": "run-p type-check build-only",
|
||||||
|
|
|
@ -1,16 +1,19 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { RouterView } from 'vue-router'
|
import { RouterView } from 'vue-router'
|
||||||
import NavbarItem from './components/NavbarView.vue'
|
import NavbarItem from './components/NavbarView.vue'
|
||||||
|
import FooterItem from './components/FooterView.vue'
|
||||||
import DevWarning from './components/DevWarning.vue'
|
import DevWarning from './components/DevWarning.vue'
|
||||||
|
|
||||||
const dev = import.meta.env.DEV
|
const dev = import.meta.env.DEV
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template class="bg-ctp-base h-full">
|
<template class="bg-ctp-base h-full flex flex-row">
|
||||||
<dev-warning v-if="dev"></dev-warning>
|
<dev-warning v-if="dev"></dev-warning>
|
||||||
<navbar-item></navbar-item>
|
<navbar-item></navbar-item>
|
||||||
|
|
||||||
<Suspense>
|
<Suspense>
|
||||||
<RouterView :key="$route.fullPath" />
|
<RouterView :key="$route.fullPath" />
|
||||||
</Suspense>
|
</Suspense>
|
||||||
|
|
||||||
|
<footer-item></footer-item>
|
||||||
</template>
|
</template>
|
||||||
|
|
18
src/components/FooterView.vue
Normal file
18
src/components/FooterView.vue
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
<script lang="ts">
|
||||||
|
import { inject } from 'vue'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
setup() {
|
||||||
|
const version = inject('version')
|
||||||
|
return {
|
||||||
|
version
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div class="m-2 mt-5 flex justify-center">
|
||||||
|
<p class="text-white font-bold">SafeTwitch v{{ version }}</p>
|
||||||
|
</div>
|
||||||
|
</template>
|
Loading…
Reference in a new issue