fix components: BackToPrevious

This commit is contained in:
KUN1007 2023-06-01 00:16:19 +08:00
parent 5dded87523
commit e7b30a7f65
6 changed files with 20 additions and 15 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 KiB

After

Width:  |  Height:  |  Size: 550 KiB

View file

@ -1,15 +1,17 @@
<script setup lang="ts">
// Vue template '<' msg
const msg = '< 返回主页'
import { useRouter } from 'vue-router'
const router = useRouter()
const msg = '< 返回上一页'
</script>
<template>
<router-link to="/">
<!-- 返回主页 -->
<div class="return">
<span>{{ msg }}</span>
</div>
</router-link>
<!-- 返回主页 -->
<div class="return" @click="router.back()">
<span>{{ msg }}</span>
</div>
</template>
<style lang="scss" scoped>

View file

@ -17,17 +17,19 @@ import { calculateTotalAmount } from './log'
<div class="title">{{ $t('balance.pl') }}</div>
<!-- 内容区 -->
<div class="content">
<!-- 是收入表的话就渲染为蓝色 -->
<Form :isIncome="true" />
<Form />
</div>
<!-- 收入支出总结 -->
<!-- 经济状态 -->
<div class="sum">
<!-- 经济状态 -->
<!-- 亏损和盈余的样式不一样 -->
<div
class="amount-status-deficit"
:class="calculateTotalAmount() >= 0 ? 'amount-status-surplus' : ''"
>
<div>
<!-- i18n -->
{{ $t('balance.status') }}:
<span>{{
calculateTotalAmount() >= 0
@ -36,6 +38,7 @@ import { calculateTotalAmount } from './log'
}}</span>
</div>
<div>
<!-- i18n -->
{{
calculateTotalAmount() >= 0
? $t('balance.surplusAmount')

View file

@ -48,10 +48,10 @@ export const FSLog: FS[] = [
},
{
index: 6,
income: false,
income: true,
reason: '啊这可海星',
date: '2019/10/07',
amount: 1007,
amount: 10007,
},
{
index: 7,

View file

@ -1,7 +1,7 @@
<script setup lang="ts">
import { Icon } from '@iconify/vue'
import BackToHome from '@/components/BackToHome.vue'
import KUNGalgameFooter from '@/components/KUNGalgameFooter.vue'
import BackToPrevious from '@/components/BackToPrevious.vue'
</script>
<template>
@ -29,7 +29,7 @@ import KUNGalgameFooter from '@/components/KUNGalgameFooter.vue'
<Icon class="icon" icon="ri:bilibili-line" />
</div>
</div>
<BackToHome />
<BackToPrevious />
<!-- 版权 -->
<KUNGalgameFooter
style="position: absolute; bottom: -20%; white-space: nowrap"

View file

@ -1,5 +1,5 @@
<script setup lang="ts">
import BackToHome from '@/components/BackToHome.vue'
import BackToPrevious from '@/components/BackToPrevious.vue'
import KUNGalgameFooter from '@/components/KUNGalgameFooter.vue'
</script>
@ -32,7 +32,7 @@ import KUNGalgameFooter from '@/components/KUNGalgameFooter.vue'
</li>
<li>设备相关设备日期操作系统信息等方便我们对设备进行适配</li>
</ul>
<BackToHome />
<BackToPrevious />
</div>
<!-- 版权 -->
<KUNGalgameFooter style="position: absolute; bottom: -40px" />