Style sets
CartoCSS, inline or as a compiled style project. Created with kind styleset.
| Type | Class |
|---|---|
"cartocss" | CartoCSSStyleSet |
"project" | CompiledStyleSet |
"cartocss" — CartoCSSStyleSet
{"type": "cartocss", "css": …, "assets": …}
{"type": "cartocss", "css": …}
| Key | Type | Always required | Notes |
|---|---|---|---|
css | string | yes | |
assets | object std::shared_ptr<AssetPackage> | no | an id of kind assets, or an inline spec |
| Property | Type | Access | Description |
|---|---|---|---|
assetPackage | object std::shared_ptr<massif::AssetPackage> | read-only | Returns the style asset package. |
cartoCSS | string | read-only | Returns the CartoCSS string used for the style. |
"project" — CompiledStyleSet
{"type": "project", "assets": …, "name": …}
{"type": "project", "assets": …}
| Key | Type | Always required | Notes |
|---|---|---|---|
assets | object std::shared_ptr<AssetPackage> | yes | an id of kind assets, or an inline spec |
name | string | no |
| Property | Type | Access | Description |
|---|---|---|---|
assetPackage | object std::shared_ptr<massif::AssetPackage> | read-only | Returns the style asset package. |
styleAssetName | string | read-only | Returns the asset name defining the current style name. |
styleName | string | read-only | Returns the current style name. |