mirror of
https://github.com/tenrok/vue-json-viewer.git
synced 2026-06-14 18:42:31 +03:00
@@ -47,6 +47,17 @@ export default {
|
||||
evt.initEvent('resized', true, false)
|
||||
this.$el.dispatchEvent(evt)
|
||||
}
|
||||
},
|
||||
getPath() {
|
||||
const path = [this.keyName];
|
||||
let p = this.$parent;
|
||||
while(p.depth) {
|
||||
if (p.$el.classList.contains('jv-node')) {
|
||||
path.push(p.keyName);
|
||||
}
|
||||
p = p.$parent;
|
||||
}
|
||||
return path.reverse()
|
||||
}
|
||||
},
|
||||
render (h) {
|
||||
|
||||
@@ -92,7 +92,7 @@ export default {
|
||||
},
|
||||
props: {
|
||||
sort: this.sort,
|
||||
// keyName: key,
|
||||
keyName: `${key}`,
|
||||
depth: this.depth + 1,
|
||||
value,
|
||||
previewMode: this.previewMode,
|
||||
|
||||
Reference in New Issue
Block a user