summaryrefslogtreecommitdiff
path: root/platform/darwin/scripts
diff options
context:
space:
mode:
authorJesse Bounds <jesse@rebounds.net>2017-02-06 15:07:13 -0800
committerJesse Bounds <jesse@rebounds.net>2017-02-08 21:11:43 -0800
commita383edaae8ec05a3b385b19576c7a9358672662b (patch)
treec703688e301180cb5d78aa262b1703b4cc46ca4f /platform/darwin/scripts
parent94a3c272ffd6676edbe59342d70bca49aaf676a5 (diff)
downloadqtlocation-mapboxgl-a383edaae8ec05a3b385b19576c7a9358672662b.tar.gz
[ios, macos] Add function and interpolation mode to style property docs
Diffstat (limited to 'platform/darwin/scripts')
-rw-r--r--platform/darwin/scripts/generate-style-code.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/platform/darwin/scripts/generate-style-code.js b/platform/darwin/scripts/generate-style-code.js
index 72aacbc742..efa7fe2d3c 100644
--- a/platform/darwin/scripts/generate-style-code.js
+++ b/platform/darwin/scripts/generate-style-code.js
@@ -281,6 +281,19 @@ global.propertyDoc = function (propertyName, property, layerType, kind) {
doc += `\n\nThis attribute corresponds to the <a href="https://www.mapbox.com/mapbox-gl-style-spec/#${anchor}"><code>${property.original}</code></a> layout property in the Mapbox Style Specification.`;
}
}
+ doc += '`\n\nThis property can be set to one of the following values:\n\n' +
+ '- `MGLStyleConstantValue`\n';
+ if (property["property-function"]) {
+ doc += '- `MGLCameraStyleFunction` with an interpolation mode of `MGLInterpolationModeExponential` or `MGLInterpolationModeInterval`\n' +
+ '- `MGLSourceStyleFunction` with an interpolation mode of `MGLInterpolationModeExponential`, `MGLInterpolationModeInterval`, `MGLInterpolationModeCategorical`, or `MGLInterpolationModeIdentity`\n' +
+ '- `MGLCompositeStyleFunction` with an interpolation mode of `MGLInterpolationModeExponential`, `MGLInterpolationModeInterval` or `MGLInterpolationModeCategorical`\n';
+ } else {
+ if (property.function === "interpolated") {
+ doc += '- `MGLCameraStyleFunction` with an interpolation mode of `MGLInterpolationModeExponential` or `MGLInterpolationModeInterval`\n';
+ } else {
+ doc += '- `MGLCameraStyleFunction` with an interpolation mode of `MGLInterpolationModeInterval`\n';
+ }
+ }
return doc;
};