Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Polish placeholder radius and enable duotone on image setup state #43425

Merged
merged 1 commit into from
Aug 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/block-library/src/image/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@
"supports": {
"anchor": true,
"color": {
"__experimentalDuotone": "img",
"__experimentalDuotone": "img, .components-placeholder",
"text": false,
"background": false
},
Expand Down
3 changes: 3 additions & 0 deletions packages/block-library/src/image/editor.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
box-shadow: inset 0 0 0 $border-width $gray-900;
border: none;

// Disable any duotone filter applied in the selected state.
filter: none;

// @todo: this should eventually be overridden by a custom border-radius set in the inspector.
border-radius: $radius-block-ui;

Expand Down
4 changes: 3 additions & 1 deletion packages/components/src/placeholder/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -173,11 +173,13 @@
// This is mainly an issue in terms of Site Logo which has a brief flash of the square placeholder.
.components-placeholder.has-illustration {
color: inherit;
border-radius: inherit;
display: flex;
box-shadow: none;
min-width: 100px;

// Radius fallback value.
border-radius: $radius-block-ui;

// Blur the background so layered dashed placeholders are still visually separate.
// We also provide a semitransparent background so as to allow duotones to sheen through.
backdrop-filter: blur(100px);
Expand Down