2019-04-29 14:40:02 -07:00
|
|
|
<template>
|
2021-01-29 17:59:05 -08:00
|
|
|
<div v-show="hpml.vars.value[block.var]">
|
2021-11-19 02:36:12 -08:00
|
|
|
<XBlock v-for="child in block.children" :key="child.id" :block="child" :hpml="hpml" :h="h"/>
|
2019-04-29 14:40:02 -07:00
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts">
|
2021-11-11 09:02:25 -08:00
|
|
|
import { IfBlock } from '@/scripts/hpml/block';
|
|
|
|
import { Hpml } from '@/scripts/hpml/evaluator';
|
2021-01-29 17:59:05 -08:00
|
|
|
import { defineComponent, defineAsyncComponent, PropType } from 'vue';
|
2019-04-29 14:40:02 -07:00
|
|
|
|
2020-10-17 04:12:00 -07:00
|
|
|
export default defineComponent({
|
2020-10-18 17:30:21 -07:00
|
|
|
components: {
|
2022-12-21 23:01:59 -08:00
|
|
|
XBlock: defineAsyncComponent(() => import('./page.block.vue')),
|
2020-10-18 17:30:21 -07:00
|
|
|
},
|
2019-04-29 14:40:02 -07:00
|
|
|
props: {
|
2021-01-29 17:59:05 -08:00
|
|
|
block: {
|
|
|
|
type: Object as PropType<IfBlock>,
|
2022-12-21 23:01:59 -08:00
|
|
|
required: true,
|
2019-04-29 14:40:02 -07:00
|
|
|
},
|
2020-04-20 05:35:27 -07:00
|
|
|
hpml: {
|
2021-01-29 17:59:05 -08:00
|
|
|
type: Object as PropType<Hpml>,
|
2022-12-21 23:01:59 -08:00
|
|
|
required: true,
|
2019-04-29 14:40:02 -07:00
|
|
|
},
|
|
|
|
h: {
|
2021-01-29 17:59:05 -08:00
|
|
|
type: Number,
|
2022-12-21 23:01:59 -08:00
|
|
|
required: true,
|
|
|
|
},
|
2019-04-29 14:40:02 -07:00
|
|
|
},
|
|
|
|
});
|
|
|
|
</script>
|