/** * * 页面布局入口文件 * * 说明: * - rayLayoutContentWrapperScopeSelector: 页面切换时重置滚动条注入 id(弃用) * * 该组件入口不做逻辑相关的处理, 仅做功能、组件、方法注入 * 提供页面内 Layout 的一些注入(css vars 为主) */ import './index.scss' import { NLayout, NLayoutContent } from 'naive-ui' import Menu from './components/Menu' import ContentWrapper from '@/layout/default/ContentWrapper' import FooterWrapper from '@/layout/default/FooterWrapper' import HeaderWrapper from './default/HeaderWrapper' import FeatureWrapper from './default/FeatureWrapper' import { LAYOUT_CONTENT_REF } from '@/app-config' import { layoutHeaderCssVars } from '@/layout/layoutResize' import useAppLockScreen from '@/app-components/app/AppLockScreen/appLockVar' import { useSettingGetters } from '@/store' export default defineComponent({ name: 'RLayout', setup() { const layoutSiderBarRef = ref() // 顶部操作栏 ref const layoutMenuTagRef = ref() // 标签页 ref const layoutFooterRef = ref() // 底部版权 ref const { getMenuTagSwitch, getCopyrightSwitch } = useSettingGetters() const { getLockAppScreen } = useAppLockScreen() const cssVarsRef = layoutHeaderCssVars([ layoutSiderBarRef, layoutMenuTagRef, layoutFooterRef, ]) return { getMenuTagSwitch, cssVarsRef, getLockAppScreen, layoutSiderBarRef, layoutMenuTagRef, layoutFooterRef, getCopyrightSwitch, } }, render() { const { getMenuTagSwitch, cssVarsRef, getCopyrightSwitch } = this const { getLockAppScreen } = this return !getLockAppScreen() ? ( {getMenuTagSwitch ? : null} {getCopyrightSwitch ? : null} ) : null }, })