diff --git a/src/assets/styles/sidebar.scss b/src/assets/styles/sidebar.scss index 8b3c472..7c982fa 100644 --- a/src/assets/styles/sidebar.scss +++ b/src/assets/styles/sidebar.scss @@ -115,10 +115,14 @@ .sidebar-container { width: 54px !important; } + .main-container { margin-left: 54px; } + .layMain-container { + margin-left: 0 !important; + } .sub-menu-title-noDropdown { padding: 0 !important; diff --git a/src/layout/components/Sidebar/index.vue b/src/layout/components/Sidebar/index.vue index 9b14dfc..ad35581 100644 --- a/src/layout/components/Sidebar/index.vue +++ b/src/layout/components/Sidebar/index.vue @@ -36,7 +36,12 @@ const appStore = useAppStore() const settingsStore = useSettingsStore() const permissionStore = usePermissionStore() -const sidebarRouters = computed(() => permissionStore.sidebarRouters); +const sidebarRouters = computed(() => permissionStore.sidebarRouters.filter((item) => { + return item.path === localStorage.getItem('CURRENT_MENU'); +})); +// const sidebarRouters = computed(() => permissionStore.sidebarRouters.filter((item) => { +// return item.path === localStorage.getItem('CURRENT_MENU') +// })); const showLogo = computed(() => settingsStore.sidebarLogo); const sideTheme = computed(() => settingsStore.sideTheme); const theme = computed(() => settingsStore.theme); diff --git a/src/layoutMain/components/AppMain.vue b/src/layoutMain/components/AppMain.vue new file mode 100644 index 0000000..42fffdf --- /dev/null +++ b/src/layoutMain/components/AppMain.vue @@ -0,0 +1,68 @@ + + + + + + + + diff --git a/src/layoutMain/components/IframeToggle/index.vue b/src/layoutMain/components/IframeToggle/index.vue new file mode 100644 index 0000000..2b8269b --- /dev/null +++ b/src/layoutMain/components/IframeToggle/index.vue @@ -0,0 +1,27 @@ + + + diff --git a/src/layoutMain/components/InnerLink/index.vue b/src/layoutMain/components/InnerLink/index.vue new file mode 100644 index 0000000..53a903c --- /dev/null +++ b/src/layoutMain/components/InnerLink/index.vue @@ -0,0 +1,24 @@ + + + diff --git a/src/layoutMain/components/Navbar.vue b/src/layoutMain/components/Navbar.vue new file mode 100644 index 0000000..8dc70b7 --- /dev/null +++ b/src/layoutMain/components/Navbar.vue @@ -0,0 +1,188 @@ + + + + + diff --git a/src/layoutMain/components/Settings/index.vue b/src/layoutMain/components/Settings/index.vue new file mode 100644 index 0000000..3360959 --- /dev/null +++ b/src/layoutMain/components/Settings/index.vue @@ -0,0 +1,241 @@ + + + + + \ No newline at end of file diff --git a/src/layoutMain/components/Sidebar/Link.vue b/src/layoutMain/components/Sidebar/Link.vue new file mode 100644 index 0000000..8011431 --- /dev/null +++ b/src/layoutMain/components/Sidebar/Link.vue @@ -0,0 +1,40 @@ + + + diff --git a/src/layoutMain/components/Sidebar/Logo.vue b/src/layoutMain/components/Sidebar/Logo.vue new file mode 100644 index 0000000..67582d0 --- /dev/null +++ b/src/layoutMain/components/Sidebar/Logo.vue @@ -0,0 +1,81 @@ + + + + + \ No newline at end of file diff --git a/src/layoutMain/components/Sidebar/SidebarItem.vue b/src/layoutMain/components/Sidebar/SidebarItem.vue new file mode 100644 index 0000000..7adac23 --- /dev/null +++ b/src/layoutMain/components/Sidebar/SidebarItem.vue @@ -0,0 +1,102 @@ + + + diff --git a/src/layoutMain/components/Sidebar/index.vue b/src/layoutMain/components/Sidebar/index.vue new file mode 100644 index 0000000..9b14dfc --- /dev/null +++ b/src/layoutMain/components/Sidebar/index.vue @@ -0,0 +1,54 @@ + + + diff --git a/src/layoutMain/components/TagsView/ScrollPane.vue b/src/layoutMain/components/TagsView/ScrollPane.vue new file mode 100644 index 0000000..516b5d2 --- /dev/null +++ b/src/layoutMain/components/TagsView/ScrollPane.vue @@ -0,0 +1,105 @@ + + + + + \ No newline at end of file diff --git a/src/layoutMain/components/TagsView/index.vue b/src/layoutMain/components/TagsView/index.vue new file mode 100644 index 0000000..c1b7e3f --- /dev/null +++ b/src/layoutMain/components/TagsView/index.vue @@ -0,0 +1,338 @@ + + + + + + + \ No newline at end of file diff --git a/src/layoutMain/components/index.js b/src/layoutMain/components/index.js new file mode 100644 index 0000000..fd57731 --- /dev/null +++ b/src/layoutMain/components/index.js @@ -0,0 +1,4 @@ +export { default as AppMain } from './AppMain' +export { default as Navbar } from './Navbar' +export { default as Settings } from './Settings' +export { default as TagsView } from './TagsView/index.vue' diff --git a/src/layoutMain/index.vue b/src/layoutMain/index.vue new file mode 100644 index 0000000..98e43da --- /dev/null +++ b/src/layoutMain/index.vue @@ -0,0 +1,108 @@ + + + + + \ No newline at end of file diff --git a/src/router/index.js b/src/router/index.js index d0b8355..25c4ec5 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -4,6 +4,7 @@ import { } from 'vue-router' /* Layout */ import Layout from '@/layout' +import LayoutMain from '@/layoutMain' /** * Note: 路由配置项 @@ -59,7 +60,7 @@ export const constantRoutes = [{ }, { path: '', - component: Layout, + component: LayoutMain, redirect: '/index', children: [{ path: '/index', diff --git a/src/views/index.vue b/src/views/index.vue index cf2e8dd..3991721 100644 --- a/src/views/index.vue +++ b/src/views/index.vue @@ -1,1016 +1,47 @@