44 <div
55 @click =" selectActivity(id)"
66 :id =" `activity_${uid}`"
7- :style =" { 'border-left-color': color }"
7+ :style =" { 'border-left-color': config. color }"
88 :class =" { selected: isSelected, highlighted: hover }"
99 class =" activity" >
1010 <v-btn
5757</template >
5858
5959<script >
60- import { mapGetters , mapMutations , mapState } from ' vuex' ;
60+ import { mapGetters , mapMutations } from ' vuex' ;
6161import Draggable from ' vuedraggable' ;
6262import filter from ' lodash/filter' ;
63- import find from ' lodash/find' ;
64- import { isEditable } from ' shared/activities' ;
6563import OptionsMenu from ' ../common/ActivityOptions/Menu' ;
6664import OptionsToolbar from ' ../common/ActivityOptions/Toolbar' ;
6765import reorderMixin from ' ./reorderMixin' ;
@@ -86,10 +84,7 @@ export default {
8684 },
8785 computed: {
8886 ... mapGetters (' repository' , [' structure' , ' isCollapsed' ]),
89- ... mapState (' repository' , { outlineState: ' outline' }),
90- config : vm => find (vm .structure , { type: vm .type }),
91- color : vm => vm .config .color ,
92- isEditable : vm => isEditable (vm .type ),
87+ config : vm => vm .structure .find (it => it .type === vm .type ),
9388 isSelected : vm => vm .selectedActivity && (vm .selectedActivity .uid === vm .uid ),
9489 isExpanded : vm => ! vm .isCollapsed ({ uid: vm .uid }),
9590 hasSubtypes : vm => !! size (vm .config .subLevels ),
0 commit comments