mirror of
https://github.com/netzmacht/contao-leaflet-libraries.git
synced 2025-11-29 11:33:44 +01:00
Update to leaflet.fullscreen 1.3.0.
This commit is contained in:
@@ -3,17 +3,17 @@
|
||||
<head>
|
||||
<meta charset='utf-8'>
|
||||
<title>Leaflet.Control.FullScreen Demo</title>
|
||||
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css" />
|
||||
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7.5/leaflet.css" />
|
||||
<style type="text/css">
|
||||
#map { width: 700px; height: 433px; }
|
||||
.leaflet-control-zoom-fullscreen { background-image: url(icon-fullscreen.png); }
|
||||
.fullscreen-icon { background-image: url(icon-fullscreen.png); }
|
||||
/* on selector per rule as explained here : http://www.sitepoint.com/html5-full-screen-api/ */
|
||||
#map:-webkit-full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
|
||||
#map:-moz-full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
|
||||
#map:full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
|
||||
.leaflet-pseudo-fullscreen { position: fixed !important; width: 100% !important; height: 100% !important; top: 0px !important; left: 0px !important; z-index: 99999; }
|
||||
</style>
|
||||
<script src="http://cdn.leafletjs.com/leaflet-0.7/leaflet.js"></script>
|
||||
<script src="http://cdn.leafletjs.com/leaflet-0.7.5/leaflet.js"></script>
|
||||
<script src="Control.FullScreen.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
@@ -21,9 +21,10 @@
|
||||
<div id="map"></div>
|
||||
|
||||
<script>
|
||||
var base = new L.TileLayer('http://{s}.www.toolserver.org/tiles/bw-mapnik/{z}/{x}/{y}.png', {
|
||||
maxZoom: 18,
|
||||
attribution: '© <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, <a href="http://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>'
|
||||
var base = new L.TileLayer('http://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}.png', {
|
||||
maxZoom: 19,
|
||||
subdomains: 'abcd',
|
||||
attribution: '© <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a> © <a href="http://cartodb.com/attributions">CartoDB</a>'
|
||||
});
|
||||
|
||||
var map = new L.Map('map', {
|
||||
@@ -32,7 +33,8 @@
|
||||
zoom: 5,
|
||||
fullscreenControl: true,
|
||||
fullscreenControlOptions: { // optional
|
||||
title:"Show me the fullscreen !"
|
||||
title:"Show me the fullscreen !",
|
||||
titleCancel:"Exit fullscreen mode"
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user