hookehuyr

✨ feat(快捷访问控件): 新增自定义sytle,z-index提高

<!--
* @Date: 2022-05-11 11:19:14
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2022-06-24 09:19:27
* @LastEditTime: 2022-06-24 13:19:43
* @FilePath: /tswj/src/components/ShortcutFixed/index.vue
* @Description: 文件描述
-->
<template>
<div class="shortcut-page">
<div class="shortcut-page" :style="customStyle">
<van-image v-if="isHome" class="icon-box" :src="icon_home" @click="toHome" />
<van-image v-if="isMe" class="icon-box" :src="icon_me" @click="toMe" />
<van-image v-if="isRank" class="icon-box" :src="icon_rank" @click="toRank" />
......@@ -21,7 +21,7 @@ import { icon_me, icon_home, icon_rank } from '@/utils/generateIcons.js'
<script>
// FIXME: VUE2写法
export default {
props: ['type', 'item'],
props: ['type', 'item', 'customStyle'],
data() {
return {
userType: Cookies.get('userType') ? Cookies.get('userType') : ''
......@@ -97,7 +97,7 @@ export default {
bottom: 18rem;
right: 1rem;
overflow: auto;
z-index: 169;
z-index: 999;
width: 3rem;
}
.icon-box {
......
......@@ -49,7 +49,7 @@
</div>
<div style="height: 5rem" />
<donate-bar :donate-type="donateType">爱心助力</donate-bar>
<shortcut-fixed :type="USER_ROLE.CLIENT" :item="shortcutItem" />
<shortcut-fixed :type="USER_ROLE.CLIENT" :item="shortcutItem" :custom-style="customStyle" />
</div>
</template>
......@@ -82,6 +82,9 @@ if (isClient) {
} else {
shortcutItem.value = ['me']
}
const customStyle = {
bottom: '8rem'
}
const userType = Cookies.get('userType')
// 判断是访客进入还是幼儿园进入
......