Skip to content

Commit 4971b12

Browse files
committed
feat (core): 移除 Switch 组件未使用属性
1 parent 978d64c commit 4971b12

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/ui/Switch.vue

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747

4848
<script setup lang="ts">
4949
import type { Component } from 'vue'
50-
import { computed, useAttrs } from 'vue'
50+
import { computed } from 'vue'
5151
5252
interface Props
5353
{
@@ -95,11 +95,6 @@ const emit = defineEmits<{
9595
change: [value: boolean, event: Event]
9696
}>()
9797
98-
const attrs = useAttrs()
99-
100-
// 生成唯一 ID
101-
const switchId = computed(() => props.id || `switch-${ Math.random().toString(36).substr(2, 9) }`)
102-
10398
// 包装器样式
10499
const wrapperClasses = computed(() => [
105100
'inline-flex items-center gap-3',

0 commit comments

Comments
 (0)