refactor: ♻️ 首页样式和登录代码优化

Former-commit-id: 37297f36749177bed5e77fcf95a252a567af757d
This commit is contained in:
hxr
2023-11-10 08:13:14 +08:00
parent 21fb121ab8
commit 3c633c2fcf
4 changed files with 54 additions and 54 deletions

View File

@@ -24,6 +24,7 @@ const fixedHeader = computed(() => settingsStore.fixedHeader);
const showTagsView = computed(() => settingsStore.tagsView);
const showSettings = computed(() => settingsStore.showSettings);
const layout = computed(() => settingsStore.layout);
const device = computed(() => appStore.device);
watchEffect(() => {
if (width.value < WIDTH) {
@@ -43,7 +44,7 @@ watchEffect(() => {
</script>
<template>
<div :class="{ hasTagsView: showTagsView }" class="main-container">
<div :class="{ 'fixed-header': fixedHeader }">
<div :class="{ 'fixed-header': fixedHeader, device: device }">
<navbar v-if="layout === 'left'" />
<tags-view v-if="showTagsView" />
</div>
@@ -70,6 +71,10 @@ watchEffect(() => {
width: calc(100% - 54px);
}
.hideSidebar.mobile .fixed-header {
width: 100%;
}
.isTop .fixed-header {
width: 100% !important;
}