2025-04-10 16:37:20 +08:00
|
|
|
<template>
|
2025-04-14 16:37:17 +08:00
|
|
|
<CfFlex class="material-view">
|
|
|
|
<div ref="container" style="width: 100%; height: 100%; flex: 3; box-sizing: border-box;" />
|
|
|
|
<MaterialAdjuster style="flex: 1;overflow-y: auto; width: 100%; height: 100%; box-sizing: border-box;" />
|
|
|
|
</CfFlex>
|
2025-04-10 16:37:20 +08:00
|
|
|
</template>
|
|
|
|
<script setup lang="ts">
|
|
|
|
import { onMounted, useTemplateRef } from 'vue';
|
2025-04-14 16:37:17 +08:00
|
|
|
import MaterialAdjuster from './MaterialAdjuster.vue';
|
|
|
|
import { useScene } from '../stores/sceneStore';
|
|
|
|
import CfFlex from './CfFlex.vue';
|
2025-04-10 16:37:20 +08:00
|
|
|
|
2025-04-14 16:37:17 +08:00
|
|
|
const scene = useScene();
|
2025-04-10 16:37:20 +08:00
|
|
|
const container = useTemplateRef<HTMLElement>('container');
|
|
|
|
|
|
|
|
onMounted(() => {
|
2025-04-14 16:37:17 +08:00
|
|
|
scene.Initial(container.value);
|
|
|
|
});
|
|
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style scoped>
|
|
|
|
.material-view
|
|
|
|
{
|
|
|
|
width: 100%;
|
|
|
|
height: 100vh;
|
|
|
|
box-sizing: border-box;
|
|
|
|
padding: 0;
|
|
|
|
margin: 0;
|
|
|
|
overflow: hidden;
|
2025-04-10 16:37:20 +08:00
|
|
|
}
|
2025-04-14 16:37:17 +08:00
|
|
|
</style>
|