@@ -30,6 +30,8 @@ import SearchNav from '../components/SearchNav.vue'
3030import Menu from ' ../components/Menu.vue'
3131import AutoLogout from ' ../components/AutoLogout.vue'
3232import ChatWidget from ' ../components/ChatWidget.vue'
33+ import { Splitpanes , Pane } from ' splitpanes'
34+ import ' splitpanes/dist/splitpanes.css'
3335import { onMounted , ref , computed } from ' vue'
3436import { getCurrentUser } from ' ../obp'
3537import { useRoute } from ' vue-router'
@@ -53,49 +55,53 @@ const isChatbotEnabled = import.meta.env.VITE_CHATBOT_ENABLED === 'true'
5355<template >
5456
5557 <AutoLogout v-if =isLoggedIn />
56- <el-container class =" root" >
57- <el-aside class =" search-nav" width =" 20%" >
58- <!-- Left-->
59- <SearchNav />
60- </el-aside >
61- <el-main >
62- <el-container class =" main" >
63- <!-- <el-header class="collections">
64- <Collections />
65- </el-header>-->
66- <el-header class =" menu" >
58+ <Splitpanes class =" root" >
59+ <Pane :size =" 20" :min-size =" 10" :max-size =" 40" >
60+ <div class =" search-nav" >
61+ <!-- Left-->
62+ <SearchNav />
63+ </div >
64+ </Pane >
65+ <Pane :size =" 80" >
66+ <div class =" main" >
67+ <div class =" menu" >
6768 <Menu />
68- </el-header >
69- <el-container class =" middle" >
70- <el-aside class =" summary" :width =" hasOperationId ? '50%' : '100%'" >
69+ </div >
70+ <Splitpanes v-if =" hasOperationId" class =" middle" >
71+ <Pane :size =" 50" >
72+ <div class =" summary" >
73+ <RouterView name =" body" />
74+ </div >
75+ </Pane >
76+ <Pane :size =" 50" >
77+ <div class =" preview" >
78+ <RouterView name =" preview" />
79+ </div >
80+ </Pane >
81+ </Splitpanes >
82+ <div v-else class =" middle" >
83+ <div class =" summary" >
7184 <RouterView name =" body" />
72- </el-aside >
73- <el-main v-if =" hasOperationId" class =" preview" >
74- <!-- right -->
75- <RouterView class =" preview" name =" preview" />
76- </el-main >
77- </el-container >
78-
79- <!-- <el-footer> -->
80- <!-- Bottom -->
81- <!-- Footer
82- </el-footer>-->
83- </el-container >
85+ </div >
86+ </div >
87+ </div >
8488 <ChatWidget v-if =" isChatbotEnabled" />
85- </el-main >
86- </el-container >
89+ </Pane >
90+ </Splitpanes >
8791</template >
8892
8993<style >
9094.root {
9195 height : 100% ;
92- /* min-height: 100vh; */
9396}
9497.summary {
95- max-height : 100% ;
98+ height : 100% ;
99+ overflow : auto ;
96100}
97101.main {
98102 height : 100% ;
103+ display : flex ;
104+ flex-direction : column ;
99105 overflow : hidden ;
100106}
101107.search-nav {
@@ -104,18 +110,30 @@ const isChatbotEnabled = import.meta.env.VITE_CHATBOT_ENABLED === 'true'
104110 overflow : hidden ;
105111}
106112.middle {
107- height : 100 % ;
113+ flex : 1 ;
108114 overflow : hidden ;
109115}
110116.preview {
111117 color : white ;
112118 background-color : #151d30 ;
113- max-height : 100% ;
119+ height : 100% ;
120+ overflow : auto ;
114121}
115122.collections {
116123 margin-left : -20px ;
117124 margin-right : -20px ;
118125 padding-left : 20px ;
119126 padding-right : 20px ;
120127}
128+
129+ /* Splitpanes handle styling */
130+ .splitpanes--vertical > .splitpanes__splitter {
131+ width : 5px ;
132+ background-color : #dcdfe6 ;
133+ border : none ;
134+ cursor : col-resize ;
135+ }
136+ .splitpanes--vertical > .splitpanes__splitter :hover {
137+ background-color : #409eff ;
138+ }
121139 </style >
0 commit comments