Skip to content

Commit 951b5d8

Browse files
committed
style maps
1 parent 7280ada commit 951b5d8

File tree

3 files changed

+43
-13
lines changed

3 files changed

+43
-13
lines changed

app/assets/stylesheets/custom.css.scss

-1
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,6 @@ $maincolor: #333;
381381
#friend_name {
382382
color: white;
383383
font-weight: bolder;
384-
// border-bottom: 2px dashed white;
385384
}
386385

387386
#namer {

app/views/meet_requests/show.html.erb

+14-7
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@
88
geocoder,
99
markersArray = [],
1010
directionsDisplay,
11-
polyline=[],
12-
businessesArray=[],
1311
infowindow;
1412

1513
function initialize() {
@@ -145,10 +143,10 @@
145143
console.log(midpoint);
146144
console.log(response.routes[0].legs[0].steps[0]);
147145

148-
var midMarker = new google.maps.Marker({
149-
position: midpoint,
150-
map: map,
151-
});
146+
// var midMarker = new google.maps.Marker({
147+
// position: midpoint,
148+
// map: map,
149+
// });
152150

153151
var request = {
154152
location: midpoint,
@@ -184,11 +182,20 @@
184182
}
185183
}
186184

185+
var placeMarkers = new google.maps.MarkerImage(
186+
'/assets/orange_marker.png',
187+
null, // size
188+
null, // origin
189+
new google.maps.Point( 10, 28 ), // anchor (move to center of marker)
190+
new google.maps.Size( 20, 28 ) // scaled size (required for Retina display icon)
191+
);
192+
187193
function createMarker(place) {
188194
var placeLoc = place.geometry.location;
189195
var marker = new google.maps.Marker({
190196
map: map,
191-
position: place.geometry.location
197+
position: place.geometry.location,
198+
icon: placeMarkers
192199
});
193200

194201
google.maps.event.addListener(marker, 'click', function() {

app/views/users/show.html.erb

+29-5
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,35 @@
2222
{ saturation: -20 }
2323
]
2424
},{
25-
featureType: "road.local",
25+
featureType: "road",
2626
elementType: "geometry",
2727
stylers: [
28-
{ hue: "#00ffee" },
29-
{ saturation: 50 }
28+
{ color: "#e2cfbc" },
29+
]
30+
},{
31+
featureType: "road.arterial",
32+
elementType: "all",
33+
stylers: [
34+
{ visibility: "off" }
35+
]
36+
},{
37+
featureType: "administrative.neighborhood",
38+
elementType: "all",
39+
stylers: [
40+
// { color: "#ffffff" },
41+
]
42+
},{
43+
featureType: "road.local",
44+
elementType: "all",
45+
stylers: [
46+
{ visibility: "off" }
47+
]
48+
},{
49+
featureType: "landscape",
50+
elementType: "all",
51+
stylers: [
52+
{ visibility: "off" },
53+
{ color: "#ffffff" },
3054
]
3155
},{
3256
featureType: "road",
@@ -105,7 +129,7 @@
105129
'/assets/orange_marker.png',
106130
null, // size
107131
null, // origin
108-
new google.maps.Point( 8, 8 ), // anchor (move to center of marker)
132+
new google.maps.Point( 10, 28 ), // anchor (move to center of marker)
109133
new google.maps.Size( 20, 28 ) // scaled size (required for Retina display icon)
110134
);
111135

@@ -131,7 +155,7 @@
131155
google.maps.event.addDomListener(window, "load", initialize);
132156

133157
</script>
134-
<section id="map-wrapper">
158+
<section id="map-wrapper">
135159
<article></article>
136160
<div id="bottom_nav">
137161
<%= link_to "", meet_requests_path, class: "glyphicon glyphicon-th" %>

0 commit comments

Comments
 (0)