improve padding, maxWidth and overflow of click anywhere popups
This commit is contained in:
parent
02be155011
commit
afb1128e3c
2 changed files with 7 additions and 2 deletions
|
@ -750,7 +750,9 @@ main:not([data-view=route-result]) #route-dots {
|
|||
border-top-width: 1px;
|
||||
}
|
||||
.location {
|
||||
margin-right: 12px;
|
||||
margin-right: 24px;
|
||||
padding-right: 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
.button-clear {
|
||||
display:block;
|
||||
|
|
|
@ -1315,7 +1315,7 @@ c3nav = {
|
|||
}
|
||||
},
|
||||
_add_map_padding: function(options, topleft, bottomright) {
|
||||
// add padding information for the current ui layout to fitBoudns options
|
||||
// add padding information for the current ui layout to fitBounds options
|
||||
var $search = $('#search'),
|
||||
$main = $('main'),
|
||||
padBesideSidebar = (
|
||||
|
@ -1324,6 +1324,9 @@ c3nav = {
|
|||
),
|
||||
left = padBesideSidebar ? ($search.width() || 0)+10 : 0,
|
||||
top = padBesideSidebar ? 10 : ($search.height() || 0)+10;
|
||||
if ('maxWidth' in options) {
|
||||
options.maxWidth = Math.min(options.maxWidth, $main.width()-left-13-50)
|
||||
}
|
||||
options[topleft || 'paddingTopLeft'] = L.point(left+13, top+41);
|
||||
options[bottomright || 'paddingBottomRight'] = L.point(50, 20);
|
||||
return options;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue