client: siplify page display

This commit is contained in:
Johann150 2022-07-31 22:57:05 +02:00
parent b662ce8460
commit 5489ce4053
Signed by untrusted user: Johann150
GPG key ID: 9EE6577A2A06F8F1

View file

@ -1,20 +1,15 @@
<template> <template>
<MkStickyContainer> <MkStickyContainer>
<template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template> <template #header><MkPageHeader/></template>
<MkSpacer :content-max="700"> <MkSpacer :content-max="700">
<transition :name="$store.state.animation ? 'fade' : ''" mode="out-in"> <transition :name="$store.state.animation ? 'fade' : ''" mode="out-in">
<div v-if="page" :key="page.id" v-size="{ max: [450] }" class="xcukqgmh"> <div v-if="page" :key="page.id" v-size="{ max: [450] }" class="xcukqgmh">
<div class="_block main"> <div class="_block main">
<!--
<div class="header">
<h1>{{ page.title }}</h1>
</div>
-->
<div class="banner"> <div class="banner">
<img v-if="page.eyeCatchingImageId" :src="page.eyeCatchingImage.url"/> <img v-if="page.eyeCatchingImageId" :src="page.eyeCatchingImage.url"/>
</div> </div>
<div class="content"> <div class="content" :class="{ center: page.alignCenter, serif: page.font === 'serif' }">
<XPage :page="page"/> <Mfm :text="page.text" :is-note="false"/>
</div> </div>
<div class="actions"> <div class="actions">
<div class="like"> <div class="like">
@ -63,7 +58,6 @@
<script lang="ts" setup> <script lang="ts" setup>
import { computed, watch } from 'vue'; import { computed, watch } from 'vue';
import XPage from '@/components/page/page.vue';
import MkButton from '@/components/ui/button.vue'; import MkButton from '@/components/ui/button.vue';
import * as os from '@/os'; import * as os from '@/os';
import { url } from '@/config'; import { url } from '@/config';
@ -196,6 +190,16 @@ definePageMetadata(computed(() => page ? {
> .content { > .content {
margin-top: 1em; margin-top: 1em;
padding: 1em; padding: 1em;
&.serif {
> div {
font-family: serif;
}
}
&.center {
text-align: center;
}
} }
> .actions { > .actions {