中国算力平台算力登记系统2.0
yanzhaofeige
2024-09-30 3c4fee1db116c11d4f04727cfe076d7c94daeaf2
commit | author | age
43dc29 1 export default {
Y 2   computed: {
3     device() {
4       return this.$store.state.app.device
5     }
6   },
7   mounted() {
8     // In order to fix the click on menu on the ios device will trigger the mouseleave bug
9     this.fixBugIniOS()
10   },
11   methods: {
12     fixBugIniOS() {
13       const $subMenu = this.$refs.subMenu
14       if ($subMenu) {
15         const handleMouseleave = $subMenu.handleMouseleave
16         $subMenu.handleMouseleave = (e) => {
17           if (this.device === 'mobile') {
18             return
19           }
20           handleMouseleave(e)
21         }
22       }
23     }
24   }
25 }