[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:
Submodule mapbox-gl-js updated: 6c22a1720d...754ec0bf51
@@ -2055,7 +2055,7 @@ public class PropertyFactory {
|
||||
}
|
||||
|
||||
/**
|
||||
* Value to use for a text label.
|
||||
* Value to use for a text label. If a plain `string` is provided, it will be treated as a `formatted` with default/inherited formatting options.
|
||||
*
|
||||
* @param value a String value
|
||||
* @return property wrapper around String
|
||||
@@ -2065,7 +2065,7 @@ public class PropertyFactory {
|
||||
}
|
||||
|
||||
/**
|
||||
* Value to use for a text label.
|
||||
* Value to use for a text label. If a plain `string` is provided, it will be treated as a `formatted` with default/inherited formatting options.
|
||||
*
|
||||
* @param value a String value
|
||||
* @return property wrapper around String
|
||||
|
||||
@@ -55,6 +55,7 @@ global.propertyType = function propertyType(property) {
|
||||
return 'Boolean';
|
||||
case 'number':
|
||||
return 'Float';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return 'String';
|
||||
case 'enum':
|
||||
@@ -74,6 +75,7 @@ global.propertyJavaType = function propertyType(property) {
|
||||
return 'boolean';
|
||||
case 'number':
|
||||
return 'float';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return 'String';
|
||||
case 'enum':
|
||||
@@ -121,6 +123,7 @@ global.propertyNativeType = function (property) {
|
||||
return 'bool';
|
||||
case 'number':
|
||||
return 'float';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return 'std::string';
|
||||
case 'enum':
|
||||
@@ -155,6 +158,7 @@ global.defaultExpressionJava = function(property) {
|
||||
return 'boolean';
|
||||
case 'number':
|
||||
return 'number';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return "string";
|
||||
case 'enum':
|
||||
@@ -179,6 +183,7 @@ global.defaultValueJava = function(property) {
|
||||
return 'true';
|
||||
case 'number':
|
||||
return '0.3f';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return '"' + property['default'] + '"';
|
||||
case 'enum':
|
||||
@@ -187,6 +192,7 @@ global.defaultValueJava = function(property) {
|
||||
return '"rgba(0, 0, 0, 1)"';
|
||||
case 'array':
|
||||
switch (property.value) {
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return '[' + property['default'] + "]";
|
||||
case 'number':
|
||||
@@ -301,6 +307,7 @@ global.evaluatedType = function (property) {
|
||||
return 'bool';
|
||||
case 'number':
|
||||
return 'float';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return 'std::string';
|
||||
case 'enum':
|
||||
|
||||
@@ -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': {
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
{
|
||||
"expression-tests/collator/accent-equals-de": "Locale-specific behavior changes based on platform.",
|
||||
"expression-tests/formatted/basic": "skip - https://github.com/mapbox/mapbox-gl-native/pull/12624",
|
||||
"expression-tests/formatted/to-string": "skip - https://github.com/mapbox/mapbox-gl-native/pull/12624",
|
||||
"expression-tests/interpolate-hcl/linear": "https://github.com/mapbox/mapbox-gl-native/issues/8720",
|
||||
"expression-tests/interpolate-lab/linear": "https://github.com/mapbox/mapbox-gl-native/issues/8720",
|
||||
"expression-tests/is-supported-script/default": "This tests RTL text plugin behavior specific to GL JS",
|
||||
"expression-tests/resolved-locale/basic": "Even the 'en' locale may not be present on some test systems.",
|
||||
"query-tests/geometry/multilinestring": "needs investigation",
|
||||
@@ -9,12 +13,16 @@
|
||||
"query-tests/world-wrapping/point": "skip - needs issue",
|
||||
"query-tests/circle-radius/feature-state": "skip - port https://github.com/mapbox/mapbox-gl-js/pull/6263 - needs issue",
|
||||
"query-tests/circle-stroke-width/feature-state": "skip - port https://github.com/mapbox/mapbox-gl-js/pull/6263 - needs issue",
|
||||
"query-tests/fill-extrusion-translate/multiple-layers": "https://github.com/mapbox/mapbox-gl-native/issues/12701",
|
||||
"query-tests/fill-translate/multiple-layers": "https://github.com/mapbox/mapbox-gl-native/issues/12701",
|
||||
"query-tests/line-gap-width/feature-state": "skip - port https://github.com/mapbox/mapbox-gl-js/pull/6263 - needs issue",
|
||||
"query-tests/line-offset/feature-state": "skip - port https://github.com/mapbox/mapbox-gl-js/pull/6263 - needs issue",
|
||||
"query-tests/line-width/feature-state": "skip - port https://github.com/mapbox/mapbox-gl-js/pull/6263 - needs issue",
|
||||
"query-tests/feature-state/default": "skip - port https://github.com/mapbox/mapbox-gl-js/pull/6263 - needs issue",
|
||||
"query-tests/regressions/mapbox-gl-js#6555": "skip - no querySourceFeatures in mbgl-node; needs issue",
|
||||
"render-tests/background-color/transition": "https://github.com/mapbox/mapbox-gl-native/issues/10619",
|
||||
"render-tests/basic-v9/z0-wide": "https://github.com/mapbox/mapbox-gl-native/pull/12611",
|
||||
"render-tests/bright-v9/z0-wide": "https://github.com/mapbox/mapbox-gl-native/pull/12611",
|
||||
"render-tests/collator/resolved-locale": "Some test platforms don't resolve 'en' locale",
|
||||
"render-tests/collator/default": "Some test platforms don't resolve 'en' locale",
|
||||
"render-tests/debug/collision": "https://github.com/mapbox/mapbox-gl-native/issues/3841",
|
||||
@@ -56,9 +64,13 @@
|
||||
"render-tests/runtime-styling/image-add-sdf": "https://github.com/mapbox/mapbox-gl-native/issues/9847",
|
||||
"render-tests/runtime-styling/paint-property-fill-flat-to-extrude": "https://github.com/mapbox/mapbox-gl-native/issues/6745",
|
||||
"render-tests/runtime-styling/set-style-paint-property-fill-flat-to-extrude": "https://github.com/mapbox/mapbox-gl-native/issues/6745",
|
||||
"render-tests/satellite-v9/z0-wide": "https://github.com/mapbox/mapbox-gl-native/pull/12611",
|
||||
"render-tests/symbol-cross-fade/chinese": "https://github.com/mapbox/mapbox-gl-native/issues/10619",
|
||||
"render-tests/symbol-placement/line-overscaled": "https://github.com/mapbox/mapbox-gl-js/issues/5654",
|
||||
"render-tests/symbol-visibility/visible": "https://github.com/mapbox/mapbox-gl-native/issues/10409",
|
||||
"render-tests/text-field/formatted-arabic": "skip - https://github.com/mapbox/mapbox-gl-native/pull/12624",
|
||||
"render-tests/text-field/formatted-line": "skip - https://github.com/mapbox/mapbox-gl-native/pull/12624",
|
||||
"render-tests/text-field/formatted": "skip - https://github.com/mapbox/mapbox-gl-native/pull/12624",
|
||||
"render-tests/text-no-cross-source-collision/default": "skip - gl-js only",
|
||||
"render-tests/text-pitch-alignment/auto-text-rotation-alignment-map": "https://github.com/mapbox/mapbox-gl-native/issues/9732",
|
||||
"render-tests/text-pitch-alignment/map-text-rotation-alignment-map": "https://github.com/mapbox/mapbox-gl-native/issues/9732",
|
||||
|
||||
@@ -37,6 +37,7 @@ global.evaluatedType = function (property) {
|
||||
return 'bool';
|
||||
case 'number':
|
||||
return 'float';
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return 'std::string';
|
||||
case 'enum':
|
||||
@@ -120,6 +121,7 @@ global.defaultValue = function (property) {
|
||||
switch (property.type) {
|
||||
case 'number':
|
||||
return property.default;
|
||||
case 'formatted':
|
||||
case 'string':
|
||||
return JSON.stringify(property.default || "");
|
||||
case 'enum':
|
||||
|
||||
Reference in New Issue
Block a user