|
@@ -12,7 +12,7 @@
|
|
|
<div
|
|
|
:class="[
|
|
|
tools[0].selected ? 'transform-scale-100' : 'transform-scale-0',
|
|
|
- 'overflow-hidden origin-top-right transition duration-300 z-999 h-100px w-180px bg-[rgba(11,21,44,1)] absolute right-62px top-0'
|
|
|
+ 'overflow-hidden origin-top-right transition duration-300 z-999 w-180px bg-[rgba(11,21,44,1)] absolute right-62px top-0'
|
|
|
]"
|
|
|
>
|
|
|
<ul class="flex flex-col gap-1 p-2">
|
|
@@ -28,11 +28,30 @@
|
|
|
</li>
|
|
|
</ul>
|
|
|
</div>
|
|
|
+ <div
|
|
|
+ :class="[
|
|
|
+ tools[3].selected ? 'transform-scale-100' : 'transform-scale-0',
|
|
|
+ 'overflow-hidden origin-top-right transition duration-300 z-999 w-180px bg-[rgba(11,21,44,1)] absolute right-62px top-180px'
|
|
|
+ ]"
|
|
|
+ >
|
|
|
+ <ul class="flex flex-col gap-1 p-2">
|
|
|
+ <li
|
|
|
+ class="flex gap-1 items-center cursor-pointer"
|
|
|
+ v-for="(item, ii) in twoList"
|
|
|
+ :key="ii"
|
|
|
+ @click="twoClick(ii)"
|
|
|
+ >
|
|
|
+ <img v-show="ii === twoActive" :src="item.yes" alt="" />
|
|
|
+ <img v-show="ii != twoActive" :src="item.no" alt="" />
|
|
|
+ <span>{{ item.name }}</span>
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
- import { getStaticResource } from '@/utils'
|
|
|
+ import { getStaticResource, $mitt } from '@/utils'
|
|
|
|
|
|
const tools = ref([
|
|
|
{
|
|
@@ -47,6 +66,12 @@
|
|
|
no: getStaticResource('assets/images/gn-no-bg.png'),
|
|
|
selected: false
|
|
|
},
|
|
|
+ {
|
|
|
+ icon: getStaticResource('assets/images/gn3-icon.png'),
|
|
|
+ yes: getStaticResource('assets/images/gn-yes-bg.png'),
|
|
|
+ no: getStaticResource('assets/images/gn-no-bg.png'),
|
|
|
+ selected: false
|
|
|
+ },
|
|
|
{
|
|
|
icon: getStaticResource('assets/images/gn3-icon.png'),
|
|
|
yes: getStaticResource('assets/images/gn-yes-bg.png'),
|
|
@@ -79,8 +104,24 @@
|
|
|
no: getStaticResource('assets/images/no-icon.png')
|
|
|
}
|
|
|
])
|
|
|
-
|
|
|
const oneClick = (i) => {
|
|
|
oneActive.value = i
|
|
|
}
|
|
|
+ const twoActive = ref(0)
|
|
|
+ const twoList = ref([
|
|
|
+ {
|
|
|
+ name: '指标一',
|
|
|
+ yes: getStaticResource('assets/images/yes-icon.png'),
|
|
|
+ no: getStaticResource('assets/images/no-icon.png')
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: '指标二',
|
|
|
+ yes: getStaticResource('assets/images/yes-icon.png'),
|
|
|
+ no: getStaticResource('assets/images/no-icon.png')
|
|
|
+ }
|
|
|
+ ])
|
|
|
+ const twoClick = (i) => {
|
|
|
+ twoActive.value = i
|
|
|
+ $mitt.emit('onTheme', i)
|
|
|
+ }
|
|
|
</script>
|