File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change 2
2
import { useNotionBlock , defineNotionProps } from " @/lib/blockable"
3
3
import NotionPageIcon from " @/blocks/helpers/page-icon.vue"
4
4
import NotionTextRenderer from " @/blocks/helpers/text-renderer.vue"
5
+ import NotionRenderer from " @/components/notion-renderer.vue"
5
6
6
7
const props = defineProps ({ ... defineNotionProps })
7
8
// @ts-ignore
8
- const { pass, title, blockColorClass } = useNotionBlock (props )
9
+ const { pass, title, blockColorClass, block } = useNotionBlock (props )
9
10
</script >
10
11
11
12
<script lang="ts">
@@ -20,7 +21,16 @@ export default {
20
21
<NotionPageIcon v-bind =" pass" />
21
22
</div >
22
23
<div class =" notion-callout-text" >
23
- <NotionTextRenderer :text =" title" v-bind =" pass" />
24
+ <NotionRenderer
25
+ v-if =" block.value.content"
26
+ v-for =" (contentId, contentIndex) in block.value.content"
27
+ v-bind =" pass"
28
+ :key =" contentId"
29
+ :level =" pass.level + 1"
30
+ :content-id =" contentId"
31
+ :content-index =" contentIndex"
32
+ />
33
+ <NotionTextRenderer v-else :text =" title" v-bind =" pass" />
24
34
</div >
25
35
</div >
26
36
</template >
You can’t perform that action at this time.
0 commit comments