Project Name | Stars | Downloads | Repos Using This | Packages Using This | Most Recent Commit | Total Releases | Latest Release | Open Issues | License | Language |
---|---|---|---|---|---|---|---|---|---|---|
Vim Startify | 5,138 | 3 days ago | 73 | mit | Vim Script | |||||
:link: The fancy start screen for Vim. | ||||||||||
Artplayer | 1,963 | 13 | 10 days ago | 135 | May 14, 2023 | 27 | mit | JavaScript | ||
:art: ArtPlayer.js is a modern and full featured HTML5 video player | ||||||||||
Loklak Timeline Plugin | 1,083 | 5 years ago | JavaScript | |||||||
loklak timeline plugin | ||||||||||
Slimefun4 | 802 | 3 days ago | 88 | gpl-3.0 | Java | |||||
Slimefun 4 - A unique Spigot/Paper plugin that looks and feels like a modpack. We've been giving you backpacks, jetpacks, reactors and much more since 2013. | ||||||||||
Vlc Pause Click Plugin | 774 | 3 days ago | 13 | lgpl-2.1 | C | |||||
Plugin for VLC that pauses/plays video on mouse click | ||||||||||
Androidsourceviewer | 669 | 4 years ago | 9 | Java | ||||||
Android Source Viewer Plugin for Android Studio | ||||||||||
Painterro | 616 | 2 months ago | 25 | mit | JavaScript | |||||
Painterro - JavaScript painting plugin | ||||||||||
Vim For Server | 455 | 4 years ago | 3 | Vim script | ||||||
.vimrc, simple configures for server, without plugins. | ||||||||||
Maglev | 439 | 5 years ago | 13 | Shell | ||||||
:monorail: A Tmux theme made to work together with bullet-train.zsh | ||||||||||
Stream | 392 | 3 days ago | 99 | gpl-2.0 | PHP | |||||
🗄️ Stream plugin for WordPress |
Leaflet promise based plugin which take screenshot of map. Used dom-to-image.
npm install leaflet-simple-map-screenshoter --save
Open (see in /examples)
Add save screenshot button to leaflet control panel
import * as L from 'leaflet'
// import script after leaflet
import {SimpleMapScreenshoter} from 'leaflet-simple-map-screenshoter'
new SimpleMapScreenshoter().addTo(this.map)
From cdn
<script src="https://unpkg.com/leaflet"></script>
<script src="https://unpkg.com/leaflet-simple-map-screenshoter"></script>
<script>
L.simpleMapScreenshoter().addTo(map)
</script>
For custom usage
import 'leaflet'
// import script after leaflet
import 'leaflet-simple-map-screenshoter'
let pluginOptions = {
cropImageByInnerWH: true, // crop blank opacity from image borders
hidden: false, // hide screen icon
preventDownload: false, // prevent download on button click
domtoimageOptions: {}, // see options for dom-to-image
position: 'topleft', // position of take screen icon
screenName: 'screen', // string or function
iconUrl: ICON_SVG_BASE64, // screen btn icon base64 or url
hideElementsWithSelectors: ['.leaflet-control-container'], // by default hide map controls All els must be child of _map._container
mimeType: 'image/png', // used if format == image,
caption: null, // string or function, added caption to bottom of screen
captionFontSize: 15,
captionFont: 'Arial',
captionColor: 'black',
captionBgColor: 'white',
captionOffset: 5,
// callback for manually edit map if have warn: "May be map size very big on that zoom level, we have error"
// and screenshot not created
onPixelDataFail: async function({ node, plugin, error, mapPane, domtoimageOptions }) {
// Solutions:
// decrease size of map
// or decrease zoom level
// or remove elements with big distanses
// and after that return image in Promise - plugin._getPixelDataOfNormalMap
return plugin._getPixelDataOfNormalMap(domtoimageOptions)
}
}
this.simpleMapScreenshoter = L.simpleMapScreenshoter(pluginOptions).addTo(this.map)
let format = 'blob' // 'image' - return base64, 'canvas' - return canvas
let overridedPluginOptions = {
mimeType: 'image/jpeg'
}
this.simpleMapScreenshoter.takeScreen(format, overridedPluginOptions).then(blob => {
alert('done')
// FileSaver.saveAs(blob, 'screen.png')
}).catch(e => {
console.error(e)
})
simpleMapScreenshoter.click - on leaflet control panel take screen btn click
simpleMapScreenshoter.takeScreen - start build screenshot
simpleMapScreenshoter.done - screenshot build ended
simpleMapScreenshoter.error - on error, return Error instance