Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

carto

Package Overview
Dependencies
Maintainers
44
Versions
68
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

carto - npm Package Compare versions

Comparing version 0.14.1 to 0.15.0

15

lib/carto/renderer.js

@@ -126,3 +126,3 @@ var _ = require('underscore');

for (var k = 0, rule, style_name; k < sorted.length; k++) {
rule = sorted[k];
rule = foldStyle(sorted[k]);
style_name = l.name + (rule.attachment !== '__default__' ? '-' + rule.attachment : '');

@@ -359,2 +359,15 @@

// Removes dead style definitions that can never be reached
// when filter-mode="first". The style is modified in-place
// and returned. The style must be sorted.
function foldStyle(style) {
for (var i = 0; i < style.length; i++) {
for (var j = style.length - 1; j > i; j--) {
if (style[j].filters.cloneWith(style[i].filters) === null)
style.splice(j, 1);
}
}
return style;
}
/**

@@ -361,0 +374,0 @@ * Find a rule like Map { background-color: #fff; },

@@ -29,2 +29,14 @@ var tree = require('../tree');

}
// Rebuild the filters dict after var subst.
var result = new tree.Filterset();
for (var i in this.filters) {
var err = result.add(this.filters[i]);
if (err) {
var filename = this.filters[i].filename;
if (filename)
err = filename + ': ' + err;
throw new Error(err);
}
}
this.filters = result.filters;
return this;

@@ -88,3 +100,3 @@ };

if (value.match(/^[0-9]+(\.[0-9]*)?$/)) value = parseFloat(value);
if (value.match(/^[+-]?[0-9]+(\.[0-9]*)?$/)) value = parseFloat(value);

@@ -91,0 +103,0 @@ switch (filter.op) {

4

package.json
{
"name": "carto",
"version": "0.14.1",
"version": "0.15.0",
"description": "Mapnik Stylesheet Compiler",

@@ -41,3 +41,3 @@ "url": "https://github.com/mapbox/carto",

"underscore": "~1.6.0",
"mapnik-reference": "~7.0.0",
"mapnik-reference": "~8.2.0",
"optimist": "~0.6.0"

@@ -44,0 +44,0 @@ },

@@ -14,3 +14,3 @@ # CartoCSS

For users looking to learn how to use TileMill the best places to start are to 1) Download [TileMill](http://mapbox.com/carto/) and review the [Carto reference documentation](http://mapbox.com/carto/).
For users looking to learn how to use TileMill the best places to start are to 1) Download [TileMill](https://github.com/mapbox/carto/) and review the [Carto reference documentation](https://github.com/mapbox/carto/blob/master/docs/latest.md).

@@ -26,3 +26,3 @@ Tutorials like the [TileMill Crashcourse](https://www.mapbox.com/tilemill/docs/crashcourse/styling/) are a great place to start to learn the basics of CartoCSS.

- [How to style polygons](https://www.mapbox.com/tilemill/docs/guides/styling-polygons/)
- See also the (Styling Concepts)[#styling-concepts] for explanations of advanced features.
- See also the [Styling Concepts](#styling-concepts) for explanations of advanced features.

@@ -226,5 +226,7 @@ ## Developers

To install, download or clone this repository, then add the `vim-carto`
directory located at `build/vim-carto` to your `~/.vim` file.
To install, download or clone this repository, then copy the `vim-carto`
directory located at `build/vim-carto` to your `~/.vim` directory.
cp build/vim-carto/* ~/.vim -R
## Credits

@@ -231,0 +233,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc