Skip to content

Commit 86a7f49

Browse files
author
Nick
committed
Added more verbose layer style docs
1 parent 2a95fc2 commit 86a7f49

14 files changed

+4084
-447
lines changed

docs/BackgroundLayer.md

+83-6
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,86 @@
1717

1818

1919
### styles
20-
| Name | Type | Requires | Disabled By | Description |
21-
| ---- | :--: | :------: | :---------: | :----------: |
22-
| `visibility` | `enum` | `none` | `none` | Whether this layer is displayed. |
23-
| `backgroundColor` | `color` | `none` | `backgroundPattern` | The color with which the background will be drawn. |
24-
| `backgroundPattern` | `string` | `none` | `none` | Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). |
25-
| `backgroundOpacity` | `number` | `none` | `none` | The opacity at which the background will be drawn. |
20+
___
21+
22+
#### Name
23+
visibility
24+
25+
#### Description
26+
Whether this layer is displayed.
27+
28+
#### Type
29+
enum
30+
31+
#### Default Value
32+
<span>visible</span>
33+
34+
#### Supported Values
35+
**visible** - The layer is shown.<br />
36+
**none** - The layer is not shown.<br />
37+
38+
39+
40+
___
41+
42+
#### Name
43+
backgroundColor
44+
45+
#### Description
46+
The color with which the background will be drawn.
47+
48+
#### Type
49+
color
50+
51+
#### Default Value
52+
<span>#000000</span>
53+
54+
55+
#### Disabled By
56+
backgroundPattern
57+
58+
#### Supported Style Functions
59+
camera
60+
61+
___
62+
63+
#### Name
64+
backgroundPattern
65+
66+
#### Description
67+
Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512).
68+
69+
#### Type
70+
string
71+
72+
#### Default Value
73+
<span></span>
74+
75+
76+
#### Supported Style Functions
77+
camera
78+
79+
___
80+
81+
#### Name
82+
backgroundOpacity
83+
84+
#### Description
85+
The opacity at which the background will be drawn.
86+
87+
#### Type
88+
number
89+
90+
#### Default Value
91+
<span>1</span>
92+
93+
#### Minimum
94+
0
95+
96+
97+
#### Maximum
98+
1
99+
100+
#### Supported Style Functions
101+
camera
102+

docs/CircleLayer.md

+260-14
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,263 @@
1717

1818

1919
### styles
20-
| Name | Type | Requires | Disabled By | Description |
21-
| ---- | :--: | :------: | :---------: | :----------: |
22-
| `visibility` | `enum` | `none` | `none` | Whether this layer is displayed. |
23-
| `circleRadius` | `number` | `none` | `none` | Circle radius. |
24-
| `circleColor` | `color` | `none` | `none` | The fill color of the circle. |
25-
| `circleBlur` | `number` | `none` | `none` | Amount to blur the circle. 1 blurs the circle such that only the centerpoint is full opacity. |
26-
| `circleOpacity` | `number` | `none` | `none` | The opacity at which the circle will be drawn. |
27-
| `circleTranslate` | `array` | `none` | `none` | The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively. |
28-
| `circleTranslateAnchor` | `enum` | `circleTranslate` | `none` | Controls the frame of reference for `circleTranslate`. |
29-
| `circlePitchScale` | `enum` | `none` | `none` | Controls the scaling behavior of the circle when the map is pitched. |
30-
| `circlePitchAlignment` | `enum` | `none` | `none` | Orientation of circle when map is pitched. |
31-
| `circleStrokeWidth` | `number` | `none` | `none` | The width of the circle's stroke. Strokes are placed outside of the `circleRadius`. |
32-
| `circleStrokeColor` | `color` | `none` | `none` | The stroke color of the circle. |
33-
| `circleStrokeOpacity` | `number` | `none` | `none` | The opacity of the circle's stroke. |
20+
___
21+
22+
#### Name
23+
visibility
24+
25+
#### Description
26+
Whether this layer is displayed.
27+
28+
#### Type
29+
enum
30+
31+
#### Default Value
32+
<span>visible</span>
33+
34+
#### Supported Values
35+
**visible** - The layer is shown.<br />
36+
**none** - The layer is not shown.<br />
37+
38+
39+
40+
___
41+
42+
#### Name
43+
circleRadius
44+
45+
#### Description
46+
Circle radius.
47+
48+
#### Type
49+
number
50+
51+
#### Default Value
52+
<span>5</span>
53+
54+
#### Units
55+
pixels
56+
57+
#### Minimum
58+
0
59+
60+
61+
#### Supported Style Functions
62+
camera, source, composite
63+
64+
___
65+
66+
#### Name
67+
circleColor
68+
69+
#### Description
70+
The fill color of the circle.
71+
72+
#### Type
73+
color
74+
75+
#### Default Value
76+
<span>#000000</span>
77+
78+
79+
#### Supported Style Functions
80+
camera, source, composite
81+
82+
___
83+
84+
#### Name
85+
circleBlur
86+
87+
#### Description
88+
Amount to blur the circle. 1 blurs the circle such that only the centerpoint is full opacity.
89+
90+
#### Type
91+
number
92+
93+
#### Default Value
94+
<span>0</span>
95+
96+
97+
#### Supported Style Functions
98+
camera, source, composite
99+
100+
___
101+
102+
#### Name
103+
circleOpacity
104+
105+
#### Description
106+
The opacity at which the circle will be drawn.
107+
108+
#### Type
109+
number
110+
111+
#### Default Value
112+
<span>1</span>
113+
114+
#### Minimum
115+
0
116+
117+
118+
#### Maximum
119+
1
120+
121+
#### Supported Style Functions
122+
camera, source, composite
123+
124+
___
125+
126+
#### Name
127+
circleTranslate
128+
129+
#### Description
130+
The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.
131+
132+
#### Type
133+
array&lt;number&gt;
134+
135+
#### Default Value
136+
<span>0,0</span>
137+
138+
#### Units
139+
pixels
140+
141+
142+
#### Supported Style Functions
143+
camera
144+
145+
___
146+
147+
#### Name
148+
circleTranslateAnchor
149+
150+
#### Description
151+
Controls the frame of reference for `circleTranslate`.
152+
153+
#### Type
154+
enum
155+
156+
#### Default Value
157+
<span>map</span>
158+
159+
#### Supported Values
160+
**map** - The circle is translated relative to the map.<br />
161+
**viewport** - The circle is translated relative to the viewport.<br />
162+
163+
164+
#### Requires
165+
circleTranslate
166+
167+
#### Supported Style Functions
168+
camera
169+
170+
___
171+
172+
#### Name
173+
circlePitchScale
174+
175+
#### Description
176+
Controls the scaling behavior of the circle when the map is pitched.
177+
178+
#### Type
179+
enum
180+
181+
#### Default Value
182+
<span>map</span>
183+
184+
#### Supported Values
185+
**map** - Circles are scaled according to their apparent distance to the camera.<br />
186+
**viewport** - Circles are not scaled.<br />
187+
188+
189+
#### Supported Style Functions
190+
camera
191+
192+
___
193+
194+
#### Name
195+
circlePitchAlignment
196+
197+
#### Description
198+
Orientation of circle when map is pitched.
199+
200+
#### Type
201+
enum
202+
203+
#### Default Value
204+
<span>viewport</span>
205+
206+
#### Supported Values
207+
**map** - The circle is aligned to the plane of the map.<br />
208+
**viewport** - The circle is aligned to the plane of the viewport.<br />
209+
210+
211+
#### Supported Style Functions
212+
camera
213+
214+
___
215+
216+
#### Name
217+
circleStrokeWidth
218+
219+
#### Description
220+
The width of the circle's stroke. Strokes are placed outside of the `circleRadius`.
221+
222+
#### Type
223+
number
224+
225+
#### Default Value
226+
<span>0</span>
227+
228+
#### Units
229+
pixels
230+
231+
#### Minimum
232+
0
233+
234+
235+
#### Supported Style Functions
236+
camera, source, composite
237+
238+
___
239+
240+
#### Name
241+
circleStrokeColor
242+
243+
#### Description
244+
The stroke color of the circle.
245+
246+
#### Type
247+
color
248+
249+
#### Default Value
250+
<span>#000000</span>
251+
252+
253+
#### Supported Style Functions
254+
camera, source, composite
255+
256+
___
257+
258+
#### Name
259+
circleStrokeOpacity
260+
261+
#### Description
262+
The opacity of the circle's stroke.
263+
264+
#### Type
265+
number
266+
267+
#### Default Value
268+
<span>1</span>
269+
270+
#### Minimum
271+
0
272+
273+
274+
#### Maximum
275+
1
276+
277+
#### Supported Style Functions
278+
camera, source, composite
279+

0 commit comments

Comments
 (0)