Treblesteph / mapestry

Playing around with maps.
0 stars 1 forks source link

Make map responsive to screen size dynamically. #20

Closed Treblesteph closed 8 years ago

Treblesteph commented 8 years ago

Currently have made the svg responsive, need to use d3 documentation for transform and translate in maps, and something like this function:

function sizeChange() {
  d3.select("g").attr("transform", "scale(" + $("#container").width()/900 + ")")
  $("svg").height($("#container").width()*0.618)
}

from here

Treblesteph commented 8 years ago

Done with changed projections.