From 60a6c2df2794cc90f950e8a05cd266fca33fc56f Mon Sep 17 00:00:00 2001 From: James Koster Date: Wed, 5 Jul 2023 14:58:46 +0100 Subject: [PATCH] wrap buttons (#52249) --- .../edit-post/src/components/sidebar/post-status/index.js | 1 + .../edit-post/src/components/sidebar/post-trash/index.js | 5 +---- .../src/components/post-switch-to-draft-button/index.js | 7 +++---- packages/editor/src/components/post-trash/style.scss | 4 ++-- 4 files changed, 7 insertions(+), 10 deletions(-) diff --git a/packages/edit-post/src/components/sidebar/post-status/index.js b/packages/edit-post/src/components/sidebar/post-status/index.js index 5cc9b70bf9ac3..d0633f26cf254 100644 --- a/packages/edit-post/src/components/sidebar/post-status/index.js +++ b/packages/edit-post/src/components/sidebar/post-status/index.js @@ -58,6 +58,7 @@ function PostStatus( { isOpened, onTogglePanel } ) { marginTop: '16px', } } spacing={ 4 } + wrap > diff --git a/packages/edit-post/src/components/sidebar/post-trash/index.js b/packages/edit-post/src/components/sidebar/post-trash/index.js index 885be537952c0..d77c7a6d82988 100644 --- a/packages/edit-post/src/components/sidebar/post-trash/index.js +++ b/packages/edit-post/src/components/sidebar/post-trash/index.js @@ -2,14 +2,11 @@ * WordPress dependencies */ import { PostTrash as PostTrashLink, PostTrashCheck } from '@wordpress/editor'; -import { FlexItem } from '@wordpress/components'; export default function PostTrash() { return ( - - - + ); } diff --git a/packages/editor/src/components/post-switch-to-draft-button/index.js b/packages/editor/src/components/post-switch-to-draft-button/index.js index 6521200fde590..1fb04931bfce1 100644 --- a/packages/editor/src/components/post-switch-to-draft-button/index.js +++ b/packages/editor/src/components/post-switch-to-draft-button/index.js @@ -3,7 +3,6 @@ */ import { Button, - FlexItem, __experimentalConfirmDialog as ConfirmDialog, } from '@wordpress/components'; import { __ } from '@wordpress/i18n'; @@ -41,7 +40,7 @@ function PostSwitchToDraftButton( { }; return ( - + <> @@ -60,7 +59,7 @@ function PostSwitchToDraftButton( { > { alertMessage } - + ); } diff --git a/packages/editor/src/components/post-trash/style.scss b/packages/editor/src/components/post-trash/style.scss index f24a6eb2743dd..e47981314d5f2 100644 --- a/packages/editor/src/components/post-trash/style.scss +++ b/packages/editor/src/components/post-trash/style.scss @@ -1,4 +1,4 @@ .editor-post-trash.components-button { - width: 100%; - display: block; + flex-grow: 1; + justify-content: center; }