GithubHelp home page GithubHelp logo

isabella232 / fresco Goto Github PK

View Code? Open in Web Editor NEW

This project forked from go-spatial/fresco

0.0 0.0 0.0 12.4 MB

An open source vector tile style editor

Home Page: https://fresco.gospatial.org

License: Apache License 2.0

HTML 0.22% CSS 5.94% JavaScript 91.02% Shell 0.55% Go 2.27%

fresco's Introduction

fresco

Netlify Status

For Cartography Professionals and Amateur Map Makers Alike

Fresco is an open source Mapbox Vector Tile Style editor that allows cartographers to craft stylesheets for use with Mapbox GL maps. Unlike other style editors, Fresco does not attempt to hide the complexity of Mapbox GL Styles - but rather exposes and surfaces it for maximum control and flexibility. This allows the user to implement rich, interactive styles utilizing data driven properties with expressions.

When using Fresco, it may be helpful to have the Mapbox Style Spec available as a reference.

Fresco runs in the browser and styles created and modified with Fresco are saved to the browser's local storage and are synced on changes. Be sure to download styles to your computer as a backup. Remote style storage and collaboration tools are coming soon.

Give it a try: https://fresco.gospatial.org/

map editing screen shot

Features

  • Rich map interaction style editor for use with Mapbox GL styles
  • Editor mode for quick changes and at a glance comprehension
  • Interactive JSON code editor for maximum control
  • Feature inspection and state setting
  • Works in our out of the browser - Fresco is available as a downloadable application
  • Auto save on style changes
  • Styles persisted to local storage (in the browser)
  • Mapbox GL style error parser - displays the error at the line location in the style
  • Integrated Mapbox GL style spec attributes (info on style fields)
  • Custom domain header configurations - useful for domains which require Authorization headers
  • Open and free for everyone license

Usage

Fresco may be used in the browser by visiting https://fresco.gospatial.org/ or by downloading a pre compiled binary from the releases page.

Running from source

Fresco is built on top of React. To run Fresco from source use the following steps:

  1. Download the latest version of Node.js
  2. Clone this repository to your computer
  3. Navigate to this repo on your computer
  4. Run npm install
  5. To startup, run npm start - Fresco should open in a browser window
  6. To build Fresco for deployment run npm run build - the deployment files will be inside the /build directoty

Hosting Fresco from a subdirectory

Fresco is able to be hosted from a subdirectory of a domain (i.e. https://yourhost.com/fresco/). To enable this functionality, modify the package.json file

{
  "name": "fresco",
  "version": "0.0.1",
  "private": true,
  "homepage": "/fresco",
...

Also, you'll need to modify the config inside /src/config/index.json.

{
	"homepage": "/fresco"
}

Then use npm run build to build Fresco for deployment.

Change default Fresco styles

You are able to change the default styles that Fresco loads up with. Update /src/config/stylesDefault.json with any number of Mapbox style JSONs. To load multiple styles in use an array structure like shown below:

[
	{
		"id": "style1",
		...
	},{
		"id": "style2",
		...
	}
]

For a single style, just replace the contents of /src/config/stylesDefault.json with the style JSON.

When testing default styles, you'll have to clear out your localStorage frescoStylesStore or use an incognito window.

Contributing

Contributions are welcome! Fork the repo and send in a PR with any bug fixes or features.

Looking for a vector tile server?

If you're looking to create vector tiles that can be styled with Fresco, check out tegola!

fresco's People

Contributors

dependabot[bot] avatar gdey avatar justenpalmer avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.