Skip to content

Commit ec96d25

Browse files
committed
修复问题
1 parent 9e7560c commit ec96d25

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
},
1010
"private": true,
1111
"version": "1.6.0",
12-
"buildDate": "2026/1/6 02:54:44",
12+
"buildDate": "2026/1/6 03:05:21",
1313
"main": "dist-electron/main.js",
1414
"type": "module",
1515
"scripts": {

src/components/ui/bg-stars/StarsBackground.vue

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,11 +71,17 @@
7171
</template>
7272

7373
<script setup lang="ts">
74-
import type { SpringOptions, Transition } from 'motion-v'
7574
import { cn } from '@/lib/utils'
7675
import { motion, useMotionValue, useSpring } from 'motion-v'
7776
import { computed, onMounted, ref, watch } from 'vue'
7877
78+
// 本地定义类型,因为 motion-v 不导出这些类型
79+
interface SpringOptions {
80+
stiffness?: number
81+
damping?: number
82+
mass?: number
83+
}
84+
7985
interface StarsBackgroundProps {
8086
factor?: number
8187
speed?: number
@@ -139,19 +145,19 @@
139145
}
140146
)
141147
142-
const starLayer1Transition = computed<Transition>(() => ({
148+
const starLayer1Transition = computed(() => ({
143149
repeat: Infinity,
144150
duration: props.speed,
145151
ease: 'linear' as const
146152
}))
147153
148-
const starLayer2Transition = computed<Transition>(() => ({
154+
const starLayer2Transition = computed(() => ({
149155
repeat: Infinity,
150156
duration: props.speed * 2,
151157
ease: 'linear' as const
152158
}))
153159
154-
const starLayer3Transition = computed<Transition>(() => ({
160+
const starLayer3Transition = computed(() => ({
155161
repeat: Infinity,
156162
duration: props.speed * 3,
157163
ease: 'linear' as const

0 commit comments

Comments
 (0)