I am learning bootstrap and I tried to use the HERE maps based on this example from HERE
I realized, that to be able to use relative height (e.g. height: 50%) I have to make the css styles like that:
html, body {
height: 100%;
width: 100%;
}
#map {
width:100%;
height: 100%;
margin:0 auto;
}
Now I would like to create two columns with bootstrap, left for itinerary and right for the map view.
<div class="container">
<div class="row">
<div class="col-sm-4">
Here comes the itinerary
</div>
<div class="col-sm-8" id="map">
</div>
</div>
I quickly realized, that I have to use absolut size for the map element (e.g. width: 400px), otherwise the map is not displayed at all (when using height: 100%;) or the columns are stack from the beginning (using width: 100%;)
I suspect, that the reason for this lies in the width/height styling of the parent elements (row, container), but I do not know the right solution.
I also know, that after getting the styling right I need to take care about the automatic adapting of the maps size on window resize, but I would like go get the right styling first.