Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Style properties are always saved, even when "not shown" #498

Closed
stevage opened this issue Feb 23, 2016 · 3 comments
Closed

Style properties are always saved, even when "not shown" #498

stevage opened this issue Feb 23, 2016 · 3 comments

Comments

@stevage
Copy link

stevage commented Feb 23, 2016

  1. Create a point
  2. Edit properties
  3. Uncheck "Show style properties"
  4. Add some other property
  5. Save
  6. The generated code includes the default styles.

Basically, if the property editor window gets opened, default styles get saved into the file.

@tomscholz
Copy link
Contributor

I don't see the problem.

@stevage
Copy link
Author

stevage commented Jan 16, 2018

The problem is the editor is adding a bunch of SimpleStyle properties which the user didn't ask for, and can't avoid. That would be (maybe) fine if you're generating a file for some application which interprets SimpleStyle, but in most cases, it's just unwanted noise.

I very often use geojson.io to create sample data, especially for Mapbox-GL-JS, and I don't ever want these properties.

It makes using the property editor unusable IMHO.

Here's an example of the code generated through the above process:

{
  "type": "FeatureCollection",
  "features": [
    {
      "type": "Feature",
      "properties": {
        "marker-color": "#7e7e7e",
        "marker-size": "medium",
        "marker-symbol": "",
        "test": "foo"
      },
      "geometry": {
        "type": "Point",
        "coordinates": [
          154.3359375,
          66.08936427047088
        ]
      }
    }
  ]
}

@chriswhong
Copy link
Contributor

style properties were removed in the recent UI refresh, others are requesting them to be restored, see #712

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants