@mapbox/mapbox-gl-style-spec 13.24.0-alpha.2 → 13.24.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ # 13.23.1
2
+
3
+ ### ✨ Features and improvements
4
+
5
+ * Improve `coalesce` expressions to return a `ResolvedImage` when images are missing. ([#11371](https://github.com/mapbox/mapbox-gl-js/pull/11371))
6
+
1
7
  # 13.23.0
2
8
 
3
9
  ### ✨ Features and improvements
package/dist/index.cjs CHANGED
@@ -10526,17 +10526,17 @@
10526
10526
  evaluate(ctx) {
10527
10527
  let result = null;
10528
10528
  let argCount = 0;
10529
- let requestedImageName;
10529
+ let firstImage;
10530
10530
  for (const arg of this.args) {
10531
10531
  argCount++;
10532
10532
  result = arg.evaluate(ctx);
10533
10533
  if (result && result instanceof ResolvedImage && !result.available) {
10534
- if (!requestedImageName) {
10535
- requestedImageName = result.name;
10534
+ if (!firstImage) {
10535
+ firstImage = result;
10536
10536
  }
10537
10537
  result = null;
10538
10538
  if (argCount === this.args.length) {
10539
- result = requestedImageName;
10539
+ return firstImage;
10540
10540
  }
10541
10541
  }
10542
10542
  if (result !== null)