Skip to content

Commit

Permalink
Featured Image: Fix block support selectors after shadow support added (
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronrobertshaw authored and carstingaxion committed Mar 27, 2024
1 parent f855ac4 commit 600d87b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/reference-guides/core-blocks.md
Original file line number Diff line number Diff line change
Expand Up @@ -642,7 +642,7 @@ Display a post's featured image. ([Source](https://github.com/WordPress/gutenber

- **Name:** core/post-featured-image
- **Category:** theme
- **Supports:** align (center, full, left, right, wide), color (~~background~~, ~~text~~), interactivity (clientNavigation), shadow (), spacing (margin, padding), ~~html~~
- **Supports:** align (center, full, left, right, wide), color (~~background~~, ~~text~~), filter (duotone), interactivity (clientNavigation), shadow (), spacing (margin, padding), ~~html~~
- **Attributes:** aspectRatio, customGradient, customOverlayColor, dimRatio, gradient, height, isLink, linkTarget, overlayColor, rel, scale, sizeSlug, useFirstImageFromPost, width

## Post Navigation Link
Expand Down
11 changes: 8 additions & 3 deletions packages/block-library/src/post-featured-image/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,22 +61,23 @@
"supports": {
"align": [ "left", "right", "center", "wide", "full" ],
"color": {
"__experimentalDuotone": "img, .wp-block-post-featured-image__placeholder, .components-placeholder__illustration, .components-placeholder::before",
"text": false,
"background": false
},
"__experimentalBorder": {
"color": true,
"radius": true,
"width": true,
"__experimentalSelector": "img, .block-editor-media-placeholder, .wp-block-post-featured-image__overlay",
"__experimentalSkipSerialization": true,
"__experimentalDefaultControls": {
"color": true,
"radius": true,
"width": true
}
},
"filter": {
"duotone": true
},
"shadow": {
"__experimentalSkipSerialization": true
},
Expand All @@ -90,7 +91,11 @@
}
},
"selectors": {
"shadow": ".wp-block-post-featured-image img, .wp-block-post-featured-image .components-placeholder"
"border": ".wp-block-post-featured-image img, .wp-block-post-featured-image .block-editor-media-placeholder, .wp-block-post-featured-image .wp-block-post-featured-image__overlay",
"shadow": ".wp-block-post-featured-image img, .wp-block-post-featured-image .components-placeholder",
"filter": {
"duotone": ".wp-block-post-featured-image img, .wp-block-post-featured-image .wp-block-post-featured-image__placeholder, .wp-block-post-featured-image .components-placeholder__illustration, .wp-block-post-featured-image .components-placeholder::before"
}
},
"editorStyle": "wp-block-post-featured-image-editor",
"style": "wp-block-post-featured-image"
Expand Down

0 comments on commit 600d87b

Please sign in to comment.