[core, test] Bump GL JS pin to bring gl-native back in sync with gl-js.

Requires changing `generate-style-code` to treat 'formatted' as being the same as 'string' until gl-native gets 'formatted' support with https://github.com/mapbox/mapbox-gl-native/pull/12624.
To make nitpick happy, PropertyFunction.java uses the latest "text-field" description from v8.json. It's technically correct, just kind of pointless since the "If a plain `string` is provided" clause will always be true.
This commit is contained in:
Chris Loer
2018-08-21 16:19:43 -07:00
committed by Chris Loer
parent 33cd094d85
commit fd1767efba
6 changed files with 34 additions and 4 deletions

View File

@@ -102,6 +102,7 @@ global.objCTestValue = function (property, layerType, arraysAsStructs, indent) {
return property.default ? '@"false"' : '@"true"';
case 'number':
return '@"1"';
case 'formatted':
case 'string':
return `@"'${_.startCase(propertyName)}'"`;
case 'enum':
@@ -146,6 +147,7 @@ global.mbglTestValue = function (property, layerType) {
return property.default ? 'false' : 'true';
case 'number':
return '1.0';
case 'formatted':
case 'string':
return `"${_.startCase(propertyName)}"`;
case 'enum': {
@@ -218,6 +220,7 @@ global.testHelperMessage = function (property, layerType, isFunction) {
return 'testBool' + fnSuffix;
case 'number':
return 'testNumber' + fnSuffix;
case 'formatted':
case 'string':
return 'testString' + fnSuffix;
case 'enum':
@@ -385,6 +388,7 @@ global.describeType = function (property) {
return 'Boolean';
case 'number':
return 'numeric';
case 'formatted':
case 'string':
return 'string';
case 'enum':
@@ -428,6 +432,7 @@ global.describeValue = function (value, property, layerType) {
return value ? '`YES`' : '`NO`';
case 'number':
return 'the float ' + '`' + formatNumber(value) + '`';
case 'formatted':
case 'string':
if (value === '') {
return 'the empty string';
@@ -509,6 +514,7 @@ global.propertyType = function (property) {
return 'NSNumber *';
case 'number':
return 'NSNumber *';
case 'formatted':
case 'string':
return 'NSString *';
case 'enum':
@@ -539,7 +545,8 @@ global.isInterpolatable = function (property) {
const type = property.type === 'array' ? property.value : property.type;
return type !== 'boolean' &&
type !== 'enum' &&
type !== 'string';
type !== 'string' &&
type !== 'formatted';
};
global.valueTransformerArguments = function (property) {
@@ -549,6 +556,7 @@ global.valueTransformerArguments = function (property) {
return ['bool', objCType];
case 'number':
return ['float', objCType];
case 'formatted':
case 'string':
return ['std::string', objCType];
case 'enum':
@@ -582,6 +590,7 @@ global.mbglType = function(property) {
return 'bool';
case 'number':
return 'float';
case 'formatted':
case 'string':
return 'std::string';
case 'enum': {