Showing
3 changed files
with
21 additions
and
9 deletions
| ... | @@ -7,11 +7,20 @@ export {} | ... | @@ -7,11 +7,20 @@ export {} |
| 7 | /* prettier-ignore */ | 7 | /* prettier-ignore */ |
| 8 | declare module 'vue' { | 8 | declare module 'vue' { |
| 9 | export interface GlobalComponents { | 9 | export interface GlobalComponents { |
| 10 | + ElBreadcrumb: typeof import('element-ui/lib/breadcrumb')['default'] | ||
| 11 | + ElBreadcrumbItem: typeof import('element-ui/lib/breadcrumb-item')['default'] | ||
| 12 | + ElCarousel: typeof import('element-ui/lib/carousel')['default'] | ||
| 13 | + ElCarouselItem: typeof import('element-ui/lib/carousel-item')['default'] | ||
| 10 | ElCheckbox: typeof import('element-ui/lib/checkbox')['default'] | 14 | ElCheckbox: typeof import('element-ui/lib/checkbox')['default'] |
| 11 | ElCol: typeof import('element-ui/lib/col')['default'] | 15 | ElCol: typeof import('element-ui/lib/col')['default'] |
| 16 | + ElCollapse: typeof import('element-ui/lib/collapse')['default'] | ||
| 17 | + ElCollapseItem: typeof import('element-ui/lib/collapse-item')['default'] | ||
| 12 | ElCollapseTransition: typeof import('element-ui/lib/transitions/collapse-transition')['default'] | 18 | ElCollapseTransition: typeof import('element-ui/lib/transitions/collapse-transition')['default'] |
| 13 | ElImage: typeof import('element-ui/lib/image')['default'] | 19 | ElImage: typeof import('element-ui/lib/image')['default'] |
| 20 | + ElInput: typeof import('element-ui/lib/input')['default'] | ||
| 21 | + ElOption: typeof import('element-ui/lib/option')['default'] | ||
| 14 | ElRow: typeof import('element-ui/lib/row')['default'] | 22 | ElRow: typeof import('element-ui/lib/row')['default'] |
| 23 | + ElSelect: typeof import('element-ui/lib/select')['default'] | ||
| 15 | ElTooltip: typeof import('element-ui/lib/tooltip')['default'] | 24 | ElTooltip: typeof import('element-ui/lib/tooltip')['default'] |
| 16 | HagerBox: typeof import('./src/components/common/hagerBox.vue')['default'] | 25 | HagerBox: typeof import('./src/components/common/hagerBox.vue')['default'] |
| 17 | HagerCarousel: typeof import('./src/components/hagerCarousel.vue')['default'] | 26 | HagerCarousel: typeof import('./src/components/hagerCarousel.vue')['default'] | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2024-09-26 13:42:11 | 2 | * @Date: 2024-09-26 13:42:11 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2024-10-18 09:34:29 | 4 | + * @LastEditTime: 2024-10-20 13:01:08 |
| 5 | * @FilePath: /hager/src/components/common/hagerHeader.vue | 5 | * @FilePath: /hager/src/components/common/hagerHeader.vue |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | --> | 7 | --> |
| ... | @@ -434,7 +434,7 @@ export default { | ... | @@ -434,7 +434,7 @@ export default { |
| 434 | }, | 434 | }, |
| 435 | goToLogin () { | 435 | goToLogin () { |
| 436 | this.$router.push({ | 436 | this.$router.push({ |
| 437 | - path: '/login' | 437 | + path: '/user/login' |
| 438 | }); | 438 | }); |
| 439 | }, | 439 | }, |
| 440 | openMenu () { | 440 | openMenu () { | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2024-10-18 17:57:33 | 2 | * @Date: 2024-10-18 17:57:33 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2024-10-20 12:10:21 | 4 | + * @LastEditTime: 2024-10-20 13:19:23 |
| 5 | * @FilePath: /hager/src/views/user/index.vue | 5 | * @FilePath: /hager/src/views/user/index.vue |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | --> | 7 | --> |
| ... | @@ -9,13 +9,13 @@ | ... | @@ -9,13 +9,13 @@ |
| 9 | <div class="hager-user-page"> | 9 | <div class="hager-user-page"> |
| 10 | <div class="centered-div"> | 10 | <div class="centered-div"> |
| 11 | <el-row> | 11 | <el-row> |
| 12 | - <el-col :span="14"> | 12 | + <el-col :span="13"> |
| 13 | <div class="user-box" style="background-color: #EFF7FB;"> | 13 | <div class="user-box" style="background-color: #EFF7FB;"> |
| 14 | <div class="user-logo"></div> | 14 | <div class="user-logo"></div> |
| 15 | <div class="user-bg"></div> | 15 | <div class="user-bg"></div> |
| 16 | </div> | 16 | </div> |
| 17 | </el-col> | 17 | </el-col> |
| 18 | - <el-col :span="10"> | 18 | + <el-col :span="11"> |
| 19 | <router-view id="router-view"></router-view> | 19 | <router-view id="router-view"></router-view> |
| 20 | </el-col> | 20 | </el-col> |
| 21 | </el-row> | 21 | </el-row> |
| ... | @@ -36,18 +36,21 @@ export default { | ... | @@ -36,18 +36,21 @@ export default { |
| 36 | }, | 36 | }, |
| 37 | mounted () { | 37 | mounted () { |
| 38 | // 设置用户盒子高度 | 38 | // 设置用户盒子高度 |
| 39 | - this.handleResize(); | 39 | + // this.handleHeight(); |
| 40 | // 监听窗口的 resize 事件 | 40 | // 监听窗口的 resize 事件 |
| 41 | - window.addEventListener('resize', this.handleResize); | 41 | + window.addEventListener('resize', this.handleHeight); |
| 42 | }, | 42 | }, |
| 43 | methods: { | 43 | methods: { |
| 44 | - handleResize () { | 44 | + handleHeight () { |
| 45 | + // | ||
| 46 | + if ($('#router-view').outerHeight() > $('.user-box').height()) { | ||
| 45 | $('.user-box').height($('#router-view').outerHeight()) | 47 | $('.user-box').height($('#router-view').outerHeight()) |
| 46 | } | 48 | } |
| 49 | + } | ||
| 47 | }, | 50 | }, |
| 48 | beforeDestroy() { | 51 | beforeDestroy() { |
| 49 | // 在组件销毁前移除监听器,防止内存泄漏 | 52 | // 在组件销毁前移除监听器,防止内存泄漏 |
| 50 | - window.removeEventListener('resize', this.handleResize); | 53 | + window.removeEventListener('resize', this.handleHeight); |
| 51 | } | 54 | } |
| 52 | } | 55 | } |
| 53 | </script> | 56 | </script> | ... | ... |
-
Please register or login to post a comment