メインコンテンツまでスキップ

Spec Reference

This documentation is divided into several sections:

  • Root. The root level properties of a Mapbox style specify the map's layers, tile sources and other resources, and default values for the initial camera position when not specified elsewhere.
  • Light. A style's light property provides a global light source for that style.
  • Sources. A map or layer source states which data the map should display. Specify the type of source with the "type" property, which must be one of vector, raster, raster-array, raster-dem, geojson, image, video.
  • Sprite. A sprite is a single image that contains all the icon and pattern images included in a style.
  • Glyphs. A style's glyphs property provides a URL template for loading signed-distance-field glyph sets (fonts) in PBF format.
  • Imports. A style's imports property lists base styles expanded by the current one.
  • Slots. A slot layer type marks positions for inserting layers from styles that expands the current one.
  • Configuration. A style's schema property describes how the current style can be adjusted by styles that depend on it.
  • Transition. A transition property controls timing for the interpolation between a transitionable style property's previous value and new value.
  • Projection. A style's projection property sets which projection a map is rendered in.
  • Terrain. A style's terrain property is a global modifier that elevates layers and markers based on a DEM data source.
  • Fog. A style's fog property is a global styling effect that can be used to create an atmospheric gradient, stars, and haze.
  • Layers. A style's layers property lists all the layers available in that style. The type of layer is specified by the "type" property, and must be one of background, fill, line, symbol, raster, raster-particle, circle, fill-extrusion, heatmap, hillshade, sky.
  • Types. A Mapbox style contains values of various types, most commonly as values for the style properties of a layer.
  • Expressions. An expression defines a formula for computing the value of a property based on various operators and data from the current map view or map sources.
  • Other. Legacy style properties are documented in this section.

Most of these sections describe a top-level property and its associated child properties. Others document more general concepts or patterns used throughout a Mapbox style such as expressions and types. Many sections also include inline JSON examples and related resources.

このpageは役に立ちましたか?