Skip to content

Commit 7ed3e2b

Browse files
committed
fix: show log
1 parent aef48cf commit 7ed3e2b

File tree

3 files changed

+387
-371
lines changed

3 files changed

+387
-371
lines changed

src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767
6868
#app .md-content > div {
6969
position: relative;
70-
height: 100%;
70+
height: 100vh;
7171
width: 100%;
7272
}
7373

src/components/InfoWindows.vue

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,20 @@
33
<google-map id="map" ref="Map">
44
<google-map-marker
55
:key="index"
6-
v-for="(infowindow, index) in infoWindowsList"
7-
:position="infowindow.position"
8-
@click="toggleInfoWindow(infowindow)"
9-
></google-map-marker>
6+
v-for="(info, index) in infoWindowsList"
7+
:position="info.position"
8+
@click="toggleInfoWindow(info)"
9+
/>
1010
<google-map-infowindow
11-
v-for="(infowindow, index) in infoWindowsList"
11+
v-for="(info, index) in infoWindowsList"
1212
:key="`info-window-${index}`"
13-
:position="infowindow.position"
13+
:position="info.position"
1414
:show.sync="showInfo"
1515
:options="{maxWidth: 300}"
16-
@info-window-clicked="infoClicked($event, infowindow)"
16+
@info-window-clicked="infoClicked($event, info)"
1717
>
18-
<h4 >{{infoWIndowContext.title}}</h4>
19-
<p>{{infoWIndowContext.description}}</p>
18+
<h4 >{{infoWindowContext.title}}</h4>
19+
<p>{{infoWindowContext.description}}</p>
2020
</google-map-infowindow>
2121
</google-map>
2222
</div>
@@ -28,7 +28,7 @@ export default {
2828
data () {
2929
return {
3030
showInfo: true,
31-
infoWIndowContext: {
31+
infoWindowContext: {
3232
title: 'Hello world',
3333
description: 'Description',
3434
position: {
@@ -41,11 +41,11 @@ export default {
4141
},
4242
methods: {
4343
toggleInfoWindow (context) {
44-
this.infoWIndowContext = context
44+
this.infoWindowContext = context
4545
this.showInfo = true
4646
},
4747
infoClicked(context, spot) {
48-
console.log(context, spot)
48+
console.log('infoClicked', context, spot)
4949
}
5050
}
5151
}

0 commit comments

Comments
 (0)