Skip to content

Commit

Permalink
Fix aspect ratio of welcome image (#32302)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevin940726 authored and youknowriad committed May 31, 2021
1 parent 48c8eca commit abf7b7d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 12 deletions.
27 changes: 15 additions & 12 deletions packages/customize-widgets/src/components/welcome-guide/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,21 @@ export default function WelcomeGuide( { sidebar } ) {

return (
<div className="customize-widgets-welcome-guide">
<picture className="customize-widgets-welcome-guide__image">
<source
srcSet="https://s.w.org/images/block-editor/welcome-editor.svg"
media="(prefers-reduced-motion: reduce)"
/>
<img
src="https://s.w.org/images/block-editor/welcome-editor.gif"
width="312"
height="240"
alt=""
/>
</picture>
<div className="customize-widgets-welcome-guide__image__wrapper">
<picture>
<source
srcSet="https://s.w.org/images/block-editor/welcome-editor.svg"
media="(prefers-reduced-motion: reduce)"
/>
<img
className="customize-widgets-welcome-guide__image"
src="https://s.w.org/images/block-editor/welcome-editor.gif"
width="312"
height="240"
alt=""
/>
</picture>
</div>
<h1 className="customize-widgets-welcome-guide__heading">
{ __( 'Welcome to block Widgets' ) }
</h1>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
margin-bottom: $grid-unit-10;
}

&__image {
height: auto;
}

// Extra specificity to override `.wrap h1` styles.
.wrap &__heading {
font-size: 18px;
Expand Down

0 comments on commit abf7b7d

Please sign in to comment.