All Projects → mapbox → Mapbox Gl Draw

mapbox / Mapbox Gl Draw

Licence: isc
Draw tools for mapbox-gl-js

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Mapbox Gl Draw

react-map-gl-draw
React Component for Mapbox GL Draw
Stars: ✭ 50 (-91.21%)
Mutual labels:  drawing, mapbox-gl, mapbox-gl-js
Osm Liberty
A free Mapbox GL basemap style for everyone
Stars: ✭ 231 (-59.4%)
Mutual labels:  mapbox-gl, mapbox-gl-js
React Mapbox Gl
A React binding of mapbox-gl-js
Stars: ✭ 1,683 (+195.78%)
Mutual labels:  mapbox-gl, mapbox-gl-js
maptalks.mapboxgl
MapboxglLayer for maptalks.js
Stars: ✭ 51 (-91.04%)
Mutual labels:  mapbox-gl, mapbox-gl-js
React Map Gl
React friendly API wrapper around MapboxGL JS
Stars: ✭ 6,244 (+997.36%)
Mutual labels:  mapbox-gl, mapbox-gl-js
Editor
An open source visual editor for the 'Mapbox Style Specification'
Stars: ✭ 1,167 (+105.1%)
Mutual labels:  mapbox-gl, mapbox-gl-js
deck.gl-time-series-widget
A React Time Slider implementation for DECK.GL - (non)temporal data - by CPU filtering ⌛
Stars: ✭ 19 (-96.66%)
Mutual labels:  mapbox-gl, mapbox-gl-js
Mapbox Gl Js
Interactive, thoroughly customizable maps in the browser, powered by vector tiles and WebGL
Stars: ✭ 8,017 (+1308.96%)
Mutual labels:  mapbox-gl, mapbox-gl-js
react-map-gl-cluster
Urbica React Cluster Component for Mapbox GL JS
Stars: ✭ 27 (-95.25%)
Mutual labels:  mapbox-gl, mapbox-gl-js
react-mapboxgl
Declarative React components for mapbox-gl-js.
Stars: ✭ 15 (-97.36%)
Mutual labels:  mapbox-gl, mapbox-gl-js
angular-mapboxgl-directive
AngularJS directive for Mapbox GL
Stars: ✭ 43 (-92.44%)
Mutual labels:  mapbox-gl, mapbox-gl-js
React Map Gl
React Component Library for Mapbox GL JS
Stars: ✭ 298 (-47.63%)
Mutual labels:  mapbox-gl, mapbox-gl-js
who-owns-what
Who owns what in nyc?
Stars: ✭ 146 (-74.34%)
Mutual labels:  mapbox-gl, mapbox-gl-js
Mapdeck
R interface to Deck.gl and Mapbox
Stars: ✭ 296 (-47.98%)
Mutual labels:  mapbox-gl, mapbox-gl-js
Martin
Blazing fast and lightweight PostGIS vector tiles server
Stars: ✭ 540 (-5.1%)
Mutual labels:  mapbox-gl, mapbox-gl-js
Canvas
Canvas is a Go drawing library based on OpenGL or using software rendering that is very similar to the HTML5 canvas API
Stars: ✭ 358 (-37.08%)
Mutual labels:  drawing
Tui.image Editor
🍞🎨 Full-featured photo image editor using canvas. It is really easy, and it comes with great filters.
Stars: ✭ 4,761 (+736.73%)
Mutual labels:  drawing
Qgis2web
A QGIS plugin to export a map to an OpenLayers, Leaflet, or Mapbox GL JS webmap
Stars: ✭ 349 (-38.66%)
Mutual labels:  mapbox-gl-js
Anyimagekit
A toolbox for pick/edit/capture photo or video. Written in Swift.
Stars: ✭ 324 (-43.06%)
Mutual labels:  drawing
Azure Design
Here you will find my complete Azure Visio Stencil and bonus SVG and PNG versions for all of the Azure Service and configuration items.
Stars: ✭ 470 (-17.4%)
Mutual labels:  drawing

@mapbox/mapbox-gl-draw

Greenkeeper badge Build Status

Adds support for drawing and editing features on mapbox-gl.js maps. See a live example here

Requires mapbox-gl-js. Compatible versions are documented in the package.json

On NPM this package has recently moved from mapbox-gl-draw to @mapbox/mapbox-gl-draw

Installing

npm install @mapbox/mapbox-gl-draw

Draw ships with CSS, make sure you include it in your build.

When using modules

import '@mapbox/mapbox-gl-draw/dist/mapbox-gl-draw.css'

When using CDN

<link rel='stylesheet' href='https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-draw/v1.2.0/mapbox-gl-draw.css' type='text/css' />

Usage in your application

When using modules

import mapboxgl from 'mapbox-gl';
import MapboxDraw from "@mapbox/mapbox-gl-draw";

When using a CDN

<script src='https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-draw/v1.2.0/mapbox-gl-draw.js'></script>

Example setup

mapboxgl.accessToken = 'YOUR_ACCESS_TOKEN';

var map = new mapboxgl.Map({
  container: 'map',
  style: 'mapbox://styles/mapbox/streets-v8',
  center: [40, -74.50],
  zoom: 9
});

var Draw = new MapboxDraw();

// Map#addControl takes an optional second argument to set the position of the control.
// If no position is specified the control defaults to `top-right`. See the docs
// for more details: https://docs.mapbox.com/mapbox-gl-js/api/#map#addcontrol

map.addControl(Draw, 'top-left');

map.on('load', function() {
  // ALL YOUR APPLICATION CODE
});

https://www.mapbox.com/mapbox-gl-js/example/mapbox-gl-draw/

See API.md for complete reference.

Enhancements and New Interactions

For additional functionality check out our list of custom modes.

Mapbox Draw accepts functionality changes after the functionality has been proven out via a custom mode. This lets users experiment and validate their mode before entering a review process, hopefully promoting innovation. When you write a custom mode, please open a PR adding it to our list of custom modes.

Developing and testing

Install dependencies, build the source files and crank up a server via:

git clone [email protected]:mapbox/mapbox-gl-draw.git
yarn install
yarn start & open "http://localhost:9967/debug/?access_token=<token>"

Testing

npm run test

Publishing

To github and npm

npm version (major|minor|patch)
git push --tags
git push
npm publish

To CDN

# make sure you are authenticated for AWS
git checkout v{x.y.z}
yarn install
yarn run prepublish
aws s3 cp --recursive --acl public-read dist s3://mapbox-gl-js/plugins/mapbox-gl-draw/v{x.y.z}

Update the version number in the GL JS example.

Naming actions

We're trying to follow standards when naming things. Here is a collection of links where we look for inspiration.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].