11<template >
22 <div
33 class =" sidebar-left-container"
4- :class =" { 'is-collapsed': !uiStore .leftSidebarVisible }"
4+ :class =" { 'is-collapsed': !windowStore .leftSidebarVisible }"
55 >
66 <nav class =" activity-bar" >
77 <div class =" nav-top" >
88 <div
99 class =" nav-item"
1010 :class =" {
1111 active:
12- uiStore .activeLeftPanelName === 'chunkList' &&
13- uiStore .leftSidebarVisible,
12+ windowStore .activeLeftPanelName === 'chunkList' &&
13+ windowStore .leftSidebarVisible,
1414 }"
1515 title =" 文件列表"
16- @click =" uiStore .setLeftPanel('chunkList')"
16+ @click =" windowStore .setLeftPanel('chunkList')"
1717 >
1818 <FolderOpen class="ui-icon" />
1919 </div >
2020 <div
2121 class =" nav-item"
2222 :class =" {
2323 active:
24- uiStore .activeLeftPanelName === 'identity' &&
25- uiStore .leftSidebarVisible,
24+ windowStore .activeLeftPanelName === 'identity' &&
25+ windowStore .leftSidebarVisible,
2626 }"
2727 title =" 身份管理"
28- @click =" uiStore .setLeftPanel('identity')"
28+ @click =" windowStore .setLeftPanel('identity')"
2929 >
3030 <UserRound class="ui-icon" />
3131 </div >
3232 <div
3333 class =" nav-item"
3434 :class =" {
3535 active:
36- uiStore .activeLeftPanelName === 'ruleEditor' &&
37- uiStore .leftSidebarVisible,
36+ windowStore .activeLeftPanelName === 'ruleEditor' &&
37+ windowStore .leftSidebarVisible,
3838 }"
3939 title =" 染色规则"
40- @click =" uiStore .setLeftPanel('ruleEditor')"
40+ @click =" windowStore .setLeftPanel('ruleEditor')"
4141 >
4242 <Palette class="ui-icon" />
4343 </div >
4444 <div
4545 class =" nav-item"
4646 :class =" {
4747 active:
48- uiStore .activeLeftPanelName === 'search' &&
49- uiStore .leftSidebarVisible,
48+ windowStore .activeLeftPanelName === 'search' &&
49+ windowStore .leftSidebarVisible,
5050 }"
5151 title =" 搜索过滤"
52- @click =" uiStore .setLeftPanel('search')"
52+ @click =" windowStore .setLeftPanel('search')"
5353 >
5454 <Search class="ui-icon" />
5555 </div >
5656 <div
5757 class =" nav-item"
5858 :class =" {
5959 active:
60- uiStore.activeLeftPanelName === 'exportFormat' &&
61- uiStore.leftSidebarVisible,
60+ windowStore.activeLeftPanelName ===
61+ 'exportFormat' &&
62+ windowStore.leftSidebarVisible,
6263 }"
6364 title =" 导出模板"
64- @click =" uiStore .setLeftPanel('exportFormat')"
65+ @click =" windowStore .setLeftPanel('exportFormat')"
6566 >
6667 <TextInitial class="ui-icon" />
6768 </div >
166167 </nav >
167168
168169 <aside
169- v-if =" uiStore .leftSidebarVisible"
170+ v-if =" windowStore .leftSidebarVisible"
170171 class =" side-panel"
171172 :style =" { width: uiStore.leftPanelWidth + 'px' }"
172173 >
173174 <div class =" panel-content" >
174175 <div
175- v-if =" uiStore .activeLeftPanelName === 'chunkList'"
176+ v-if =" windowStore .activeLeftPanelName === 'chunkList'"
176177 class =" panel-slot"
177178 >
178179 <ChunkListPanel />
179180 </div >
180181 <div
181- v-else-if =" uiStore .activeLeftPanelName === 'identity'"
182+ v-else-if =" windowStore .activeLeftPanelName === 'identity'"
182183 class =" panel-slot"
183184 >
184185 <IdentityPanel />
185186 </div >
186187 <div
187- v-else-if =" uiStore .activeLeftPanelName === 'ruleEditor'"
188+ v-else-if =" windowStore .activeLeftPanelName === 'ruleEditor'"
188189 class =" panel-slot"
189190 >
190191 <RuleEditorPanel />
191192 </div >
192193 <div
193- v-else-if =" uiStore .activeLeftPanelName === 'search'"
194+ v-else-if =" windowStore .activeLeftPanelName === 'search'"
194195 class =" panel-slot"
195196 >
196197 <SearchPanel />
197198 </div >
198199 <div
199- v-else-if =" uiStore.activeLeftPanelName === 'exportFormat'"
200+ v-else-if ="
201+ windowStore.activeLeftPanelName === 'exportFormat'
202+ "
200203 class =" panel-slot"
201204 >
202205 <ExportFormatPanel />
205208 </aside >
206209
207210 <div
208- v-if =" uiStore .leftSidebarVisible"
211+ v-if =" windowStore .leftSidebarVisible"
209212 class =" resize-handle"
210213 @mousedown =" startResize"
211214 ></div >
@@ -226,13 +229,15 @@ import {
226229import { ref , onMounted , onUnmounted , watch } from ' vue' ;
227230import { useStyleStore } from ' @/stores/styleStore' ;
228231import { useUiStore , PANEL_MIN_WIDTH , PANEL_MAX_WIDTH } from ' @/stores/uiStore' ;
232+ import { useWindowStore } from ' @/stores/windowStore' ;
229233import ChunkListPanel from ' @/components/panels/ChunkListPanel.vue' ;
230234import IdentityPanel from ' @/components/panels/IdentityPanel.vue' ;
231235import RuleEditorPanel from ' @/components/panels/RuleEditorPanel.vue' ;
232236import ExportFormatPanel from ' @/components/panels/ExportFormatPanel.vue' ;
233237import SearchPanel from ' @/components/panels/SearchPanel.vue' ;
234238
235239const uiStore = useUiStore ();
240+ const windowStore = useWindowStore ();
236241const styleStore = useStyleStore ();
237242const showSettings = ref (false );
238243const closeSettings = () => {
0 commit comments