From 64ca9b25d41a04833511ad013b23fa75c2ecfe40 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Mon, 23 Sep 2024 00:02:19 +0900 Subject: [PATCH] Add __nextHasNoMarginBottom to BaseControl-based components --- src/editor-sidebar/create-panel.js | 132 ++++++++++--------- src/editor-sidebar/create-variation-panel.js | 4 +- src/editor-sidebar/metadata-editor-modal.js | 17 ++- src/editor-sidebar/reset-theme.js | 5 +- src/editor-sidebar/save-panel.js | 10 +- src/landing-page/create-modal.js | 10 +- 6 files changed, 106 insertions(+), 72 deletions(-) diff --git a/src/editor-sidebar/create-panel.js b/src/editor-sidebar/create-panel.js index 951c03a0..41135665 100644 --- a/src/editor-sidebar/create-panel.js +++ b/src/editor-sidebar/create-panel.js @@ -139,6 +139,7 @@ export const CreateThemePanel = ( { createType } ) => { /> @@ -153,67 +154,76 @@ export const CreateThemePanel = ( { createType } ) => { ) } - - setTheme( { ...theme, description: value } ) - } - placeholder={ __( - 'A short description of the theme', - 'create-block-theme' - ) } - /> - - setTheme( { ...theme, uri: value } ) - } - placeholder={ __( - 'https://github.com/wordpress/twentytwentythree/', - 'create-block-theme' - ) } - /> - - setTheme( { ...theme, author: value } ) - } - placeholder={ __( - 'the WordPress team', - 'create-block-theme' - ) } - /> - - setTheme( { ...theme, author_uri: value } ) - } - placeholder={ __( - 'https://wordpress.org/', - 'create-block-theme' - ) } - /> - ( { - label: version, - value: version, - } ) ) } - onChange={ ( value ) => { - setTheme( { ...theme, requires_wp: value } ); - } } - /> + + + setTheme( { ...theme, description: value } ) + } + placeholder={ __( + 'A short description of the theme', + 'create-block-theme' + ) } + /> + + setTheme( { ...theme, uri: value } ) + } + placeholder={ __( + 'https://github.com/wordpress/twentytwentythree/', + 'create-block-theme' + ) } + /> + + setTheme( { ...theme, author: value } ) + } + placeholder={ __( + 'the WordPress team', + 'create-block-theme' + ) } + /> + + setTheme( { ...theme, author_uri: value } ) + } + placeholder={ __( + 'https://wordpress.org/', + 'create-block-theme' + ) } + /> + ( { + label: version, + value: version, + } ) + ) } + onChange={ ( value ) => { + setTheme( { ...theme, requires_wp: value } ); + } } + /> +
{ createType === 'createClone' && ( diff --git a/src/editor-sidebar/create-variation-panel.js b/src/editor-sidebar/create-variation-panel.js index daa00221..a4e9f17d 100644 --- a/src/editor-sidebar/create-variation-panel.js +++ b/src/editor-sidebar/create-variation-panel.js @@ -101,8 +101,9 @@ export const CreateVariationPanel = () => { - + { /> { onRequestClose={ onRequestClose } className="create-block-theme__metadata-editor-modal" > - + { __( 'Edit Metadata properties of the current theme.', @@ -159,11 +159,13 @@ export const ThemeMetadataEditorModal = ( { onRequestClose } ) => { @@ -175,6 +177,7 @@ export const ThemeMetadataEditorModal = ( { onRequestClose } ) => { ) } /> @@ -186,6 +189,7 @@ export const ThemeMetadataEditorModal = ( { onRequestClose } ) => { ) } /> @@ -197,6 +201,7 @@ export const ThemeMetadataEditorModal = ( { onRequestClose } ) => { ) } /> @@ -208,6 +213,7 @@ export const ThemeMetadataEditorModal = ( { onRequestClose } ) => { ) } /> @@ -219,6 +225,7 @@ export const ThemeMetadataEditorModal = ( { onRequestClose } ) => { ) } /> { } } /> { { @@ -288,6 +296,7 @@ Plugin Description`, /> @@ -327,6 +336,7 @@ ${ __( 'Source', 'create-block-theme' ) }` } /> @@ -358,7 +368,7 @@ Image license`, } /> - + { __( 'Screenshot', 'create-block-theme' ) } @@ -408,6 +418,7 @@ Image license`, diff --git a/src/editor-sidebar/reset-theme.js b/src/editor-sidebar/reset-theme.js index 3ee5501b..fa770371 100644 --- a/src/editor-sidebar/reset-theme.js +++ b/src/editor-sidebar/reset-theme.js @@ -94,8 +94,9 @@ function ResetTheme() { - + { - + { onChange={ () => handleTogglePreference( 'saveFonts' ) } /> { onChange={ () => handleTogglePreference( 'saveStyle' ) } /> { onChange={ () => handleTogglePreference( 'saveTemplates' ) } /> { } /> { onChange={ () => handleTogglePreference( 'savePatterns' ) } /> { onChange={ () => handleTogglePreference( 'localizeText' ) } /> { } /> { ) } { onChange={ ( value ) => setTheme( { ...theme, name: value } ) } - /> - - - { __( + help={ __( '(Tip: You can edit all of this and more in the Editor later.)', 'create-block-theme' ) } - + /> @@ -140,6 +139,7 @@ export const CreateThemeModal = ( { onRequestClose, creationType } ) => { ) } />