diff --git a/remix-debugger/src/ui/TreeView.js b/remix-debugger/src/ui/TreeView.js
index a6e210ffa9..7601a707f3 100644
--- a/remix-debugger/src/ui/TreeView.js
+++ b/remix-debugger/src/ui/TreeView.js
@@ -77,32 +77,32 @@ class TreeView {
formatData (key, data, children, expand, keyPath) {
var self = this
- var li = yo`
+
${caret}
${self.formatSelf(key, data, li)}
`
li.appendChild(label)
if (data.children) {
- var list = yo`
`
+ var list = yo`
`
list.style.display = 'none'
caret.className = list.style.display === 'none' ? `fa fa-caret-right caret ${css.caret_tv}` : `fa fa-caret-down caret ${css.caret_tv}`
label.onclick = function () {
self.expand(keyPath)
}
label.oncontextmenu = function (event) {
- self.event.trigger('nodeRightClick', [key, data, label, event])
+ self.event.trigger('nodeRightClick', [keyPath, data, label, event])
}
li.appendChild(list)
} else {
caret.style.visibility = 'hidden'
label.oncontextmenu = function (event) {
- self.event.trigger('leafRightClick', [key, data, label, event])
+ self.event.trigger('leafRightClick', [keyPath, data, label, event])
}
label.onclick = function (event) {
- self.event.trigger('leafClick', [key, data, label, event])
+ self.event.trigger('leafClick', [keyPath, data, label, event])
}
}
return li