Moved UI to client folder to fix HMR

This commit is contained in:
Stefan Zermatten
2022-11-19 17:51:50 +02:00
parent 060b5f93ca
commit e3644eb9e8
358 changed files with 1069 additions and 1066 deletions

View File

@@ -0,0 +1,41 @@
<template lang="html">
<component
:is="treeNodeView"
:model="model"
:selected="selected"
:class="{
'inactive': model.inactive,
}"
v-bind="$attrs"
/>
</template>
<script lang="js">
import treeNodeViewIndex from '/imports/client/ui/properties/treeNodeViews/treeNodeViewIndex.js';
export default {
name: 'TreeNodeView',
components: {
...treeNodeViewIndex
},
props: {
model: {
type: Object,
required: true,
},
selected: Boolean,
},
computed: {
treeNodeView(){
let type = this.model.type;
return treeNodeViewIndex[type] || treeNodeViewIndex.default;
},
}
}
</script>
<style lang="css" scoped>
.inactive {
opacity: 0.6;
}
</style>