feat: 新增「猫咪设置 > 窗口设置 > 镜像模式」配置项 (#66)

This commit is contained in:
ayangweb
2025-04-22 22:08:46 +08:00
committed by GitHub
parent a40b612a30
commit 905ce2969f
3 changed files with 7 additions and 0 deletions

View File

@@ -36,5 +36,9 @@ const modeList: SelectProps['options'] = [
<ProListItem title="透明度" vertical>
<Slider v-model:value="catStore.opacity" class="m-0!" />
</ProListItem>
<ProListItem title="镜像模式">
<Switch v-model:checked="catStore.mirrorMode" />
</ProListItem>
</ProList>
</template>

View File

@@ -52,6 +52,7 @@ function resolveImageURL(key: string) {
<template>
<div
class="relative children:(absolute h-screen w-screen)"
:class="[catStore.mirrorMode ? '-scale-x-100' : 'scale-x-100']"
:style="{ opacity: catStore.opacity / 100 }"
@mousedown="handleWindowDrag"
>

View File

@@ -5,10 +5,12 @@ export const useCatStore = defineStore('cat', () => {
const mode = ref<'standard' | 'keyboard'>('standard')
const penetrable = ref(false)
const opacity = ref(100)
const mirrorMode = ref(false)
return {
mode,
penetrable,
opacity,
mirrorMode,
}
})