From e0f2616213714da1d333afb55e899b9478bb1ec4 Mon Sep 17 00:00:00 2001 From: Kiryl Dzehtsiarenka Date: Wed, 2 Oct 2024 11:45:56 +0300 Subject: [PATCH] Add metadata to "featureset" Needed for https://github.com/mapbox/style-distillery/pull/226 --- src/style-spec/reference/v8.json | 4 ++++ src/style-spec/types.ts | 1 + 2 files changed, 5 insertions(+) diff --git a/src/style-spec/reference/v8.json b/src/style-spec/reference/v8.json index 543b5807ad5..092f69a5ef7 100644 --- a/src/style-spec/reference/v8.json +++ b/src/style-spec/reference/v8.json @@ -230,6 +230,10 @@ }, "featureset": { "experimental": true, + "metadata": { + "type": "*", + "doc": "Arbitrary properties useful to track with the stylesheet, but do not influence rendering. Properties should be prefixed to avoid collisions, like 'mapbox:'." + }, "selectors": { "type": "array", "value": "selector", diff --git a/src/style-spec/types.ts b/src/style-spec/types.ts index b790aa4a6ea..e2f09ea0f8c 100644 --- a/src/style-spec/types.ts +++ b/src/style-spec/types.ts @@ -198,6 +198,7 @@ export type FeaturesetsSpecification = { * @experimental This is experimental and subject to change in future versions. */ export type FeaturesetSpecification = { + "metadata"?: unknown, "selectors"?: Array }