Skip to content

Commit 9dc3f7d

Browse files
committed
🚧
1 parent a490e1c commit 9dc3f7d

9 files changed

+3371
-884
lines changed

dist/Vue2LeafletHeightGraph.common.js

Lines changed: 141 additions & 129 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/Vue2LeafletHeightGraph.common.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/Vue2LeafletHeightGraph.umd.js

Lines changed: 141 additions & 129 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/Vue2LeafletHeightGraph.umd.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/Vue2LeafletHeightGraph.umd.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/Vue2LeafletHeightGraph.umd.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Vue2LeafletHeightGraph.vue

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -50,31 +50,31 @@
5050
if(this.debug) {
5151
console.log('mounted')
5252
}
53-
this.$nextTick(() => {
54-
const map = this.$parent.mapObject;
55-
this.hgInstance = L.control.heightgraph({...this.options,...{
56-
// merges quick settings with options if they are defined
57-
...(this.position && {position: this.position}),
58-
...(this.expand && {expand: this.expand})
59-
}})
60-
this.controlRef = this.hgInstance.addTo(map)
61-
if(this.container) {
62-
const container = document.getElementById(this.container);
63-
container.innerHTML = ''
64-
container.appendChild(this.controlRef.onAdd(map));
53+
const map = this.$parent.mapObject;
54+
this.hgInstance = L.control.heightgraph({...this.options,...{
55+
// merges quick settings with options if they are defined
56+
...(this.position && {position: this.position}),
57+
...(this.expand && {expand: this.expand})
58+
}})
59+
this.controlRef = this.hgInstance.addTo(map)
60+
if(this.container) {
61+
const container = document.getElementById(this.container);
62+
container.innerHTML = ''
63+
container.appendChild(this.controlRef.onAdd(map));
6564
66-
try {
67-
document.querySelector('.leaflet-control-container .heightgraph.leaflet-control').hidden = true
68-
} catch (e) {
69-
console.error('Unable to hide the default height graph control')
70-
}
71-
} else {
72-
this.hgInstance.addTo(map)
73-
}
74-
let p = Object.keys(this.availableParsers).includes(this.parser) ? this.parser : 'normal'
75-
let dataCollections = this.availableParsers[p](this.data)
76-
this.hgInstance.addData(dataCollections)
77-
})
65+
try {
66+
document.querySelector('.leaflet-control-container .heightgraph.leaflet-control').hidden = true
67+
} catch (e) {
68+
console.error('Unable to hide the default height graph control')
69+
}
70+
} else {
71+
this.hgInstance.addTo(map)
72+
}
73+
let p = Object.keys(this.availableParsers).includes(this.parser) ? this.parser : 'normal'
74+
console.log({p})
75+
let dataCollections = this.availableParsers[p](this.data)
76+
console.log({dataCollections})
77+
this.hgInstance.addData(dataCollections)
7878
},
7979
beforeDestroy() {
8080
if(this.debug) {

0 commit comments

Comments
 (0)