You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+57-2Lines changed: 57 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -103,7 +103,23 @@ const style = {
103
103
height:'100%'
104
104
}
105
105
```
106
-
initalCenter: Takes an object containing latitude and longitude coordinates. Sets the maps center upon loading.
106
+
107
+
Container Style: Takes CSS style object - optional, commonly when you want to change from the default of position "absolute".
108
+
109
+
```javascript
110
+
constcontainerStyle= {
111
+
position:'relative',
112
+
width:'100%',
113
+
height:'100%'
114
+
}
115
+
```
116
+
117
+
```javascript
118
+
<Map
119
+
containerStyle={containerStyle}
120
+
```
121
+
122
+
initialCenter: Takes an object containing latitude and longitude coordinates. Sets the maps center upon loading.
107
123
108
124
```javascript
109
125
<Map
@@ -229,7 +245,7 @@ render() {
229
245
}
230
246
```
231
247
232
-
The `<Map />` component also listens to `onRecenter`, `onBoundsChanged`, `onCenterChanged`, `onDblclick`, `onDragstart`, `onHeadingChange`, `onIdle`, `onMaptypeidChanged`, `onMousemove`, `onMouseout`, `onMouseover`, `onProjectionChanged`, `onResize`, `onRightclick`, `onTilesloaded`, `onTiltChanged`, and `onZoomChanged` events. See Google Maps [Events](https://developers.google.com/maps/documentation/javascript/events) for more information.
248
+
The `<Map />` component also listens to `onRecenter`, `onBounds_changed`, `onCenter_changed`, `onDblclick`, `onDragstart`, `onHeading_change`, `onIdle`, `onMaptypeid_changed`, `onMousemove`, `onMouseout`, `onMouseover`, `onProjection_changed`, `onResize`, `onRightclick`, `onTilesloaded`, `onTilt_changed`, and `onZoom_changed` events. See Google Maps [Events](https://developers.google.com/maps/documentation/javascript/events) for more information.
233
249
234
250
### Visibility
235
251
@@ -534,6 +550,45 @@ The `<Circle />` component listens to `onClick`, `onMouseover` and `onMouseout`
534
550
535
551
The `GoogleApiWrapper` automatically passes the `google` instance loaded when the component mounts (and will only load it once).
536
552
553
+
#### Custom Map Style
554
+
555
+
To set your own custom map style, import your custom map style in JSON format.
0 commit comments