diff --git a/A2teamkadai/map.js b/A2teamkadai/map.js index 62fda91..700eb3d 100644 --- a/A2teamkadai/map.js +++ b/A2teamkadai/map.js @@ -114,6 +114,7 @@ L.tileLayer('http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { attribution: '© OpenStreetMap contributors,' }).addTo(map); + /* // GeoJSONのレイヤーを設定 var foodLayer = L.geoJson(asahi, { // asahi変数は asahi.geojson からロードした style: function (feature) { @@ -161,10 +162,12 @@ var ovlLayers = {'食 ': foodLayer, '場所': placeLayer, '自然': natureLayer}; // オーバーレイレイヤをマップに追加 L.control.layers(null, ovlLayers).addTo(map); + */ //地図に地点を表示する(asahi変数はtsuruoka-asahi.geojsonからロードした) L.marker([asahi["features"][0]["geometry"]["coordinates"][1], asahi["features"][0]["geometry"]["coordinates"][0]], {title: asahi["features"][0]["properties"]["name"], icon: skyblueIcon}) - .bindPopup(L.popup().setContent("

"+asahi["features"][0]["properties"]["name"]+"

"+"")).addTo(map).on("click", () => { + .bindPopup(L.popup().setContent("

"+asahi["features"][0]["properties"]["name"]+"

"+"

"+asahi["features"][0]["properties"]["description"]+"

"+"")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][0]["properties"]["html"], asahi["features"][0]["properties"]["quiz"], asahi["features"][0]["properties"]["choiceA"], @@ -177,7 +180,9 @@ asahi["features"][0]["properties"]["description"]); }); L.marker([asahi["features"][1]["geometry"]["coordinates"][1], asahi["features"][1]["geometry"]["coordinates"][0]], - {title: asahi["features"][1]["properties"]["name"], icon: brownIcon}).addTo(map).on("click", () => { + {title: asahi["features"][1]["properties"]["name"], icon: brownIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][1]["properties"]["name"]+"

"+"

"+asahi["features"][1]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][1]["properties"]["html"], asahi["features"][1]["properties"]["quiz"], asahi["features"][1]["properties"]["choiceA"], @@ -190,7 +195,9 @@ asahi["features"][1]["properties"]["description"]); }); L.marker([asahi["features"][2]["geometry"]["coordinates"][1], asahi["features"][2]["geometry"]["coordinates"][0]], - {title: asahi["features"][2]["properties"]["name"], icon: purpleIcon}).addTo(map).on("click", () => { + {title: asahi["features"][2]["properties"]["name"], icon: purpleIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][2]["properties"]["name"]+"

"+"

"+asahi["features"][2]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][2]["properties"]["html"], asahi["features"][2]["properties"]["quiz"], asahi["features"][2]["properties"]["choiceA"], @@ -203,7 +210,9 @@ asahi["features"][2]["properties"]["description"]); }); L.marker([asahi["features"][3]["geometry"]["coordinates"][1], asahi["features"][3]["geometry"]["coordinates"][0]], - {title: asahi["features"][3]["properties"]["name"], icon: orangeIcon}).addTo(map).on("click", () => { + {title: asahi["features"][3]["properties"]["name"], icon: orangeIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][3]["properties"]["name"]+"

"+"

"+asahi["features"][3]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][3]["properties"]["html"], asahi["features"][3]["properties"]["quiz"], asahi["features"][3]["properties"]["choiceA"], @@ -216,7 +225,9 @@ asahi["features"][3]["properties"]["description"]); }); L.marker([asahi["features"][4]["geometry"]["coordinates"][1], asahi["features"][4]["geometry"]["coordinates"][0]], - {title: asahi["features"][4]["properties"]["name"]}).addTo(map).on("click", () => { + {title: asahi["features"][4]["properties"]["name"]}) + .bindPopup(L.popup().setContent("

"+asahi["features"][4]["properties"]["name"]+"

"+"

"+asahi["features"][4]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][4]["properties"]["html"], asahi["features"][4]["properties"]["quiz"], asahi["features"][4]["properties"]["choiceA"], @@ -229,7 +240,9 @@ asahi["features"][4]["properties"]["description"]); }); L.marker([asahi["features"][5]["geometry"]["coordinates"][1], asahi["features"][5]["geometry"]["coordinates"][0]], - {title: asahi["features"][5]["properties"]["name"], icon: pinkIcon}).addTo(map).on("click", () => { + {title: asahi["features"][5]["properties"]["name"], icon: pinkIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][5]["properties"]["name"]+"

"+"

"+asahi["features"][5]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][5]["properties"]["html"], asahi["features"][5]["properties"]["quiz"], asahi["features"][5]["properties"]["choiceA"], @@ -242,7 +255,9 @@ asahi["features"][5]["properties"]["description"]); }); L.marker([asahi["features"][6]["geometry"]["coordinates"][1], asahi["features"][6]["geometry"]["coordinates"][0]], - {title: asahi["features"][6]["properties"]["name"], icon: whiteIcon}).addTo(map).on("click", () => { + {title: asahi["features"][6]["properties"]["name"], icon: whiteIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][6]["properties"]["name"]+"

"+"

"+asahi["features"][6]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][6]["properties"]["html"], asahi["features"][6]["properties"]["quiz"], asahi["features"][6]["properties"]["choiceA"], @@ -255,7 +270,9 @@ asahi["features"][6]["properties"]["description"]); }); L.marker([asahi["features"][7]["geometry"]["coordinates"][1], asahi["features"][7]["geometry"]["coordinates"][0]], - {title: asahi["features"][7]["properties"]["name"], icon: blackIcon}).addTo(map).on("click", () => { + {title: asahi["features"][7]["properties"]["name"], icon: blackIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][7]["properties"]["name"]+"

"+"

"+asahi["features"][7]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][7]["properties"]["html"], asahi["features"][7]["properties"]["quiz"], asahi["features"][7]["properties"]["choiceA"], @@ -268,7 +285,9 @@ asahi["features"][7]["properties"]["description"]); }); L.marker([asahi["features"][8]["geometry"]["coordinates"][1], asahi["features"][8]["geometry"]["coordinates"][0]], - {title: asahi["features"][8]["properties"]["name"], icon: darkgoldIcon}).addTo(map).on("click", () => { + {title: asahi["features"][8]["properties"]["name"], icon: darkgoldIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][8]["properties"]["name"]+"

"+"

"+asahi["features"][8]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][8]["properties"]["html"], asahi["features"][8]["properties"]["quiz"], asahi["features"][8]["properties"]["choiceA"], @@ -281,7 +300,9 @@ asahi["features"][8]["properties"]["description"]); }); L.marker([asahi["features"][9]["geometry"]["coordinates"][1], asahi["features"][9]["geometry"]["coordinates"][0]], - {title: asahi["features"][9]["properties"]["name"], icon: redIcon}).addTo(map).on("click", () => { + {title: asahi["features"][9]["properties"]["name"], icon: redIcon}) + .bindPopup(L.popup().setContent("

"+asahi["features"][9]["properties"]["name"]+"

"+"

"+asahi["features"][9]["properties"]["description"]+"

")) + .addTo(map).on("click", () => { clickMarker(asahi["features"][9]["properties"]["html"], asahi["features"][9]["properties"]["quiz"], asahi["features"][9]["properties"]["choiceA"], diff --git a/A2teamkadai/quiz.html b/A2teamkadai/quiz.html index 908a861..12a1596 100644 --- a/A2teamkadai/quiz.html +++ b/A2teamkadai/quiz.html @@ -16,9 +16,8 @@
- - - + +

マップ

@@ -52,10 +51,6 @@
-

観光地名

-

説明

-
-

朝日地区イズの遊び方

  1. マップ上のマーカーのいずれかをクリックしよう!
  2. @@ -83,7 +78,7 @@

    スタンプの見方

    クイズに正解すると、白い丸にスタンプが押されていきます。

-
+