mirror of
https://github.com/troisjs/trois.git
synced 2024-11-24 04:12:02 +08:00
move tools (fix rollup)
This commit is contained in:
parent
9eb6bac736
commit
a11a6cecf4
@ -1,5 +1,5 @@
|
|||||||
import { watch } from 'vue';
|
import { watch } from 'vue';
|
||||||
import { bindProp } from '../tools/index.js';
|
import { bindProp } from '../tools';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Object3D',
|
name: 'Object3D',
|
||||||
@ -10,11 +10,12 @@ export default {
|
|||||||
rotation: { type: Object, default: { x: 0, y: 0, z: 0 } },
|
rotation: { type: Object, default: { x: 0, y: 0, z: 0 } },
|
||||||
scale: { type: Object, default: { x: 1, y: 1, z: 1 } },
|
scale: { type: Object, default: { x: 1, y: 1, z: 1 } },
|
||||||
lookAt: { type: Object, default: null },
|
lookAt: { type: Object, default: null },
|
||||||
|
autoRemove: { type: Boolean, default: true },
|
||||||
},
|
},
|
||||||
// can't use setup because it will not be used in sub components
|
// can't use setup because it will not be used in sub components
|
||||||
// setup() {},
|
// setup() {},
|
||||||
unmounted() {
|
unmounted() {
|
||||||
this.removeFromParent();
|
if (this.autoRemove) this.removeFromParent();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
initObject3D(o3d) {
|
initObject3D(o3d) {
|
||||||
|
Loading…
Reference in New Issue
Block a user