-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use latest Leaflet version. Add meta viewport tag for the page to look OK on mobile. Update broken URL in README.
- Loading branch information
Showing
3 changed files
with
22 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<link rel="stylesheet" href="style.css" /> | ||
<link rel="stylesheet" href="https://unpkg.com/[email protected]/dist/leaflet.css" /> | ||
<link rel="stylesheet" href="../src/leaflet-areaselect.css" /> | ||
|
@@ -26,10 +27,10 @@ | |
<button id="setDimensions">Set Dimensions</button> | ||
</div> | ||
</div> | ||
<a href="https://github.com/heyman/leaflet-areaselect"><img style="position:absolute; top:0; right:0; border:0; z-index: 1000;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_red_aa0000.png" alt="Fork me on GitHub"></a> | ||
<a href="https://github.com/heyman/leaflet-areaselect"><img style="position:absolute; top:0; right:0; border:0; z-index: 1000;" src="https://github.blog/wp-content/uploads/2008/12/forkme_right_red_aa0000.png?resize=149%2C149" alt="Fork me on GitHub"></a> | ||
|
||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script> | ||
<script src="https://unpkg.com/leaflet@1.0.2/dist/leaflet.js"></script> | ||
<script src="https://unpkg.com/leaflet@1.9.4/dist/leaflet.js"></script> | ||
<script src="../src/leaflet-areaselect.js"></script> | ||
<script> | ||
// initialize map | ||
|
@@ -43,6 +44,8 @@ | |
var bounds = this.getBounds(); | ||
$("#result .sw").val(bounds.getSouthWest().lat + ", " + bounds.getSouthWest().lng); | ||
$("#result .ne").val(bounds.getNorthEast().lat + ", " + bounds.getNorthEast().lng); | ||
$(".width").val(this.getDimensions().width); | ||
$(".height").val(this.getDimensions().height); | ||
}); | ||
areaSelect.addTo(map); | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters