From 5c1dced6be6309a37c65bb56226050689e18993c Mon Sep 17 00:00:00 2001 From: Tetsuaki Hamano Date: Mon, 20 Mar 2023 21:56:59 +0900 Subject: [PATCH 1/2] Theme JSON schema: Add defaultPresets property to shadow --- schemas/json/theme.json | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/schemas/json/theme.json b/schemas/json/theme.json index 0458e587a909f2..9d68bef1710255 100644 --- a/schemas/json/theme.json +++ b/schemas/json/theme.json @@ -74,6 +74,11 @@ "description": "Settings related to shadows.", "type": "object", "properties": { + "defaultPresets": { + "description": "Allow users to choose shadows from the default shadow presets.", + "type": "boolean", + "default": true + }, "presets": { "description": "Shadow presets for the shadow picker.\nGenerates a single custom property (`--wp--preset--shadow--{slug}`) per preset value.", "type": "array", @@ -97,7 +102,8 @@ "additionalProperties": false } } - } + }, + "additionalProperties": false } } }, From 793daa70aeed0d89c747f54a5c6eeb16e74873e3 Mon Sep 17 00:00:00 2001 From: Tetsuaki Hamano Date: Mon, 20 Mar 2023 22:04:33 +0900 Subject: [PATCH 2/2] build docs --- docs/reference-guides/theme-json-reference/theme-json-living.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/reference-guides/theme-json-reference/theme-json-living.md b/docs/reference-guides/theme-json-reference/theme-json-living.md index c7bb892103e004..2342fc0656221f 100644 --- a/docs/reference-guides/theme-json-reference/theme-json-living.md +++ b/docs/reference-guides/theme-json-reference/theme-json-living.md @@ -60,6 +60,7 @@ Settings related to shadows. | Property | Type | Default | Props | | --- | --- | --- |--- | +| defaultPresets | boolean | true | | | presets | array | | name, shadow, slug | ---