2019-04-29 00:11:57 +00:00
|
|
|
<template>
|
|
|
|
<section class="sdgxphyu">
|
2021-01-30 01:59:05 +00:00
|
|
|
<component :is="'h' + h">{{ block.title }}</component>
|
2019-04-29 00:11:57 +00:00
|
|
|
|
|
|
|
<div class="children">
|
2023-05-14 01:50:21 +00:00
|
|
|
<XBlock v-for="child in block.children" :key="child.id" :page="page" :block="child" :h="h + 1"/>
|
2019-04-29 00:11:57 +00:00
|
|
|
</div>
|
|
|
|
</section>
|
|
|
|
</template>
|
|
|
|
|
2023-05-14 01:50:21 +00:00
|
|
|
<script lang="ts" setup>
|
|
|
|
import { defineAsyncComponent } from 'vue';
|
|
|
|
import * as Misskey from 'misskey-js';
|
|
|
|
import { SectionBlock } from './block.type';
|
|
|
|
|
|
|
|
const XBlock = defineAsyncComponent(() => import('./page.block.vue'));
|
|
|
|
|
|
|
|
defineProps<{
|
|
|
|
block: SectionBlock,
|
|
|
|
h: number,
|
|
|
|
page: Misskey.entities.Page,
|
|
|
|
}>();
|
2019-04-29 00:11:57 +00:00
|
|
|
</script>
|
|
|
|
|
2022-12-27 09:29:39 +00:00
|
|
|
<style lang="scss" scoped>
|
2020-01-29 19:37:25 +00:00
|
|
|
.sdgxphyu {
|
|
|
|
margin: 1.5em 0;
|
2019-04-29 00:11:57 +00:00
|
|
|
|
2020-01-29 19:37:25 +00:00
|
|
|
> h2 {
|
|
|
|
font-size: 1.35em;
|
|
|
|
margin: 0 0 0.5em 0;
|
|
|
|
}
|
2019-04-29 00:11:57 +00:00
|
|
|
|
2020-01-29 19:37:25 +00:00
|
|
|
> h3 {
|
|
|
|
font-size: 1em;
|
|
|
|
margin: 0 0 0.5em 0;
|
|
|
|
}
|
2019-04-29 00:11:57 +00:00
|
|
|
|
2020-01-29 19:37:25 +00:00
|
|
|
> h4 {
|
|
|
|
font-size: 1em;
|
|
|
|
margin: 0 0 0.5em 0;
|
|
|
|
}
|
2019-04-29 00:11:57 +00:00
|
|
|
|
2020-01-29 19:37:25 +00:00
|
|
|
> .children {
|
2019-04-29 00:11:57 +00:00
|
|
|
//padding 16px
|
2020-01-29 19:37:25 +00:00
|
|
|
}
|
|
|
|
}
|
2019-04-29 00:11:57 +00:00
|
|
|
</style>
|