Skip to content

Commit 17d23e8

Browse files
committed
Updated augen scripts to run with current(old) v8.json
1 parent 5e3b75b commit 17d23e8

File tree

20 files changed

+1909
-699
lines changed

20 files changed

+1909
-699
lines changed

android/rctmgl/src/main/java/com/mapbox/rctmgl/components/styles/RCTMGLStyleFactory.java

+242
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212
import com.mapbox.mapboxsdk.style.layers.PropertyValue;
1313
import com.mapbox.mapboxsdk.style.layers.RasterLayer;
1414
import com.mapbox.mapboxsdk.style.layers.SymbolLayer;
15+
import com.mapbox.mapboxsdk.style.layers.HeatmapLayer;
16+
import com.mapbox.mapboxsdk.style.layers.HillshadeLayer;
1517
import com.mapbox.mapboxsdk.style.layers.TransitionOptions;
1618
import com.mapbox.mapboxsdk.style.light.Light;
1719
import com.mapbox.mapboxsdk.style.light.Position;
@@ -454,6 +456,47 @@ public static void setCircleLayerStyle(final CircleLayer layer, RCTMGLStyle styl
454456
}
455457
}
456458
}
459+
public static void setHeatmapLayerStyle(final HeatmapLayer layer, RCTMGLStyle style) {
460+
List<String> styleKeys = style.getAllStyleKeys();
461+
462+
if (styleKeys.size() == 0) {
463+
return;
464+
}
465+
466+
for (String styleKey : styleKeys) {
467+
final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey);
468+
469+
switch (styleKey) {
470+
case "visibility":
471+
RCTMGLStyleFactory.setVisibility(layer, styleValue);
472+
break;
473+
case "heatmapRadius":
474+
RCTMGLStyleFactory.setHeatmapRadius(layer, styleValue);
475+
break;
476+
case "heatmapRadiusTransition":
477+
RCTMGLStyleFactory.setHeatmapRadiusTransition(layer, styleValue);
478+
break;
479+
case "heatmapWeight":
480+
RCTMGLStyleFactory.setHeatmapWeight(layer, styleValue);
481+
break;
482+
case "heatmapIntensity":
483+
RCTMGLStyleFactory.setHeatmapIntensity(layer, styleValue);
484+
break;
485+
case "heatmapIntensityTransition":
486+
RCTMGLStyleFactory.setHeatmapIntensityTransition(layer, styleValue);
487+
break;
488+
case "heatmapColor":
489+
RCTMGLStyleFactory.setHeatmapColor(layer, styleValue);
490+
break;
491+
case "heatmapOpacity":
492+
RCTMGLStyleFactory.setHeatmapOpacity(layer, styleValue);
493+
break;
494+
case "heatmapOpacityTransition":
495+
RCTMGLStyleFactory.setHeatmapOpacityTransition(layer, styleValue);
496+
break;
497+
}
498+
}
499+
}
457500
public static void setFillExtrusionLayerStyle(final FillExtrusionLayer layer, RCTMGLStyle style) {
458501
List<String> styleKeys = style.getAllStyleKeys();
459502

@@ -571,6 +614,53 @@ public static void setRasterLayerStyle(final RasterLayer layer, RCTMGLStyle styl
571614
}
572615
}
573616
}
617+
public static void setHillshadeLayerStyle(final HillshadeLayer layer, RCTMGLStyle style) {
618+
List<String> styleKeys = style.getAllStyleKeys();
619+
620+
if (styleKeys.size() == 0) {
621+
return;
622+
}
623+
624+
for (String styleKey : styleKeys) {
625+
final RCTMGLStyleValue styleValue = style.getStyleValueForKey(styleKey);
626+
627+
switch (styleKey) {
628+
case "visibility":
629+
RCTMGLStyleFactory.setVisibility(layer, styleValue);
630+
break;
631+
case "hillshadeIlluminationDirection":
632+
RCTMGLStyleFactory.setHillshadeIlluminationDirection(layer, styleValue);
633+
break;
634+
case "hillshadeIlluminationAnchor":
635+
RCTMGLStyleFactory.setHillshadeIlluminationAnchor(layer, styleValue);
636+
break;
637+
case "hillshadeExaggeration":
638+
RCTMGLStyleFactory.setHillshadeExaggeration(layer, styleValue);
639+
break;
640+
case "hillshadeExaggerationTransition":
641+
RCTMGLStyleFactory.setHillshadeExaggerationTransition(layer, styleValue);
642+
break;
643+
case "hillshadeShadowColor":
644+
RCTMGLStyleFactory.setHillshadeShadowColor(layer, styleValue);
645+
break;
646+
case "hillshadeShadowColorTransition":
647+
RCTMGLStyleFactory.setHillshadeShadowColorTransition(layer, styleValue);
648+
break;
649+
case "hillshadeHighlightColor":
650+
RCTMGLStyleFactory.setHillshadeHighlightColor(layer, styleValue);
651+
break;
652+
case "hillshadeHighlightColorTransition":
653+
RCTMGLStyleFactory.setHillshadeHighlightColorTransition(layer, styleValue);
654+
break;
655+
case "hillshadeAccentColor":
656+
RCTMGLStyleFactory.setHillshadeAccentColor(layer, styleValue);
657+
break;
658+
case "hillshadeAccentColorTransition":
659+
RCTMGLStyleFactory.setHillshadeAccentColorTransition(layer, styleValue);
660+
break;
661+
}
662+
}
663+
}
574664
public static void setBackgroundLayerStyle(final BackgroundLayer layer, RCTMGLStyle style) {
575665
List<String> styleKeys = style.getAllStyleKeys();
576666

@@ -1591,6 +1681,74 @@ public static void setCircleStrokeOpacityTransition(CircleLayer layer, RCTMGLSty
15911681
}
15921682
}
15931683

1684+
public static void setVisibility(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1685+
layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY)));
1686+
}
1687+
1688+
public static void setHeatmapRadius(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1689+
if (styleValue.isExpression()) {
1690+
layer.setProperties(PropertyFactory.heatmapRadius(styleValue.getExpression()));
1691+
} else {
1692+
layer.setProperties(PropertyFactory.heatmapRadius(styleValue.getFloat(VALUE_KEY)));
1693+
}
1694+
}
1695+
1696+
1697+
public static void setHeatmapRadiusTransition(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1698+
TransitionOptions transition = styleValue.getTransition();
1699+
if (transition != null) {
1700+
layer.setHeatmapRadiusTransition(transition);
1701+
}
1702+
}
1703+
1704+
public static void setHeatmapWeight(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1705+
if (styleValue.isExpression()) {
1706+
layer.setProperties(PropertyFactory.heatmapWeight(styleValue.getExpression()));
1707+
} else {
1708+
layer.setProperties(PropertyFactory.heatmapWeight(styleValue.getFloat(VALUE_KEY)));
1709+
}
1710+
}
1711+
1712+
public static void setHeatmapIntensity(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1713+
if (styleValue.isExpression()) {
1714+
layer.setProperties(PropertyFactory.heatmapIntensity(styleValue.getExpression()));
1715+
} else {
1716+
layer.setProperties(PropertyFactory.heatmapIntensity(styleValue.getFloat(VALUE_KEY)));
1717+
}
1718+
}
1719+
1720+
1721+
public static void setHeatmapIntensityTransition(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1722+
TransitionOptions transition = styleValue.getTransition();
1723+
if (transition != null) {
1724+
layer.setHeatmapIntensityTransition(transition);
1725+
}
1726+
}
1727+
1728+
public static void setHeatmapColor(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1729+
if (styleValue.isExpression()) {
1730+
layer.setProperties(PropertyFactory.heatmapColor(styleValue.getExpression()));
1731+
} else {
1732+
layer.setProperties(PropertyFactory.heatmapColor(styleValue.getInt(VALUE_KEY)));
1733+
}
1734+
}
1735+
1736+
public static void setHeatmapOpacity(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1737+
if (styleValue.isExpression()) {
1738+
layer.setProperties(PropertyFactory.heatmapOpacity(styleValue.getExpression()));
1739+
} else {
1740+
layer.setProperties(PropertyFactory.heatmapOpacity(styleValue.getFloat(VALUE_KEY)));
1741+
}
1742+
}
1743+
1744+
1745+
public static void setHeatmapOpacityTransition(HeatmapLayer layer, RCTMGLStyleValue styleValue) {
1746+
TransitionOptions transition = styleValue.getTransition();
1747+
if (transition != null) {
1748+
layer.setHeatmapOpacityTransition(transition);
1749+
}
1750+
}
1751+
15941752
public static void setVisibility(FillExtrusionLayer layer, RCTMGLStyleValue styleValue) {
15951753
layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY)));
15961754
}
@@ -1807,6 +1965,90 @@ public static void setRasterFadeDuration(RasterLayer layer, RCTMGLStyleValue sty
18071965
}
18081966
}
18091967

1968+
public static void setVisibility(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
1969+
layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY)));
1970+
}
1971+
1972+
public static void setHillshadeIlluminationDirection(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
1973+
if (styleValue.isExpression()) {
1974+
layer.setProperties(PropertyFactory.hillshadeIlluminationDirection(styleValue.getExpression()));
1975+
} else {
1976+
layer.setProperties(PropertyFactory.hillshadeIlluminationDirection(styleValue.getFloat(VALUE_KEY)));
1977+
}
1978+
}
1979+
1980+
public static void setHillshadeIlluminationAnchor(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
1981+
if (styleValue.isExpression()) {
1982+
layer.setProperties(PropertyFactory.hillshadeIlluminationAnchor(styleValue.getExpression()));
1983+
} else {
1984+
layer.setProperties(PropertyFactory.hillshadeIlluminationAnchor(styleValue.getString(VALUE_KEY)));
1985+
}
1986+
}
1987+
1988+
public static void setHillshadeExaggeration(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
1989+
if (styleValue.isExpression()) {
1990+
layer.setProperties(PropertyFactory.hillshadeExaggeration(styleValue.getExpression()));
1991+
} else {
1992+
layer.setProperties(PropertyFactory.hillshadeExaggeration(styleValue.getFloat(VALUE_KEY)));
1993+
}
1994+
}
1995+
1996+
1997+
public static void setHillshadeExaggerationTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
1998+
TransitionOptions transition = styleValue.getTransition();
1999+
if (transition != null) {
2000+
layer.setHillshadeExaggerationTransition(transition);
2001+
}
2002+
}
2003+
2004+
public static void setHillshadeShadowColor(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
2005+
if (styleValue.isExpression()) {
2006+
layer.setProperties(PropertyFactory.hillshadeShadowColor(styleValue.getExpression()));
2007+
} else {
2008+
layer.setProperties(PropertyFactory.hillshadeShadowColor(styleValue.getInt(VALUE_KEY)));
2009+
}
2010+
}
2011+
2012+
2013+
public static void setHillshadeShadowColorTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
2014+
TransitionOptions transition = styleValue.getTransition();
2015+
if (transition != null) {
2016+
layer.setHillshadeShadowColorTransition(transition);
2017+
}
2018+
}
2019+
2020+
public static void setHillshadeHighlightColor(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
2021+
if (styleValue.isExpression()) {
2022+
layer.setProperties(PropertyFactory.hillshadeHighlightColor(styleValue.getExpression()));
2023+
} else {
2024+
layer.setProperties(PropertyFactory.hillshadeHighlightColor(styleValue.getInt(VALUE_KEY)));
2025+
}
2026+
}
2027+
2028+
2029+
public static void setHillshadeHighlightColorTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
2030+
TransitionOptions transition = styleValue.getTransition();
2031+
if (transition != null) {
2032+
layer.setHillshadeHighlightColorTransition(transition);
2033+
}
2034+
}
2035+
2036+
public static void setHillshadeAccentColor(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
2037+
if (styleValue.isExpression()) {
2038+
layer.setProperties(PropertyFactory.hillshadeAccentColor(styleValue.getExpression()));
2039+
} else {
2040+
layer.setProperties(PropertyFactory.hillshadeAccentColor(styleValue.getInt(VALUE_KEY)));
2041+
}
2042+
}
2043+
2044+
2045+
public static void setHillshadeAccentColorTransition(HillshadeLayer layer, RCTMGLStyleValue styleValue) {
2046+
TransitionOptions transition = styleValue.getTransition();
2047+
if (transition != null) {
2048+
layer.setHillshadeAccentColorTransition(transition);
2049+
}
2050+
}
2051+
18102052
public static void setVisibility(BackgroundLayer layer, RCTMGLStyleValue styleValue) {
18112053
layer.setProperties(PropertyFactory.visibility(styleValue.getString(VALUE_KEY)));
18122054
}

docs/Annotation.md

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
## <MapboxGL.Annotation />
2+
###
3+
4+
### props
5+
| Prop | Type | Default | Required | Description |
6+
| ---- | :--: | :-----: | :------: | :----------: |
7+
| id | `string` | `none` | `true` | FIX ME NO DESCRIPTION |
8+
| animated | `bool` | `false` | `false` | FIX ME NO DESCRIPTION |
9+
| animationDuration | `number` | `1000` | `false` | FIX ME NO DESCRIPTION |
10+
| animationEasingFunction | `func` | `Easing.linear` | `false` | FIX ME NO DESCRIPTION |
11+
| coordinates | `arrayOf` | `none` | `false` | FIX ME NO DESCRIPTION |
12+
| onPress | `func` | `none` | `false` | FIX ME NO DESCRIPTION |
13+
| icon | `union` | `none` | `false` | FIX ME NO DESCRIPTION |
14+
15+
### methods
16+
#### onPress()
17+
18+
19+
20+
##### arguments
21+
| Name | Type | Required | Description |
22+
| ---- | :--: | :------: | :----------: |
23+
24+
25+
26+
#### symbolStyle()
27+
28+
29+
30+
##### arguments
31+
| Name | Type | Required | Description |
32+
| ---- | :--: | :------: | :----------: |
33+
34+
35+
36+

docs/BackgroundLayer.md

+10-7
Original file line numberDiff line numberDiff line change
@@ -59,23 +59,25 @@ The color with which the background will be drawn.
5959
#### Disabled By
6060
`backgroundPattern`
6161

62-
#### Supported Style Functions
63-
`camera`
62+
#### Expression
63+
64+
Parameters: `zoom`
6465

6566
___
6667

6768
#### Name
6869
`backgroundPattern`
6970

7071
#### Description
71-
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).
72+
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). Note that zoomDependent expressions will be evaluated only at integer zoom levels.
7273

7374
#### Type
7475
`string`
7576

7677

77-
#### Supported Style Functions
78-
`camera`
78+
#### Expression
79+
80+
Parameters: `zoom`
7981

8082
___
8183

@@ -97,6 +99,7 @@ The opacity at which the background will be drawn.
9799
#### Maximum
98100
`1`
99101

100-
#### Supported Style Functions
101-
`camera`
102+
#### Expression
103+
104+
Parameters: `zoom`
102105

docs/Camera.md

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
## <MapboxGL.Camera />
2+
###
3+
4+
### props
5+
| Prop | Type | Default | Required | Description |
6+
| ---- | :--: | :-----: | :------: | :----------: |
7+
| animationDuration | `number` | `2000` | `false` | FIX ME NO DESCRIPTION |
8+
| animationMode | `enum` | `'easeTo'` | `false` | FIX ME NO DESCRIPTION |
9+
| centerCoordinate | `arrayOf` | `none` | `false` | FIX ME NO DESCRIPTION |
10+
| heading | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
11+
| pitch | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
12+
| bounds | `shape` | `none` | `false` | FIX ME NO DESCRIPTION |
13+
| zoomLevel | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
14+
| minZoomLevel | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
15+
| maxZoomLevel | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
16+
| followUserLocation | `bool` | `none` | `false` | FIX ME NO DESCRIPTION |
17+
| followUserMode | `enum` | `none` | `false` | FIX ME NO DESCRIPTION |
18+
| followZoomLevel | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
19+
| followPitch | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
20+
| followHeading | `number` | `none` | `false` | FIX ME NO DESCRIPTION |
21+
| triggerKey | `any` | `none` | `false` | FIX ME NO DESCRIPTION |
22+
| alignment | `arrayOf` | `none` | `false` | FIX ME NO DESCRIPTION |
23+
| isUserInteraction | `FIX ME UNKNOWN TYPE` | `false` | `false` | FIX ME NO DESCRIPTION |
24+
25+

0 commit comments

Comments
 (0)