Skip to content

Commit

Permalink
prep build 02/12
Browse files Browse the repository at this point in the history
  • Loading branch information
bph committed Feb 12, 2024
2 parents 3d77e63 + 1283299 commit d5763e2
Show file tree
Hide file tree
Showing 9 changed files with 37 additions and 62 deletions.
17 changes: 0 additions & 17 deletions bin/docker-compose.override.yml.template

This file was deleted.

13 changes: 0 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -378,18 +378,5 @@
"**/tsconfig.json": [
"npm run lint:tsconfig"
]
},
"wp-env": {
"plugin-dir": "gutenberg",
"plugin-name": "Gutenberg",
"docker-template": "./bin/docker-compose.override.yml.template",
"welcome-logo": [
",⁻⁻⁻· . |",
"| ،⁓’. . |--- ,---. ,---. |---. ,---. ,---. ,---.",
"| | | | | |---' | | | | |---' | | |",
"`---' `---' `---’ `---’ ' ` `---' `---’ ` `---|",
" `---'"
],
"welcome-build-command": "npm run dev"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -46,31 +46,23 @@ export default function HeadingLevelDropdown( {
icon={ <HeadingLevelIcon level={ value } /> }
label={ __( 'Change level' ) }
controls={ options.map( ( targetLevel ) => {
{
const isActive = targetLevel === value;

return {
icon: (
<HeadingLevelIcon
level={ targetLevel }
isPressed={ isActive }
/>
),
title:
targetLevel === 0
? __( 'Paragraph' )
: sprintf(
// translators: %s: heading level e.g: "1", "2", "3"
__( 'Heading %d' ),
targetLevel
),
isActive,
onClick() {
onChange( targetLevel );
},
role: 'menuitemradio',
};
}
const isActive = targetLevel === value;
return {
icon: <HeadingLevelIcon level={ targetLevel } />,
title:
targetLevel === 0
? __( 'Paragraph' )
: sprintf(
// translators: %s: heading level e.g: "1", "2", "3"
__( 'Heading %d' ),
targetLevel
),
isActive,
onClick() {
onChange( targetLevel );
},
role: 'menuitemradio',
};
} ) }
/>
);
Expand Down
9 changes: 7 additions & 2 deletions packages/block-library/src/spacer/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,14 @@ const SpacerEdit = ( {
return editorSettings?.disableCustomSpacingSizes;
} );
const { orientation } = context;
const { orientation: parentOrientation, type } = parentLayout || {};
const {
orientation: parentOrientation,
type,
default: { type: defaultType } = {},
} = parentLayout || {};
// Check if the spacer is inside a flex container.
const isFlexLayout = type === 'flex';
const isFlexLayout =
type === 'flex' || ( ! type && defaultType === 'flex' );
// If the spacer is inside a flex container, it should either inherit the orientation
// of the parent or use the flex default orientation.
const inheritedOrientation =
Expand Down
2 changes: 2 additions & 0 deletions packages/block-library/src/spacer/editor.scss
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,7 @@

&.resize-horizontal {
margin-bottom: 0;
// Important is used to have higher specificity than the inline style set by re-resizable library.
height: 100% !important;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ export default function HeaderEditMode() {
</div>
) }
<PostViewLink />
<SaveButton />
<SaveButton size="compact" />
{ ! isDistractionFree && (
<PinnedItems.Slot scope="core/edit-site" />
) }
Expand Down
3 changes: 2 additions & 1 deletion packages/edit-site/src/components/save-button/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export default function SaveButton( {
showTooltip = true,
defaultLabel,
icon,
size,
__next40pxDefaultSize = false,
} ) {
const { isDirty, isSaving, isSaveViewOpen, previewingThemeName } =
Expand Down Expand Up @@ -119,7 +120,7 @@ export default function SaveButton( {
showTooltip={ showTooltip }
icon={ icon }
__next40pxDefaultSize={ __next40pxDefaultSize }
size="compact"
size={ size }
>
{ label }
</Button>
Expand Down
7 changes: 5 additions & 2 deletions packages/edit-site/src/components/save-hub/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,16 @@
border-top: 1px solid $gray-800;
flex-shrink: 0;
margin: 0;
padding: $grid-unit-20 + $grid-unit-05 $canvas-padding;
padding: $grid-unit-20 $canvas-padding;
}

.edit-site-save-hub__button {
color: inherit;
width: 100%;
justify-content: center;

&.components-button.components-button {
justify-content: center;
}

&[aria-disabled="true"] {
opacity: 1;
Expand Down
4 changes: 3 additions & 1 deletion schemas/json/block.json
Original file line number Diff line number Diff line change
Expand Up @@ -556,10 +556,12 @@
}
},
"shadow": {
"default": false,
"description": "Allow blocks to define a box shadow.",
"oneOf": [
{
"type": "boolean"
"type": "boolean",
"description": "Defines whether a box shadow is enabled or not."
},
{
"type": "object"
Expand Down

0 comments on commit d5763e2

Please sign in to comment.