visgraph: add hover interaction

This commit is contained in:
Mathieu Jaumotte 2021-11-01 09:49:55 +01:00
parent a57a23dc49
commit 869e442c2c
2 changed files with 12 additions and 4 deletions

View File

@ -294,7 +294,7 @@ const store = createStore({
arrows: 'to',
color: 'lightblue',
font: { color: '#33839d' },
dashes: true,
dashes: true, //physics: false,
label: getRelationshipLabel(r, false),
title: getRelationshipTitle(r),
})
@ -316,7 +316,7 @@ const store = createStore({
commit('addPerson', adapt2vis(person, { folded: true }))
console.log('********* fetch infos for missing', person.id, '******')
dispatch('fetchInfoForPerson', person)
//dispatch('fetchInfoForPerson', person)
},
}
})

View File

@ -69,6 +69,16 @@ window.options = {
adaptiveTimestep: true,
wind: { x: 0, y: 0 }
},
interaction: {
hover: true,
keyboard: {
enabled: true,
speed: {x: 3, y: 3, zoom: 0.02},
bindToWindow: false
},
multiselect: true,
navigationButtons: false
},
manipulation: {
enabled: true,
initiallyActive: true,
@ -115,7 +125,6 @@ window.options = {
}
},
nodes: {
//physics: true,
borderWidth: 1,
borderWidthSelected: 3,
font: {
@ -123,7 +132,6 @@ window.options = {
}
},
edges: {
//physics: true,
font: {
color: '#b0b0b0',
size: 9,