|
|
|
@ -8,7 +8,10 @@ const props = defineProps({
|
|
|
|
|
fixedHeader: Boolean
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
const { $storage, $config } = useGlobal<GlobalPropertiesApi>();
|
|
|
|
|
const {
|
|
|
|
|
// $storage,
|
|
|
|
|
$config
|
|
|
|
|
} = useGlobal<GlobalPropertiesApi>();
|
|
|
|
|
|
|
|
|
|
const keepAlive = computed(() => {
|
|
|
|
|
return $config?.KeepAlive;
|
|
|
|
@ -20,23 +23,23 @@ const transitions = computed(() => {
|
|
|
|
|
};
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
const hideTabs = computed(() => {
|
|
|
|
|
return $storage?.configure.hideTabs;
|
|
|
|
|
});
|
|
|
|
|
// const hideTabs = computed(() => {
|
|
|
|
|
// return $storage?.configure.hideTabs;
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
|
|
const layout = computed(() => {
|
|
|
|
|
return $storage?.layout.layout === "vertical";
|
|
|
|
|
});
|
|
|
|
|
// const layout = computed(() => {
|
|
|
|
|
// return $storage?.layout.layout === "vertical";
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
|
|
const getSectionStyle = computed(() => {
|
|
|
|
|
return [
|
|
|
|
|
hideTabs.value && layout ? "padding-top: 48px;" : "",
|
|
|
|
|
!hideTabs.value && layout ? "padding-top: 85px;" : "",
|
|
|
|
|
hideTabs.value && !layout.value ? "padding-top: 48px" : "",
|
|
|
|
|
!hideTabs.value && !layout.value ? "padding-top: 85px;" : "",
|
|
|
|
|
props.fixedHeader ? "" : "padding-top: 0;"
|
|
|
|
|
];
|
|
|
|
|
});
|
|
|
|
|
// const getSectionStyle = computed(() => {
|
|
|
|
|
// return [
|
|
|
|
|
// hideTabs.value && layout ? "padding-top: 48px;" : "",
|
|
|
|
|
// !hideTabs.value && layout ? "padding-top: 85px;" : "",
|
|
|
|
|
// hideTabs.value && !layout.value ? "padding-top: 48px" : "",
|
|
|
|
|
// !hideTabs.value && !layout.value ? "padding-top: 85px;" : "",
|
|
|
|
|
// props.fixedHeader ? "" : "padding-top: 0;"
|
|
|
|
|
// ];
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
|
|
const transitionMain = defineComponent({
|
|
|
|
|
render() {
|
|
|
|
@ -76,7 +79,6 @@ const transitionMain = defineComponent({
|
|
|
|
|
<template>
|
|
|
|
|
<section
|
|
|
|
|
:class="[props.fixedHeader ? 'app-main' : 'app-main-nofixed-header']"
|
|
|
|
|
:style="getSectionStyle"
|
|
|
|
|
>
|
|
|
|
|
<router-view>
|
|
|
|
|
<template #default="{ Component, route }">
|
|
|
|
@ -132,7 +134,10 @@ const transitionMain = defineComponent({
|
|
|
|
|
.app-main {
|
|
|
|
|
position: relative;
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 100vh;
|
|
|
|
|
height: calc(100vh - 48px - 2 * 24px);
|
|
|
|
|
overflow: scroll;
|
|
|
|
|
|
|
|
|
|
/* height: 100vh; */
|
|
|
|
|
overflow-x: hidden;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|