Skip to content

Commit

Permalink
Merge pull request #1033 from publishpress/release-4.1.1
Browse files Browse the repository at this point in the history
Release 4.1.1
  • Loading branch information
andergmartins authored Nov 12, 2024
2 parents 9533450 + 0efcf46 commit 5458cc8
Show file tree
Hide file tree
Showing 35 changed files with 1,496 additions and 1,418 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,18 @@
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## [4.1.1] - 12 Nov, 2024

### Fixed

- Fix the layout of inserter in the workflow editor for WP 6.7 (Issue #1025).
- Fix the layout of the top toolbar in the workflow editor for WP 6.7 (Issue #1028).

### Changed

- Minimum required version of WordPress is now 6.7.
- Minimum required version of PHP is now 7.4.

## [4.1.0] - 11 Nov, 2024

### Added
Expand Down
2 changes: 1 addition & 1 deletion assets/js/blockEditor.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/bulkEdit.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/classicEditor.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/quickEdit.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/settingsGeneral.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/settingsPostTypes.min.js

Large diffs are not rendered by default.

163 changes: 62 additions & 101 deletions assets/js/workflowEditor.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/workflowEditor.min.js

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export function FullscreenModeClose({ showTooltip }) {
let buttonIcon = <Icon size="36px" icon={wordpress} />;

return (
<motion.div whileHover="expand">
<motion.div whileHover="expand" className="editor-header__back-button">
<Button
className="edit-post-fullscreen-mode-close"
href={
Expand Down
2 changes: 1 addition & 1 deletion assets/jsx/workflow-editor/components/layout/layout.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
FEATURE_INSERTER,
FEATURE_WELCOME_GUIDE
} from "../../constants";
import { InserterSidebar } from "../secondary-sidebar/inserter";
import { InserterSidebar } from "../secondary-sidebar/inserter-sidebar";
import classnames from 'classnames';
import { SlotFillProvider } from "@wordpress/components";
import { SettingsSidebar } from "../settings-sidebar/settings-sidebar";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ function InserterListboxGroup(props, ref) {
useEffect(() => {
if (shouldSpeak) {
speak(
__('Use left and right arrow keys to move through blocks', 'post-expirator')
__('Use left and right arrow keys to move through steps', 'post-expirator')
);
}
}, [shouldSpeak]);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,26 +1,17 @@
/**
* WordPress dependencies
*/
import { __unstableUseCompositeState as useCompositeState } from '@wordpress/components';

/**
* Internal dependencies
*/
import InserterListboxContext from './context';
import { Composite } from '@wordpress/components';

export { default as InserterListboxGroup } from './group';
export { default as InserterListboxRow } from './row';
export { default as InserterListboxItem } from './item';

export function InserterListbox({ children }) {
const compositeState = useCompositeState({
shift: true,
wrap: 'horizontal',
});
export const InserterListbox = ({ children }) => {
return (
<InserterListboxContext.Provider value={compositeState}>
{children}
</InserterListboxContext.Provider>
<Composite focusShift focusWrap="horizontal" render={ <></> }>
{ children }
</Composite>
);
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,52 +1,45 @@
/**
* WordPress dependencies
*/
import {
Button,
__unstableCompositeItem as CompositeItem,
} from '@wordpress/components';
import { forwardRef, useContext } from '@wordpress/element';

/**
* Internal dependencies
*/
import InserterListboxContext from './context';
import { Button, Composite } from '@wordpress/components';
import { forwardRef } from '@wordpress/element';

function InserterListboxItem(
{ isFirst, as: Component, children, ...props },
ref
) {
const state = useContext(InserterListboxContext);
return (
<CompositeItem
ref={ref}
state={state}
<Composite.Item
ref={ ref }
role="option"
// Use the CompositeItem `focusable` prop over Button's
// isFocusable. The latter was shown to cause an issue
// with tab order in the inserter list.
focusable
{...props}
>
{(htmlProps) => {
// Use the Composite.Item `accessibleWhenDisabled` prop
// over Button's `isFocusable`. The latter was shown to
// cause an issue with tab order in the inserter list.
accessibleWhenDisabled
{ ...props }
render={ ( htmlProps ) => {
const propsWithTabIndex = {
...htmlProps,
tabIndex: isFirst ? 0 : htmlProps.tabIndex,
};
if (Component) {
if ( Component ) {
return (
<Component {...propsWithTabIndex}>
{children}
<Component { ...propsWithTabIndex }>
{ children }
</Component>
);
}
if (typeof children === 'function') {
return children(propsWithTabIndex);
if ( typeof children === 'function' ) {
return children( propsWithTabIndex );
}
return <Button {...propsWithTabIndex}>{children}</Button>;
}}
</CompositeItem>
return (
<Button __next40pxDefaultSize { ...propsWithTabIndex }>
{ children }
</Button>
);
} }
/>
);
}

export default forwardRef(InserterListboxItem);
export default forwardRef( InserterListboxItem );
Original file line number Diff line number Diff line change
@@ -1,24 +1,11 @@
/**
* WordPress dependencies
*/
import { forwardRef, useContext } from '@wordpress/element';
import { __unstableCompositeGroup as CompositeGroup } from '@wordpress/components';
import { forwardRef } from '@wordpress/element';
import { Composite } from '@wordpress/components';

/**
* Internal dependencies
*/
import InserterListboxContext from './context';

function InserterListboxRow(props, ref) {
const state = useContext(InserterListboxContext);
return (
<CompositeGroup
state={state}
role="presentation"
ref={ref}
{...props}
/>
);
function InserterListboxRow( props, ref ) {
return <Composite.Group role="presentation" ref={ ref } { ...props } />;
}

export default forwardRef(InserterListboxRow);
export default forwardRef( InserterListboxRow );
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ import { useSelect } from '@wordpress/data';
import NodeTypesList from './node-types-list';
import InserterPanel from './panel';
import { searchNodeItems } from './search-items';
import { InserterListbox } from './inserter-listbox';
import { InserterNoResults } from './inserter-no-results';
import { store as editorStore } from '../editor-store';
import InserterListbox from './inserter-listbox';

export const InserterSearchResults = ({
filterValue,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,16 @@ export function InserterSidebar() {
<div
ref={inserterDialogRef}
{...inserterDialogProps}
className="edit-post-editor__inserter-panel"
className="editor-inserter-sidebar"
>
<div className="edit-post-editor__inserter-panel-header">
<div className="editor-inserter-sidebar__header">
<Button
icon={close}
onClick={() => closeInserter()}
className="block-editor-tabbed-sidebar__close-button is-small"
/>
</div>
<div className="edit-post-editor__inserter-panel-content">
<div className="editor-inserter-sidebar__content">
<InserterLibrary
showMostUsedNodes={showMostUsedNodes}
showInserterHelpPanel={true}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ export function InserterMenu({
<div className="block-editor-inserter__menu">
<div className="block-editor-inserter__main-area show-as-tabs">
{ /* the following div is necessary to fix the sticky position of the search form */}
<div className="block-editor-inserter__content">
<div className="block-editor-tabbed-sidebar">
<SearchControl
className="block-editor-inserter__search"
onChange={(value) => {
Expand Down
5 changes: 3 additions & 2 deletions assets/jsx/workflow-editor/css/inserter.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@
justify-content: flex-end;
}

@media (min-width: 600px) {
.edit-post-editor__inserter-panel-header {
@media (min-width: 782px) {
.editor-inserter-sidebar__header {
display: none;
}
}

.edit-post-header-toolbar .editor-document-tools__left > .edit-post-header-toolbar__inserter-toggle.is-pressed svg {
transform: rotate(45deg);
}

2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"prefer-stable": true,
"minimum-stability": "stable",
"require": {
"php": ">=7.2.5",
"php": ">=7.4",
"ext-json": "*"
},
"require-dev": {
Expand Down
38 changes: 19 additions & 19 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions dev-workspace/docker/compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ services:
- ../.cache/.composer/cache:/root/.composer/cache
- ../.cache/.composer/auth.json:/root/.composer/auth.json
wordpress:
image: wordpress:6.6
image: wordpress:beta-6.7
container_name: ${COMPOSE_PROJECT_NAME}_tests_wordpress
restart: always
ports:
Expand All @@ -31,7 +31,7 @@ services:
- ../.cache/wordpress:/var/www/html/
- ../../:/var/www/html/wp-content/plugins/post-expirator
- ../../tests/Support/Data/plugins/pre-tests:/var/www/html/wp-content/plugins/pre-tests
- ../../tests/Support/Data/plugins/classic-editor-v1.6.2:/var/www/html/wp-content/plugins/classic-editor
- ../../tests/Support/Data/plugins/classic-editor-v1.6.5:/var/www/html/wp-content/plugins/classic-editor
depends_on:
db:
condition: service_healthy
Expand Down Expand Up @@ -68,7 +68,7 @@ services:
- ../.cache/wordpress:/var/www/html/
- ../../:/var/www/html/wp-content/plugins/post-expirator
- ../../tests/Support/Data/plugins/pre-tests:/var/www/html/wp-content/plugins/pre-tests
- ../../tests/Support/Data/plugins/classic-editor-v1.6.2:/var/www/html/wp-content/plugins/classic-editor
- ../../tests/Support/Data/plugins/classic-editor-v1.6.5:/var/www/html/wp-content/plugins/classic-editor
depends_on:
- wordpress
links:
Expand Down
Loading

0 comments on commit 5458cc8

Please sign in to comment.