
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
🌏 Render a map on browser easily.
Just download the js
and include it in your HTML
.
<!-- add easy.map in your html -->
<script type="text/javascript" src="PATH/TO/easy-map.min.js"></script>
<!-- if you use AMD or CommonJS -->
<script>
require(["PATH/TO/easy-map"], function (EasyMap) {
// Do something..
});
/* or */
var EasyMap = require("easy-map");
</script>
$ yarn add easy-map
# or
$ npm i easy-map
$ npm run demo
# then access http://127.0.0.1:7777
Map Key
to use map API
.
Parameter | Type | Remarks |
---|---|---|
mapType | string | Required (It must be included in ['google'] ) |
element | DOM Node | Required |
key | string | Required |
source | object | Specific location's information |
source.lat | number | Specific location's latitude |
source.lng | number | Specific location's longitude |
source.marker | object | Marker on Specific location |
source.marker.icon | string | Write icon image's path |
source.marker.width | number | Marker's width (px) |
source.marker.height | number | Marker's height (px) |
source.marker.verticalAlign | string | top, bottom, middle |
source.marker.horizontalAlign | string | right, left, center |
source.infoWindow | object | Marker's infoWindow |
source.infoWindow.content | string | infoWindow's content |
source.infoWindow.maxWidth | number | infoWindow's max width (px) |
source.infoWindow.isOpen | boolean | initial open status of source's infoWindow |
source.infoWindow.backgroundColor | string | infoWindow's background color (hex code or color name )ONLY FOR NAVER |
source.infoWindow.borderColor | string | infoWindow's border color (hex code or color name )ONLY FOR NAVER |
source.infoWindow.borderWidth | number | infoWindow's border width (px) ONLY FOR NAVER |
source.infoWindow.anchorSize | object | infoWindow's anchor widthnew naver.maps.Size(30, 30) ONLY FOR NAVER |
source.infoWindow.anchorSkew | boolean | infoWindow's anchor shape ONLY FOR NAVER |
source.infoWindow.pixelOffset | object | infoWindow's offsetnew naver.maps.Point(20, -20) ONLY FOR NAVER |
coords | array | Set of coordinates |
coords[n] | object | Same as source |
closeInfoWindowAuto | boolean | Close automately when click a marker |
clickedNestedMarker | function | Callback function when click nested markers |
- | - | - |
coords[n].infoWindow.content | string | If you write {{distance m}}, you can get the distance between coores[n] and source Available unites : [ m , km , ft , yd ] |
Google Map
const easyMap = new EasyMap({
mapType: 'google',
key: 'AIzaSyBL4Ugej1KvkfIrU2qOhoAkE85rKEcTApo',
element: document.getElementById('map'),
source: {
lat: 37.5666103,
lng: 126.9783882,
marker: { icon: '//assets-cdn.github.com/images/modules/contact/heartocat.png', width: 48, height: 48, verticalAlign: 'top' },
infoWindow: { content: '<div class="info-window">Source Marker</div>', maxWidth: 50 },
},
coords: [{
lat: 37.5658528,
lng: 126.9779845,
name: 'Marker 1',
marker: { icon: '//assets-cdn.github.com/images/modules/contact/heartocat.png', width: 36, height: 36, verticalAlign: 'middle' },
infoWindow: { content: '<div class="info-window">Marker 1<br>distance is {{distance m}}</div>', maxWidth: 50 },
}, {
lat: 37.5658528,
lng: 126.9779845,
name: 'Marker 2',
marker: { icon: '//assets-cdn.github.com/images/modules/contact/heartocat.png', width: 36, height: 36, verticalAlign: 'middle' },
infoWindow: { content: '<div class="info-window">Marker 2<br>distance is {{distance km}}</div>', maxWidth: 50 },
}],
closeInfoWindowAuto: true,
clickedNestedMarker: (cb, ids, strs) => {
const userInput = prompt(`You clicked nested markers! Select on.\n${strs}`, '');
cb(+userInput);
},
});
easyMap.start();
Naver Map
const easyMap = new EasyMap({
mapType: 'naver',
key: 'ZINRRHtKwGpXNxXjcqwv',
element: document.getElementById('map'),
source: {
lat: 37.5666103,
lng: 126.9783882,
marker: { icon: '//assets-cdn.github.com/images/modules/contact/heartocat.png', width: 48, height: 48, verticalAlign: 'top' },
infoWindow: { content: '<div class="info-window">Source Marker</div>', maxWidth: 50 },
},
coords: [{
lat: 37.5658528,
lng: 126.9779845,
name: 'Marker 1',
marker: { icon: '//assets-cdn.github.com/images/modules/contact/heartocat.png', width: 36, height: 36, verticalAlign: 'middle' },
infoWindow: { content: '<div class="info-window">Marker 1<br>distance is {{distance m}}</div>', maxWidth: 50 },
}, {
lat: 37.5658528,
lng: 126.9779845,
name: 'Marker 2',
marker: { icon: '//assets-cdn.github.com/images/modules/contact/heartocat.png', width: 36, height: 36, verticalAlign: 'middle' },
infoWindow: { content: '<div class="info-window">Marker 2<br>distance is {{distance km}}</div>', maxWidth: 50 },
}],
closeInfoWindowAuto: true,
clickedNestedMarker: (cb, ids, strs) => {
const userInput = prompt(`You clicked nested markers! Select on.\n${ strs }`, '');
cb(+userInput);
},
});
easyMap.start();
Google Maps
Naver Maps
1.0.0
1.0.2
1.0.3
switch-case
(Use braces in switch-case).1.1.0
1.1.2
1.1.4
Copyright (c) 2017 wonism
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
FAQs
This is a open source project to represent map in your web page easily.
We found that easy-map demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.