Skip to content

Commit

Permalink
Restore dropzone
Browse files Browse the repository at this point in the history
  • Loading branch information
stokesman committed May 4, 2021
1 parent 8a65511 commit 77ec62f
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions packages/block-library/src/cover/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ function mediaPosition( { x, y } ) {
const isTemporaryMedia = ( id, url ) => ! id && isBlobURL( url );

function CoverPlaceholder( {
hasBackground = false,
disableMediaButtons = false,
children,
noticeUI,
noticeOperations,
Expand All @@ -273,7 +273,7 @@ function CoverPlaceholder( {
accept="image/*,video/*"
allowedTypes={ ALLOWED_MEDIA_TYPES }
notices={ noticeUI }
disableMediaButtons={ hasBackground }
disableMediaButtons={ disableMediaButtons }
onError={ ( message ) => {
removeAllNotices();
createErrorNotice( message );
Expand Down Expand Up @@ -665,6 +665,12 @@ function CoverEdit( {
/>
) }
{ isUploadingMedia && <Spinner /> }
<CoverPlaceholder
disableMediaButtons
noticeUI={ noticeUI }
onSelectMedia={ onSelectMedia }
noticeOperations={ noticeOperations }
/>
<div { ...innerBlocksProps } />
</div>
</>
Expand Down

0 comments on commit 77ec62f

Please sign in to comment.